Ablation
This case has no trajectory (it checks an API result).
Presets
Expected vs measured
Benchmarks
The two open issues as numbers: the lean's lag keeps acting after an input is released, and the two lean axes are independent, so a diagonal lean accelerates more than its angle allows. Every score is 0 when the behaviour is ideal. Run them with the defaults, or with the sandbox's parameters to see how a change moves them (the defaults are then drawn dashed for comparison).
Loop-the-loop
Does the ball go round a vertical loop (Rollball's planned loop segment), with the model as it is? The road: 7 m wide between 1 m lips, level in and out, the exit 10 m to the side, the shift banked in so a ball rolling straight follows the middle. Each run starts 12 m before the loop's foot at the speed of its column, rolling, driven as chosen, no steer. Theory for a point mass: v² ≥ 5 g R at the foot (the thin shell carries a little more energy in its spin). Above 75° the model has no ground: no grip and no motor, the ball coasts over the top on its contacts alone.
Cell: the speed at the foot (it changes on the 12 m before it) and where the ball first left the road; "heading back": out of the loop its heading points the way it came, so drive brakes it. round round, but airborne for a moment fell or rolled back. Click a cell for its run.
One run
Corkscrew
Does the ball go through a corkscrew (a road piece Rollball may get): the ball's centre line follows one turn of a helix about a horizontal axis along the travel, eased so the piece enters and leaves level, straight, on the same line, and the road rolls a full turn about that line (the heartline: a bed rolling about its own centreline slides sideways under the ball at R × the roll rate). The road's up is the felt force at the speed a ball driven flat out from the shape's rated entry has there, so such a ball rolls straight through the middle unsteered; off that speed it drifts, and a driver holds the middle. The ball rides the smooth surface itself (a triangle mesh of a twisted bed folds at every seam and launches the ball: the Drive tab draws the mesh, the ball steps on the surface). Each run starts 12 m before the foot at the speed of its column, rolling, coasting to the foot, then driven as chosen. Shapes: the heartline's radius (m) × the piece's length (m), eased over half the piece each way (ramp 0.5: the gentlest entry; a shorter ramp flattens the top, where the bank follows a weaker felt force and swings faster); each banked for its rated speed, a coasting ball's need to be pressed on at the top, rounded up. The recommended pieces are the 3 m × 64 m one (8 cells; the roll 3.3 rad/s mean, 8.6 at the top from 28 m/s) and the 3 m × 48 m one (6 cells; 4.3 mean, 6.7 peak from 26); the old 2.5 m × 32 m piece winds up at 6.5 mean, 10.7 peak. The biggest that rides clean is the 6 m × 80 m one (10 cells; 3.1 mean, 5.6 peak): its top needs v² / 12.75 m over g, so 20 m/s there is 0.3 g and 23 is 0.65, and as the drive stops at 24 m/s only a drop feeds it while the overspeed drag bleeds it (a metre of drop buys 0.4 m/s at 34, a level metre costs 0.1): a 32 m drop at 30° gives 36.7 m/s at the foot and 22.8 at the top at 0.7 g, the bank cut for it (vd 36).
Cell: the speed at the foot (it changes on the 12 m before it), the furthest from the middle (m) and, when through, the exit speed. through, grounded all the way through, but airborne for a moment fell or stuck. Click a cell for its run.
One run
"corkscrew <radius> <length>" then any of "vd <speed>" (the bank's rated speed; 0: no bank, the up towards the axis), "w <width>", "ramp <0-0.5>" (0: a pure helix, its ends yawed), "heart <m>" (0: the road rolls about the bed), "drive <0-1>" (the bank's speed profile: 0 for a coasting ball), "drop <m>" (a run-up before the run-in, as the loop's but with eased vertical curves, the pitch a smoothstep of the distance so the slope and its curvature change continuously: the Drive tab starts at its top; 10 m gives 28 m/s at the foot, 6 gives 26), "slope <deg>" (the drop's slope, 20 by default: steeper, a drop is shorter and bleeds less to the overspeed drag), "run <m>" (the level run-in, 60 by default: a long one bleeds speed above the drive's 24 m/s), "left".
Segments
Four road pieces Rollball may get, each on a sampled heartline (the ball's centre line) banked for the felt force at the speed a ball driven flat out from its run-up has, and ridden on its smooth surface (segs_world.h; the Drive tab draws the mesh, the ball steps on the surface). The wall ride: a level turn whose bank is turned on to a vertical wall at the middle (gravity slides the ball down the wall; a driver steers up: the steer needed is g over 0.76 × the load, 0.57 of full steer at 2.3 g). The dive turn: half a corkscrew to inverted, then half a loop nose over to a lower road heading back, beside the entry. The tube: a round tube the ball can ride anywhere inside, through a falling turn: it swings up the outside wall to where the felt force points. The jump: an eased kicker, a gap, a straight landing ramp tangent to the ballistic arc of the profile's lip speed (so the rated ball lands tangent; the shell must pass over the ramp's start: under the heartline there, the ramp's leading edge catches it and the engine pushes it out, which reads soft but flings the body), then a pull-out. Each run starts 12 m before the foot at the speed of its column, rolling, coasting to the foot, then driven as chosen. Each kind's first track is its golden piece: the default here, and the one ./segs --check drives from its start.
Cell: the speed at the foot, the load range (g) and the piece's own measure. through, grounded all the way through, but airborne or off the middle for a moment fell, out or stuck. Click a cell for its run.
One run
"wallride <radius> <turn deg>" with "bank <deg>" (90: vertical at the middle), "ease <0.1-0.5>"; "diveturn <cork radius> <cork length> <loop radius>" with "shift <m>"; "tube <radius> <turn deg> <turn radius>" with "fall <m>" and a trailing "s" (an S-bend); "jump <kick deg> <gap>" with "kick <m>", "land <m>", "pull <m>". Every one takes "vd <m/s>" (the rated speed at the foot the bank is cut for), "drop <m>", "slope <deg>", "run <m>", "w <m>", "left" / "right" (as the corkscrew's).