Training annotation: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
(better bug info)
m (→‎Keyvalues: updated)
Line 4: Line 4:
An in-world location-specific information bubble.
An in-world location-specific information bubble.
==Keyvalues==
==Keyvalues==
{{KV Targetname}}
{{KV|Displayed text|string|intn=display_text|The text to be displayed in the annotation popup.}}
{{KV|Lifetime|float|intn=lifetime|How long should the annotation be shown in seconds. {{{lifetime add|}}}}}
{{KV|Lifetime|float|intn=lifetime|How long you want the annotation popup to stick around.  If set to 0, it will default to the value in code (1 sec).  If it set to -1, it will last forever.}}
{{Note|The fade-in effect when an annotation is shown does not work unless lifetime is set to -1}}
{{Note|The fade-in effect when an annotation is shown does not work unless lifetime is set to -1}}
{{KV|Vertical offset|float|intn=offset|The vertical offset.}}
{{KV BaseEntity|base=1}}
==Inputs==
==Inputs==
{{I Targetname}}
{{I Targetname}}

Revision as of 20:24, 27 April 2023

Team Fortress 2 training_annotation is a point entity available in Team Fortress 2 Team Fortress 2.

Entity description

An in-world location-specific information bubble.

Keyvalues

Displayed text (display_text) <string>
The text to be displayed in the annotation popup.
Lifetime (lifetime) <float>
How long you want the annotation popup to stick around. If set to 0, it will default to the value in code (1 sec). If it set to -1, it will last forever.
Note.pngNote:The fade-in effect when an annotation is shown does not work unless lifetime is set to -1
Vertical offset (offset) <float>
The vertical offset.


Inputs

Show
Shows the annotation bubble.
Icon-Bug.pngBug:Showing an annotation will print an error to console mentioning a missing sound file, the file path cannot be modified.  [todo tested in ?]
Hide
Hides the annotation bubble.
Warning.pngWarning:Hide does not work in multiplayer! Use the lifetime keyvalue if you want to use this entity outside of training mode.

Outputs