Trigger Relay

trigger_relay is a triggering function in Sven Co-op. It has many uses: triggering of entities if direct methods are otherwise not desired (such as removing the !activator), when several triggers need to linked together as one, if the target entity needs to have a delay to be triggered or a wait period between triggers, or when the target entity should only be triggered once and never again by an activator entity (if the appropriate flag is set). It can also be used to delete entities using "killtarget". If several entities need to be triggered, use multi_manager.

'' { "classname" "trigger_relay" "targetname" "target_me" "target" "entity_a" "killtarget" "entity_b" "triggerstate" "0/1/2" "delay" "t" "m_flDelayBeforeReset" "t" "spawnflags" "s" } ''

Attributes
0 : "Off" 1 : "On" 2 : "Toggle" Warning: if this key is not explicitly set, the default value will be 0 which will trigger off the target entity. If an entity needs to be activated (which is most often the case) the triggerstate value must be explicitly set to 1.
 * Trigger State- "triggerstate" "0/1/2" : This defines how the target entity should be activated:
 * Delay- "delay" "t" : Time t in seconds before the relay triggers its target. If this attribute is not set, or the keyvalue is "0", the target entity will otherwise be triggered instantaneously. Note: the delay has no effect on "killtarget".
 * Wait- "m_flDelayBeforeReset" "t" : Time, in seconds, the trigger_relay can fire it's target again after being triggered.
 * Kill Target- "killtarget" " " : This will delete the entity with the targetname that is defined in this key, once the trigger_relay is activated. Use of this attribute is optional.

Flags
"spawnflags" "s", when s equals:
 * 1- Remove on fire : Setting this will delete the trigger_relay once it has activated its target successfully so that it cannot be used again.
 * 16- Keep !activator : This retains the original activator of the trigger_relay and passes it onto the relay's target entity. By default, the relay passes itself as the activator of the target entity when triggered.