Saving my variable?
#1

I have this:

pawn Код:
new admin[MAX_PLAYERS];
pawn Код:
public OnPlayerConnect(playerid)
{
admin[playerid] = 0;
}
pawn Код:
if (strcmp("/makemeadmin", cmdtext, true) == 0)
{
    if (IsPlayerAdmin(playerid))
    {
        if (admin[playerid] == 1)
        {
            SendClientMessage(playerid,COLOR_RED,"You are already an admin!");
        }
        else
        {
            admin[playerid] = 1;
            SendClientMessage(playerid,COLOR_GREEN,"You became an admin!");
        }
    }
    else
    {
        SendClientMessage(playerid,COLOR_RED,"You must be logged on in RCON!");
    }
}
But how to: When he quits the variable saves. I searched but couldn't find anything good.
Reply


Messages In This Thread
Saving my variable? - by lawonama - 09.07.2011, 09:52
Re: Saving my variable? - by lawonama - 09.07.2011, 10:31
Re: Saving my variable? - by lawonama - 09.07.2011, 10:42
Re: Saving my variable? - by Pghpunkid - 09.07.2011, 10:44
Re: Saving my variable? - by jameskmonger - 09.07.2011, 10:45
Re: Saving my variable? - by lawonama - 09.07.2011, 10:48
Re: Saving my variable? - by lawonama - 09.07.2011, 10:52
Re: Saving my variable? - by lawonama - 09.07.2011, 11:38
Re: Saving my variable? - by Pghpunkid - 09.07.2011, 15:42
Re: Saving my variable? - by lawonama - 09.07.2011, 18:08

Forum Jump:


Users browsing this thread: 1 Guest(s)