07.11.2011, 12:09
Hi all I have a problem when i do score in my server And then exit it and connect again my score is 0 why ?? Please Helpp
public OnPlayerDisconnect(playerid, reason) { new string[64], name[MAX_PLAYER_NAME]; GetPlayerName(playerid,name,MAX_PLAYER_NAME); switch(reason) { case 0: format(string,sizeof string,"%s left the server. (Timed out)",name); case 1: format(string,sizeof string,"%s left the server. (Leaving)",name); case 2: format(string,sizeof string,"%s left the server. (Kicked/Banned)",name); } SendClientMessageToAll(0xFFFFFFAA,string); } return 1; }
Here is my code:
Код:
public OnPlayerDisconnect(playerid, reason) { new string[64], name[MAX_PLAYER_NAME]; GetPlayerName(playerid,name,MAX_PLAYER_NAME); switch(reason) { case 0: format(string,sizeof string,"%s left the server. (Timed out)",name); case 1: format(string,sizeof string,"%s left the server. (Leaving)",name); case 2: format(string,sizeof string,"%s left the server. (Kicked/Banned)",name); } SendClientMessageToAll(0xFFFFFFAA,string); } return 1; } |