Trigger brush: Difference between revisions
Jump to navigation
Jump to search
Note:The brush is fully solid unlike other trigger entities.
No edit summary |
No edit summary |
||
| Line 21: | Line 21: | ||
==Keyvalues== | ==Keyvalues== | ||
{{KV EnableDisable}} | |||
{{KV BaseEntity|brush=1}} | {{KV BaseEntity|brush=1}} | ||
==Inputs== | ==Inputs== | ||
{{I EnableDisable}} | |||
{{I BaseEntity}} | {{I BaseEntity}} | ||
==Outputs== | ==Outputs== | ||
Revision as of 10:08, 20 October 2018
Template:Base brush Fires an output when given a special targetname in response to player events.
For example, when a player dies, a Use input is sent to any trigger_brush named game_playerdie. The trigger_brush will fire OnUse in response.
Targetnames
The following targetnames are available for trigger_brush.
game_playerdie- Fires every time a player dies. The player who died is the !activator.game_playerkill- Fires every time a player kills another player, the killer is the !activator.game_playerjoin- Fires every time a player joins the game, the joining player is the !activator.game_playerspawn- Fires every time a player spawns, the spawning player is the !activator.
Bug:game_playerspawndoes not function in
and
. [todo tested in ?]game_playerleave- Fires every time a player leaves the game, !activator will not work in this case as the player entity no longer exists.
FGD Code
@SolidClass base(Targetname, Parentname, Global, EnableDisable) = trigger_brush [ input Use(void) : "Fires the OnUse output." output OnUse(void) : "Fired when the Use input is given." ]
Keyvalues
- Start Disabled (StartDisabled) <boolean>
- Stay dormant until activated (with the
Enableinput).
Inputs
EnableDisable:
- Enable / Disable
- Enable/disable this entity from performing its task. It might also disappear from view.
Outputs
- OnUse
- Fired when the
Useinput is given.