SpawnPlayer

From SA-MP Wiki

Jump to: navigation, search


Description:

(Re)Spawns a player.


Parameters:
(playerid)
playeridThe ID of the player to spawn.


Return Values:

  • 1: The function executed successfully.
  • 0: The function failed to execute. This means the player is not connected.


Image:32px-Ambox_warning_orange.png

Note

Kills the player if they are in a vehicle and then they spawn with a bottle in their hand.


Example Usage:

if (strcmp(cmdtext, "/spawn", true) == 0)
{
    SpawnPlayer(playerid);
    return 1;
}

Related Functions

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


Related Callbacks

The following callbacks might be useful, as they're related to this function in one way or another.

Personal tools
Navigation
Toolbox