Hud timer: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (Combined description)
No edit summary
Line 1: Line 1:
{{wrongtitle|title=hud_timer}}
{{Synergy}} '''hud_timer''' is a [[point entity]] available in [[Synergy]].
{{Synergy}} '''hud_timer''' is a [[point entity]] available in [[Synergy]].
It displays a timer on every player's [[HUD]]. Similar to [[logic_timer]] -- displays a [[HUD]] element to all players showing the value, often counting down to an event.
It displays a countdown timer on every player's [[HUD]] and fires an output once reaching zero.
{{tip|This is the same [[HUD]] element used during the "Waiting for Players" event before level transitions.}}
{{tip|This is the same [[HUD]] element used during the "Waiting for Players" event before level transitions.}}
[[Image:Synergy_hud_timer_levelchange.jpg|thumb|right|300px|hud_timer example. '''TimerText''' set to "LEVEL CHANGE"]]


==Keyvalues==
==Keyvalues==
{{KV|TimerType|choices|Counter Type}}
{{KV|TimerType|choices|Keep this set to 'Count Down Timer'(1) Other types not yet supported.}}
: 0 : Count Up. {{confirm}}
: 1 : Count Down.
{{KV|TimerText|string|Text to display when this timer is visible.}}
{{KV|TimerText|string|Text to display when this timer is visible.}}
{{tip|Try to keep the text under ~25 characters to avoid protruding text out of the HUD's frame. (ends will not be visiable)}}
{{KV Targetname}}
{{KV Targetname}}


==Inputs==
==Inputs==
; <code>Start <[[int]]></code>
{{IO|Start|Start the timer with a specified duration of seconds.|param=int}}
: Start the timer with a specified duration of seconds.
{{IO|Stop|Stop the timer instantly, without triggering the OnTimer output.}}
{{IO|Stop|Stop the timer instantly, without triggering the OnTimer output.}}
; <code>Change <[[int]]></code>
{{IO|Change|Update the timer time - value is added to current timer time; allows positive and negative values.|param=int}}
: Update the timer time - value is added to current timer time; allows positive and negative values.
{{I Targetname}}
{{I Targetname}}


Line 23: Line 22:


==See also==
==See also==
*[[Synergy_Entities]]
*[[Synergy_Entities|Synergy Entity List]]

Revision as of 11:11, 7 November 2011

Template:Wrongtitle Synergy hud_timer is a point entity available in Synergy. It displays a countdown timer on every player's HUD and fires an output once reaching zero.

Tip.pngTip:This is the same HUD element used during the "Waiting for Players" event before level transitions.
hud_timer example. TimerText set to "LEVEL CHANGE"

Keyvalues

TimerType ([todo internal name (i)]) <choices>
Keep this set to 'Count Down Timer'(1) Other types not yet supported.
TimerText ([todo internal name (i)]) <string>
Text to display when this timer is visible.
Tip.pngTip:Try to keep the text under ~25 characters to avoid protruding text out of the HUD's frame. (ends will not be visiable)
Name (targetname) <string>[ Edit ]
The name that other entities refer to this entity by, via Inputs/Outputs or other keyvalues (e.g. parentname or target).
Also displayed in Hammer's 2D views and Entity Report.
See also:  Generic Keyvalues, Inputs and Outputs available to all entities

Inputs

Start <integerRedirectInput/integer>
Start the timer with a specified duration of seconds.
Stop
Stop the timer instantly, without triggering the OnTimer output.
Change <integerRedirectInput/integer>
Update the timer time - value is added to current timer time; allows positive and negative values.


Outputs

OnTimer
Fired when the timer reaches zero.


See also