Automatic save!!
#2

First, use the search button and read the rules, second, welcome.

Search in your GameMode something similar to this:
pawn Код:
accountstimer = SetTimer("SaveAccounts", 900000, 1); //15 mins every account saved
Change for the time do you need.

But if you want save when the player leaves the server, search in your gamemode OnPlayerDisconnect and put: SaveAccounts(); or your accounts variable.

If you want save with a command use this:
pawn Код:
if(strcmp(cmd, "/saveaccounts", true) == 0)
    {
        if (PlayerInfo[playerid][pAdmin] >= 2) // Change for your required level admin.
        {
            SaveAccounts(); // Change for your account variable.
            SendClientMessage(playerid, COLOR_YELLOW, "The Accounts saved correctly.");
        }
        else
        {
            SendClientMessage(playerid, COLOR_GRAD1, "  You are not autorized to use that command!");
        }
        return 1;
    }
Good Luck, and USE THE SEARCH BUTTON BEFORE POST.
Reply


Messages In This Thread
Automatic save!! - by MB@ - 24.08.2009, 09:20
Re: Automatic save!! - by Energyzer - 24.08.2009, 09:25
Re: Automatic save!! - by MB@ - 24.08.2009, 09:44
Re: Automatic save!! - by Energyzer - 24.08.2009, 09:53

Forum Jump:


Users browsing this thread: 1 Guest(s)