logo
By Lawrence

16 minutes

Weapons Truck

Your oil slicks and smoke screens from lesson 2.3 run out. Drop the last one and Q or R goes quiet for good. Nothing on the road refills them, and your gun stays at one barrel.

This lesson brings a weapons truck up the road. Drive into the back of its trailer flat out, and it swallows your car, fits a refit (more ammo, a better gun or repairs), and lets you out of the tail.

Thick gates

You dock by driving in through the trailer's doors. The game checks for that once a frame, and between checks your car jumps forward.

Flat out, your car does 52 m/s, and the truck cruises at 30:

closing speed    52 − 30 = 22 m/s
one frame        22 ÷ 60 = 0.37 m at 60 fps

A doorway as thin as a line would almost never catch you, because the nose is in front of it on one frame and past it on the next. So the game checks a gate instead: a box behind the doors that the nose has to be inside. A gate you pass through must be thicker than one frame's step, so that some frame lands in it:

frames inside ≈ depth ÷ step = 3 ÷ 0.37 ≈ 8

Continue reading

Unlock the Full Course

Every lesson, the runnable examples, and the finished build — yours to keep.

$9one-time

Was this page helpful?

We read every note — tell us what's working and what isn't.

↑↓ NavigateEnter SelectEsc CloseCtrl+K Open Search