Es msg

From EventScripts Community Encyclopedia


Overview

Syntax: es_msg [color] <message>

Note: Command parameters are described inside the < and > characters. Optional parameters are contained within [ and ] characters.

Variation of this command that doesn't expand variables: es_xmsg

Description

Broadcasts a text message to the chat area for every client. In Counter-Strike: Source it includes options for coloring the text.

Parameters

  • color - the name of the color option. If not provided, the text is printed in the default color (yellow). The following color values are supported:
    • #green - the entire message is sent in green.
    • #lightgreen - the entire message is sent in light green (don't work for HL2DM)
    • #multi - allows the message to be multi-colored. To specify color, intersperse #default, #green, and #lightgreen throughout your message text and the text will change color accordingly.
  • message - the text message you wish to broadcast


Examples

// sends a single message to everyone
es_msg Hello World
 
// Announces the gravity value
es_msg The server's gravity is server_var(sv_gravity)
 
// Announces in light green (CS:S only)
es_msg #green Hello!
 
// Announces in multi-color
// outputs a multi-colored message
es_msg #multi Change to#green green then change to#default default, then change to#lightgreen light green.


Notes

  • Only colors #default and #green are working on HL2DM
  • Es_msg Can expand Server cvars.


See also

blog comments powered by Disqus