SetPlayerScore
From SA-MP Wiki
SetPlayerScore
Set a player's score.
(playerid, score)
| playerid | The ID of the player to set the score of. |
| score | The score to set the player's score to. |
This function does not return a specific value.
public OnPlayerDeath(playerid, killerid, reason) { // Add 1 to this killer's score. if(killerid != INVALID_PLAYER_ID) SetPlayerScore(killerid, GetPlayerScore(killerid) + 1); return 1; }
Related Functions
The following functions might be useful as well, as they're related to this function in one way or another.
- GetPlayerScore: Get the score of a player.
