22.12.2013, 22:42
Quote:
Hi, I'd like to present you OnPlayerAfk library and sample script use. Script: Код:
forward OnPlayerAfk(playerid, bool:afk); public OnPlayerAfk(playerid, bool:afk){ new string[30]; format( string, sizeof( string ), "Player %s (%d) %s", getPlayerNick(playerid), playerid, (afk==true)?("away from keyboard"):("Already returned") ); SendClientMessageToAll(0xFF00FF, string); } getPlayerNick( playerid ){ new pName[ MAX_PLAYER_NAME + 1]; GetPlayerName( playerid, pName, 30); return pName; } |