5 minutes
Catching up?
Dropping in at this lesson? One command reinstalls the library components the build uses so far and writes the scene as it stood at the end of the previous lesson to public/scenes/WingmanFlight2-lesson-3/scene.json:
Copy that scene.json over your src/scenes/wingman.json and you are caught up to the start of this lesson.
Last lesson you proved the collision works. You did it by hand-typing two throwaway boxes in local space. You tuned their half-extents until a tracer finally stopped. But those were just two non-critical boxes. A real fighter has a cockpit, two wings, engines, and a fuselage. Each part has its own HP and a flag for whether losing it kills the ship. Nobody wants to type that table by hand, and you would need one per enemy. Scene JSON also can't import a TypeScript PartDef[]. There is no way to hand a ship an array from a file. You want to write one word, like "this is a kilrathi fighter," and get the whole hitbox table for free.
Continue reading
Unlock the Full Course
Every lesson, the runnable examples, and the finished build — yours to keep.