Env message

It draws a text message on player HUDs, predefined in the /scripts/titles.txt file.
== Keyvalues ==
== Flags ==
== Inputs ==
== Outputs ==
== File format ==
Each message entry in titles.txt follows a similar structure as other Valve text files. Example: Title { Text Value }. The message can reference a localized string prefixed with #.
This text can be formatted in many different ways, according to the syntax provided. The resource/clientscheme.res is responsible for the font family, size and weight of the message. To change the size find CenterPrintText in the res file.
Variables can be defined which will affect all the messages below them, until overwritten with another value.
Varaible 	Parameters 	Description
$position 	float, float	Position of the text onscreen, represented as a range from 0-1. The first float is horizontal, with 0 being the left; the second is vertical, with 0 being the top. -1 is centered.
$effect 	integer 	How it is displayed. 0 is fade in/fade out, 1 is flickery credits, 2 is write out
$fxtime 	float 	When using the write out effect, this is the amount of time the highlight lags behind the leading edge of the text
$color 	R G B 	Color of the text as red-green-blue between 0-255
$color2 	R G B 	Highlight color used for the write out effect as characters are appearing
$fadein 	float 	Fade in time of message or each character in seconds
$fadeout 	float 	Fade out time in seconds
$holdtime 	float 	How long to wait after fade in before fade out
$boxsize 	float 	If non-zero, adds a background behind the text (like the HL2 'Saved' message). The size of the border is calculated as this value multiplied by the font height.
$boxcolor 	R G B A 	Color and opacity of the text background
$clearmessage	string 	Clears any existing message of the given name upon display. Set to 0 to disable.
If you make a standalone modification you can alter this file with your own entries. The default titles from HL2 are listed below:
Message Value 	Printed Text
CR1 	Testing 1
CR2 	Testing 2
CR3 	Testing 3
GAMEOVER_ALLY 	ASSIGNMENT: TERMINATED
SUBJECT: FREEMAN
REASON: FAILURE TO PRESERVE MISSION-CRITICAL PERSONNEL
GAMEOVER_OBJECT	ASSIGNMENT: TERMINATED
SUBJECT: FREEMAN
REASON: FAILURE TO PRESERVE MISSION-CRITICAL RESOURCES
GAMEOVER_TIMER 	ASSIGNMENT: TERMINATED
SUBJECT: FREEMAN
REASON: FAILURE TO PREVENT TIME-CRITICAL SEQUENCE
GAMEOVER_STUCK 	ASSIGNMENT: TERMINATED
SUBJECT: FREEMAN
REASON: DEMONSTRATION OF EXCEEDINGLY POOR JUDGMENT
CHAPTER1_TITLE 	POINT INSERTION
CHAPTER2_TITLE 	"A RED LETTER DAY"
CHAPTER3_TITLE 	ROUTE KANAL
CHAPTER4_TITLE 	WATER HAZARD
CHAPTER5_TITLE 	BLACK MESA EAST
CHAPTER6_TITLE 	"WE DON'T GO TO RAVENHOLM..."
CHAPTER7_TITLE 	HIGHWAY 17
CHAPTER8_TITLE 	SANDTRAPS
CHAPTER9_TITLE 	NOVA PROSPEKT
CHAPTER9A_TITLE	ENTANGLEMENT
CHAPTER10_TITLE	ANTICITIZEN ONE
CHAPTER11_TITLE	"FOLLOW FREEMAN!"
CHAPTER12_TITLE	OUR BENEFACTORS
CHAPTER13_TITLE	DARK ENERGY
GAMESAVED 	Saved...
GAMETITLE 	Half-Life
==Files==
# scripts/titles.txt
== See also ==
* - Similar entity that lets you define a text directly in the Hammer editor.
* - Similar entity that displays predefined HUD hints about controls and other things.
Category:GUI Entities
Category:Plain text formats