mtl_trigger_area

An advanced variant of trigger_multiple, this brush entity can trigger different targets when a player enters, stays in and leaves an area. It can also be used to react to the movement of monsters and pushable objects.

Properties

  • Target on enter (on_enter) -- The name of the entity that will be triggered when the player enters the area.
  • Target on stay (on_stay) -- The name of the entity that will be triggered periodically while the player is inside the area.
  • Target on leave (on_leave) -- The name of the entity that will be triggered when the player leaves the area.
  • Interval (poll_interval) -- How often the trigger checks whether the player is still inside the area, and how often 'Target on stay' is triggered. The default (and minimum) is 0.2 seconds.
  • Master (master) -- The name of a multisource entity. If set, the trigger area will only work when the multisource is active.

Flags

  • React to monster movement (1) -- If enabled, the trigger area will also react to monster movement.
  • React to pushables movement (2) -- If enabled, the trigger area will also react to pushable objects.
  • Ignore players (4) -- If enabled, the trigger area will not react to players.

Notes

  • If the trigger area has a master, activating the master while the player is inside the area will trigger the 'enter target'. Likewise, deactivating the master while the player is inside the area will trigger the 'leave target'.
  • When dealing with multiple players, the 'enter target' is triggered when the first player enters the trigger area, and the 'leave target' is triggered when the last player leaves the trigger area. The 'stay target' is periodically triggered as long as at least one player is inside the area.
  • Monsters and pushables only activate triggers while they're moving. So if a monster or pushable stops moving while it's inside a trigger area, the 'leave target' will be triggered. When the monster or pushable starts moving again, the 'enter target' will be triggered.
  • This entity generates a single trigger_multiple and a fixed number of multi_manager, trigger_relay and trigger_changetarget entities.