Env hudhint: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
No edit summary
(You CAN make localized text if you insert the aforementioned string as what to localize.)
Line 1: Line 1:
{{base point|env_hudhint}} It is used to control the display of HUD hints, which show the player what key is bound to a particular command.
{{base point|env_hudhint}} It is used to control the display of HUD hints, which show the player what key is bound to a particular command.


{{bug|{{css}} It seems that this entity has some difficulties to work correctly for raw text under Counter-Strike Source. It will not show the text unless the player is at the origin of the I/O chain. For example, if a player touches a [[Trigger_multiple|trigger_multiple]] who trigger the env_hudhint, it will works but if a [[Logic_auto|logic_auto]] would have been used to trigger it, it would not. Keep in mind that the env_hudhint will show his text only to player(s) who trigger it. In other word, the !activator must be the player.}}
{{bug|{{css}} It seems that this entity has some difficulties to work correctly for raw text under ''Counter-Strike Source''. It will not show the text unless the player is at the origin of the I/O chain. For example, if a player touches a [[trigger_multiple]] who trigger the env_hudhint, it will works but if a [[logic_auto]] would have been used to trigger it, it would not. Keep in mind that the env_hudhint will show his text only to player(s) who trigger it. In other word, the !activator must be the player.}}


== Keyvalues ==
==Keyvalues==
{{KV|Hint Text (localized)|string|This should be match a HUD hint entry in <code>hl2\resource\[[valve_english.txt]]</code> or its localized equivalent. Example: entering "<kbd>Valve_Hint_Zoom</kbd>" will display the following hint text: "%+zoom% ZOOM VIEW", with %+zoom% being the key currently bound to the zoom function. {{warning|Entering an unlocalized text as a hint will work, though when used in a mod you cannot make it language-specific!}}}}
{{KV|Hint Text (localized)|string|This should be match a HUD hint entry in <code>hl2\resource\[[valve_english.txt]]</code> or its localized equivalent. Example: entering "<kbd>#Valve_Hint_Zoom</kbd>" will display the following hint text: "%+zoom% ZOOM VIEW", with %+zoom% being the key currently bound to the zoom function. {{warning|Entering an unlocalized text as a hint will work, though when used in a mod you cannot make it language-specific unless you make localized text for the specified name!}}}}
{{KV Targetname}}
{{KV Targetname}}


== Inputs ==
==Inputs==
{{IO|ShowHudHint|Shows the hint message.}}
{{IO|ShowHudHint|Shows the hint message.}}
{{IO|HideHudHint|Hides the hint message.}}
{{IO|HideHudHint|Hides the hint message.}}
{{I Targetname}}
{{I Targetname}}


== Outputs ==
==Outputs==
{{O Targetname}}
{{O Targetname}}


== See also ==
==See also==
* [[env_message]] - A similar entity that displays other predefined messages on the screen.
* [[env_message]] - A similar entity that displays other predefined messages on the screen.


[[Category:GUI Entities]]
[[Category:GUI Entities]]

Revision as of 16:45, 15 July 2017

Template:Base point It is used to control the display of HUD hints, which show the player what key is bound to a particular command.

Icon-Bug.pngBug:Counter-Strike: Source It seems that this entity has some difficulties to work correctly for raw text under Counter-Strike Source. It will not show the text unless the player is at the origin of the I/O chain. For example, if a player touches a trigger_multiple who trigger the env_hudhint, it will works but if a logic_auto would have been used to trigger it, it would not. Keep in mind that the env_hudhint will show his text only to player(s) who trigger it. In other word, the !activator must be the player.  [todo tested in ?]

Keyvalues

Hint Text (localized) ([todo internal name (i)]) <string>
This should be match a HUD hint entry in hl2\resource\valve_english.txt or its localized equivalent. Example: entering "#Valve_Hint_Zoom" will display the following hint text: "%+zoom% ZOOM VIEW", with %+zoom% being the key currently bound to the zoom function.
Warning.pngWarning:Entering an unlocalized text as a hint will work, though when used in a mod you cannot make it language-specific unless you make localized text for the specified name!
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

ShowHudHint
Shows the hint message.
HideHudHint
Hides the hint message.


Outputs

See also

  • env_message - A similar entity that displays other predefined messages on the screen.