This article was converted from a previous version of TWHL and may need to be reviewed
- The formatting may be incorrect due to differences in the WikiCode processing engine, it needs to be revised and reformatted
- Some information may be out of date
- After the article is re-formatted and updated, remove this notice and the Review Required category.
- Some older articles are no longer useful, or they duplicate information from other pages. In this case, delete the page after merging any relevant information into other pages. Contact an admin to delete a page.
Point EntityThis entity is used to display messages on-screen. It is used instead of env_message because it doesn't need to a file full of message strings to be distributed with the map.
Attributes
- Name (targetname) - Property used to identify entities.
- Target (target) - When an entity is activated, it triggers the entity with the name specified by Target.
- Master (master) - The name of a multisource (or game_team_master) entity. A master must usually be active in order for the entity to work. Thus they act almost like an on/off switch, in their simplest form, and like an AND gate in the case of the multisource.
- Message Text (message) - The text to be displayed.
- X (0 - 1.0 = left to right, -1 = center) (x) - X position of text (across screen).
- Y (0 - 1.0 = top to bottom, -1 = center) (y) - Y position of text (up/down screen).
- Text Effect (effect) - Effect to apply to the text (0 = Fade In/Out, 1 = Credits, 2 = Scan Out).
- Color1 (color) - The main colour.
- Color2 (color2) - The highlight colour.
- Fade in Time (or character scan time) (fadein) - Time taken to fade in each character.
- Fade Out Time (fadeout) - Time taken to fade out message.
- Hold Time (holdtime) - Length of time to hold message on screen after fading in.
- Scan time (scan effect only) (fxtime) - The amount of time the highlight lags behind the leading edge of the text.
- Text Channel (channel) - Any of four channels can be used by this entity. If while one channel is being used another entity on the same channel is triggered, the old text will be cleared from the screen.
Flags
- All Players (1) - Show the text to all players. If not set, only the player who activated the game_text will see the message.
Inputs
Outputs
Notes
- You are limited to a maximum message length of 127 characters. Exceeding this can crash HL.
*
Line breaks can be added with the newline code ('n'). e.g. 'Line onenLine two'.
*
X, y, effect, color, color2, fadein, fadeout and fxtime are the same as those found in titles.txt.
*
The easiest way to get a text-based message at the start of your level, like the Black Mesa one from HL, is to add a trigger_auto to the level and set it's target to the name of your game_text. You might have to add a delay to the trigger, depending on wether you fade the screen in or not, but either way when the game starts your text will be displayed.
Decided to test for myself.
Vanilla Half-Life's text engine seem to be broken for anything that's not ASCII. It consumes single-byte character sets (presumably ANSI/Windows-1252/system locale) but the text rendering is consuming UTF-8. This results in the broken text consistent with the table in this page: https://www.i18nqa.com/debug/utf8-debug.html
Haven't looked at the other SDKs or engines (candidates include Updated/Unified/Featureful/Xash-fwgs/Pathos) on how they handle text. Hopefully better than the unrecoverable mess vanilla is in right now.
ALSO, JACK will purposefully mangle non-ASCII texts. You'd need to edit the .map directly and feed it to the compilers yourself.
2024-06-29
apparently HLCSG also needs
-notextconvert
argument. sauce: singularmurderertarget
attribute does not work. This entity can't trigger anything else.