PHP код:
public OnPlayerSpawn(playerid)
{
//...
new str[128];
format(str, sizeof(str), "Matou: ~h~~g~%d", pStats[playerid][pMatou]);
PlayerTextDrawSetString(playerid, StatusMatou[playerid], str);
format(str, sizeof(str), "Morreu: ~h~~r~%d", pStats[playerid][pMorreu]);
PlayerTextDrawSetString(playerid, StatusMorreu[playerid], str);
//para quando ele nascer atualizar as TD
return 1;
}
public OnPlayerDeath(playerid, killerid, reason)
{
//...
new str[128];
format(str, sizeof(str), "Matou: ~h~~g~%d", pStats[playerid][pMatou]);
PlayerTextDrawSetString(playerid, StatusMatou[playerid], str);
format(str, sizeof(str), "Morreu: ~h~~r~%d", pStats[playerid][pMorreu]);
PlayerTextDrawSetString(playerid, StatusMorreu[playerid], str);
//Assim irar atualizar apenas quando ele morrer/matar alguem
return 1;
}