GameTextForPlayer

GameTextForPlayer

Description:
Function GameTextForPlayer shows 'game text' (on-screen text) for a certain length of time for a specific player.


Parameters:
(playerid, string[], time, style)
int playerid The ID of the player to show the gametext for.
string string The text to be displayed.
int time The duration of the text being shown in milliseconds.
int style The style of text to be displayed.


Return Values:
  • 1: The function was executed successfully. Success is reported when the style and/or time is invalid. Nothing will happen though (no text displayed). May also cause game crashes.
  • 0: The function failed to execute. This means either the string is null or the player is not connected.


Examples:
public OnPlayerDeath(playerid, killerid, reason)
{
    GameTextForPlayer(playerid, "Wasted", 5000, 2);
    return 1;
}


Related Functions
The following functions may be useful, as they are related to this function in one way or another.