Script (entity type)

Script Entities are used to add events to a level.

Door Unlock
Unlocks the linked doors. ShowMessage: If True, displays  on the HUD when triggered.

Door Open
Opens the linked doors. Doors opened by script do not automatically close. ShowMessage: If True, displays  on the HUD when triggered.

Activate Matcen
Causes linked Matcen entities to start producing Auto-Ops.

On Destroy
When the first linked entity is destroyed, triggers all other linked entities.

On Count
Triggers linked entities when this script is triggered a certain number of times. SpecialIndex: The number times the On Count must be triggered for it to activate.

Disable Shield
Removes shields from linked Invulnerable props, making them vulnerable again. ShowMessage: If True, displays  on the HUD when triggered.

Forcefield Disable
Deactivates linked forcefields. ShowMessage: If True, displays  on the HUD when triggered.

Reveal Robot
Shows an enemy or enemies. The robot's Hidden property should be marked as True

Door Lock
Closes and locks the linked doors. ShowMessage: If True, displays  on the HUD when triggered.

On Pickup
When the first linked entity is an Item and is picked up, triggers all other linked entities.

Lockdown Master
Used to create a Lockdown. The Lockdown starts when this Script is triggered, activating all linked s, s, and s. Delay: Maximum time between robots appearing. Robots will appear faster if none are active. SpecialIndex: Number of robots that appear when the lockdown is triggered.

Multiple Master scripts can be used on a single Box Trigger to allow more lights, doors, or robots to spawn in a given lockdown instance.

Lockdown Door
Linked doors are closed and locked at the start of the Lockdown, and opened at the end. Doors opened in this way do not automatically close.

Lockdown Light
Linked Emlight Om1 props are activated while the Lockdown is active.

An interesting feature is that this script isn't necessary at all: an active lockdown (normal or boss) will trigger all the Emlight Om1 entities in the level.

Lockdown Robot
Marks linked robots as part of the Lockdown. Linked robots should be set to Hidden, and will be revealed during the Lockdown. The order in which robots are revealed appears to be random.

Lockdown Boss
Marks the linked enemy as the boss for the Lockdown. As with Lockdown Robot, the boss entity should have its Hidden tag set to True.

Destroying a boss this way will trigger the  countdown as seen in the boss fights during the campaign.

Tutorial Message
Displays a tutorial message on the HUD. SpecialIndex: Determines which message is shown.

Activate Object
Activates a linked entity when triggered. However, their change in state is not stored in savegames.

Entities known to work with this script are:


 * Forcefield
 * Lights
 * Triggers

Deactivate Object
Deactivates a linked entity when triggered. This can disable forcefields, doors, and triggers for example. (See "Activate Object")

However, the entity's deactivated state will not be stored in savegames.

Robot Attack
Directs linked Auto-Ops to move towards the player.

Comm Message
Plays a comm message from the level's story text. SpecialIndex: Determines which message is shown. Indexes start at 1.

Teleport Out
Ends the level with a cutscene showing the player being teleported out.

On Robot Kills
Triggers linked entities when a certain number of Auto-Ops are destroyed. SpecialIndex: The required number of auto-ops to destroy.

Level1
Triggers linked entities based on destroyed Auto-Op count and player position. SpecialIndex: The required number of auto-ops to destroy. Entities are triggered as follows:
 * When the required number of auto-ops are destroyed, the first linked entity is triggered.
 * If the number of destroyed auto-ops is within 5 of the required number, and 5 minutes have passed, the second linked entity is triggered.
 * Shortly after triggering either of the first two linked entities: if the player's Y position is 10 units below this Script or higher, the fifth linked entity is triggered; otherwise, the third linked entity is triggered.
 * Afterwards, if the player's Y position eventually goes above that of this Script, the fifth linked entity is triggered.

Level16
Causes the player to start with level 2 security access. Does not need to be triggered. After overloading the reactor, this script will also play comm messages during the countdown:
 * Comm message 10 at 30 seconds left
 * Comm message 11 at 15 seconds left

Activate Alien Warp
Turns on linked Alien Warp props. Active Alien Warps end the level when entered.

Alien Door Link
Connects an Alien door with Alien Switches. The door should be the first link. The door will be open as long as any linked switch is active.

Secret Level
When triggered, sends the player to a Secret Level. To function correctly, it should be triggered by a Box Warper.

Fade Music
Causes level music to fade out.

Objective Message
Displays an objective on the HUD. SpecialIndex: Determines which objective is shown.