Scripting/Squirrel/Functions/Misc/Message

From VC-MP Wiki

Jump to: navigation, search

This function sends a message to all the players in the game.

Syntax

bool Message( string text )

Arguments

  • text - This is the message to send to the player

Example

This will send a message saying 'Testing...' when somebody types '/c test'

function onPlayerCommand( player, cmd, text )
{
     if ( cmd == "test" )
     {
          Message( "Testing..." );
     }
}

Notes

The call onPlayerCommand was used in in this example. More info about this in the corresponding page.

Related Functions

Personal tools
squirrel scripting