World and levels › Space and combat
Level scripting: triggers, doors and scenes
Know first: Blockout: a world of boxes
This lesson is about how a level responds to the player: zones that start events when the player walks in, doors and elevators, enemies that arrive on cue, short scenes. At the center of it is one question: how to make a script survive a player who comes the wrong way. In the demo you’ll choose where a trigger for an ambush goes and send the player along two routes.
Why this matters
A level built from walls and floors is a stage with no performers. Scripts make things happen in it. A door opens when a fight ends, a bridge falls behind the player, a guard says a line as the player passes. They also cause some of the worst bugs a level can have. A player who comes in through a window instead of the door may never start the fight that unlocks the exit, and then they are stuck for good. A script is only as good as its handling of the players who don’t do what the designer expected.