16.06.2012, 20:20
(
Последний раз редактировалось Kindred; 16.06.2012 в 21:05.
)
pawn Код:
public OnRconLoginAttempt(ip[], password[], success)
{
if(success) //If the password was correct
{
new originalname[MAX_PLAYER_NAME], string[MAX_PLAYER_NAME]; //Creates the new variables
GetPlayerName(playerid, originalname, sizeof(originalname)); //Gets current name
format(string, sizeof(string), "(Admin)%s", originalname); //Adds (Admin) to the front of the name
SetPlayerName(playerid, string); //Sets the name to the new name
}
return 1;
}
Simply states that if the player attempts to log into rcon, and succeeds, it gets his current name and set's his name to (Admin), along with his originalname following it afterwards.
EDIT: Sorry, forgot there was no playerid parameter in here (they should have one)