27.04.2013, 10:06
pawn Код:
CMD:stats(playerid, params[])
{
if(IsPlayerConnected(playerid))
{
new
string[ 128 ],
Age = PlayerInfo[ playerid ][ pAge ],
Stress = PlayerInfo[ playerid ][ pStressweed ],
Money = GetPlayerCash( playerid )
;
new Sex[20];
if(PlayerInfo[ playerid ][ pSex ] == 1) { Sex = "Male"; }
else if(PlayerInfo[ playerid ][ pSex ] == 2) { Sex = "Female"; }
new Job[20];
if(PlayerInfo[ playerid ][ pJob ] == 0) { Job = "None"; }
else if(PlayerInfo[ playerid ][ pJob ] == 1) { Job = "Drugdealer"; }
SendClientMessage(playerid, COLOR_LIGHTBLUE, "------------------------------------------------------------------------");
format(string, sizeof(string), "Name: %s | Money: %d | Age: %d | Sex: %s | Stress: %d | Job: %d", RPName(playerid), Money, Age, Sex, Stress, Job);
SendClientMessage(playerid, COLOR_GRAD2, string);
}
return 1;
}