trigger_counter

From Valve Developer Community
Jump to navigation Jump to search
Obsolete-notext.png
This entity is obsolete. Its use is discouraged. It may only exist/function in older engine branches.
It has since been deprecated by: game_counter(not in Team Fortress Classic).
C++ Class hierarchy
CTriggerCounter
CBaseTrigger
CBaseToggle
CBaseAnimating
CBaseDelay
CBaseEntity
C++ triggers.cpp

trigger_counter is a brush entity available in all GoldSrc GoldSrc games. Also works as a logical entity. This entity counts the number of times it is used and activates its target when it reaches a specified number. Deprecated since Half-Life 1.0.0.9 by game_counter; mods released beforehand (such as Team Fortress Classic) may still require this entity.

Icon-Important.pngImportant: Although this entity inherits CBaseTrigger, it does not use InitTrigger(), so most trigger-based behavior won't work.
Confirm:Effectively a logical entity? Doesn't set model nor solidity.

Key Values

Target (target) <targetname>
The targetname of an entity this entity will trigger when activated.
Name (targetname) <string>
The targetname that other entities refer to this entity by, usually via the target, killtarget, and TriggerTarget KVs.
Kill target (killtarget) <targetname>
Remove this entity from the game on activation.
Target Path (netname) <targetname>
Master (master) <targetname>
Name of a master entity. If the master hasn't been activated, this entity will not activate.
Delay before trigger (delay) <string>
The time in seconds before the trigger should trigger its target (after being triggered itself).
Message (set sound too!) (message) <string>
Sound when triggered (noise) <sound>
Count before activation (count) <integer>
The number that the counter must reach before activating its targets.

Flags

No Message : [1]
Don't print "Quakesque" messages to the console when this entity is used.