Jails are marked by a JBInfoJail actor that is placed in a distinct zone in a map. Release switches are simple triggers connected to a JBInfoJail actor. Here's how it works:
- Teams
- Jails are generic now. That means the jail itself can hold players of any team – if a red player accidentally walks into the blue jail, that's just tough luck and he'll be considered just as jailed as everybody else in that jail.
- PlayerStarts
- Whether it's effectively a jail for the blue or the red team is decided by the TeamNumber property of the (regular) PlayerStarts you put in there. (In fact, there's no reason why a single jail shouldn't hold players of both teams.) There is no special class of PlayerStarts for jailed players; the game is smart enough to figure out by itself that jailed players are to be spawned in jail and free players not.
- Release Switches
- Release triggers are simple, regular triggers that directly trigger the JBInfoJail actor. Depending on who touched a release trigger, the JBInfoJail actor in turn fires either the event specified in EventReleaseRed or EventReleaseBlue. Use the appropriate event to actually open the jail doors (or whatever mechanism you devised to release the team). You can also use any subclass of GameObjective instead of a simple trigger, for instance DestroyableObjective or LockedObjective. For the standard Jailbreak look, we provide JBGameObjectiveSwitch.
- Execution Sequence
- Before the execution sequence starts, the players of the capturing team are teleported out of jail (just in case you happen to have jails containing players of both teams). Then, the events specified in EventExecutionInit, EventExecutionCommit and EventExecutionEnd are fired in this sequence as detailed in the property descriptions for JBInfoJail. Executed players don't have to remain in jail during the execution sequence, so there's no problem with dropping them out of jail into a lava pit or something like that.
- Execution Camera
- Every jail has one (or more) execution cameras attached to it via the JBInfoJail's Event and the camera's Tag.
Since JBInfoJail isn't a ZoneInfo subclass itself, you can make any zone a jail by simply dropping a JBInfoJail actor in it. Of course that also applies to zones that provide some sort of fancy execution effect when triggered, such as the ever-popular pressure zones.
Quick Guide to Making a Jail
Here's a quick guide to making a jail for one team in a map, including a release door, release switch and an execution camera for the capturing team:
- Create an area that is properly zoned off from the rest of the map.
- Place a JBInfoJail actor in that zone.
- Add PlayerStarts in that zone and set their TeamNumber property.
- Add a mover for a release door. Set the JBInfoJail actor's EventReleaseRed or EventReleaseBlue property (depending on which team you want to release through this door) to the same arbitrary string as the mover's Tag property. Set the door's MoverEncroachType property to CrushWhenEncroach.
- To path the door for bots,
- Add a Door actor (extends NavigationPoint) in the middle of the static mesh used for the door (but low enough to touch the ground). Set its bBlockedWhenClosed property to True and its DoorTag property to the mover's Tag.
- If a jail has multiple paths to freedom with individual doors, don't trigger those movers and Door actors with the same Tag. Instead, chain the movers by their OpeningEvent event. See clarification at the bottom of this page for assistance.
- Somewhere else in your map, add a trigger and set its Event property to the same arbitrary string as the JBInfoJail actor's Tag property. The JBInfoJail actor should be connected to the trigger by a red line then. If you want something fancier than a plain trigger, see below.
- Add a JBCamera actor at a nice place and justify it for a nice view. Set its Tag property to the same arbitrary string as the JBInfoJail actor's Event property. (The JBInfoJail actor and the JBCameraExecution actor should be connected by a red line then.)
Quick Guide to Making a Release
- Add a JBGameObjectiveSwitch. This is the standard Jailbreak release switch, but you can use any subclass of GameObjective or Trigger to make other types of release switch.
- Set its Event property to match the Tag of a JBInfoJail actor
- Set its DefenderTeamIndex property to the Team number of the team that defends this switch.
Setting up Multiple Jail Escape Movers with the OpeningEvent
- Place the first mover which will move when the release switch is activated. Set the InitialStage in the Object property of the mover, and set up the appropriate mover Base's.
- Make the Events > Tag of this first mover to whatever the JBInfoJail triggers. For this clarification, the JBInfoJail will fire OpenDoor1.
- In the MoverEvents > OpeningEvent property, set it to something like OpenDoor2.
- Make your second mover like the first, but set the Tag to OpenDoor2 and the MoverEvents > OpeningEvent property to OpenDoor3.
- Below is a mathematical sequence where N equals 1. In practice, do the simple maths rather than leaving the brackets and N in! My examples are given in green
- JBInfoJail > Events > EventReleaseRed or EventReleaseBlue > OpenDoorN (eg OpenDoor1)
- Mover1 > Events > Tag > OpenDoorN (eg OpenDoor1)
- Mover1 > MoverEvents > OpeningEvent > OpenDoor(N+1) (eg OpenDoor2)
- Mover2 > Events > Tag > OpenDoor(N+1) (eg OpenDoor2)
- Mover2 > MoverEvents > OpeningEvent > OpenDoor(N+2) (eg OpenDoor3)
- Mover3 > Events > Tag > OpenDoor(N+2) (egOpenDoor3)
- Mover3 > MoverEvents > OpeningEvent > OpenDoor(N+3) (eg OpenDoor4)
- ...and so on.