Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- new iPlayers = 1;
- public OnPlayerDisconnect( playerid, reason )
- {
- static sStr[128];
- if(reason == 0)
- {
- format(sStr,sizeof(sStr), "%s saiu do servidor (Crash)! [%d/%d]",GetPlayerNick(playerid),iPlayers,GetMaxPlayers());
- }
- if(reason == 1)
- {
- format(sStr,sizeof(sStr), "%s saiu do servidor (Vontade Própria)! [%d/%d]",GetPlayerNick(playerid),iPlayers,GetMaxPlayers());
- }
- if(reason == 2)
- {
- format(sStr,sizeof(sStr), "%s saiu do servidor (Kickado/Banido)! [%d/%d]",GetPlayerNick(playerid),iPlayers,GetMaxPlayers());
- }
- SendClientMessageToAll(0xFFFFFFFF,sStr);
- return iPlayers--;
- }
- public OnPlayerConnect( playerid )
- {
- return iPlayers++;
- }
- stock GetPlayerNick(i)
- {
- static sStr[MAX_PLAYER_NAME];
- GetPlayerName(i,sStr,MAX_PLAYER_NAME);
- return sStr;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement