08.04.2017, 12:15
Don't use
it will not increment the player's score it will initialize the score and then set it to deathcount
for example if you killed 4 players and you had 5 score you score will be 4 not 9
Quote:
|
new deathcount; public OnPlayerDeath(playerid, killerid, reason) { if (IsPlayerInArea (playerid, ...)) { deathcount++; if(killerid != INVALID_PLAYER_ID) { SetPlayerScore (killerid, deathcount); } } return 1; } |
for example if you killed 4 players and you had 5 score you score will be 4 not 9
Quote:
|
if(killerid != INVALID_PLAYER_ID) { new Score = GetPlayerScore(killerid) + 1; SetPlayerScore (killerid, Score); } |

