Help with total accounts plz
#5

If you are using a filterscript

pawn Код:
new total_account; // at top of your script

public OnFilterScriptInit()
{
    new File:totalAccount=fopen("totalAccount.ini", io_write);
    if(!fexists(totalAccount)
    {
        fwrite(totalAccount, "total accounts = 0");
        fclose(totalAccount);
    }
    return 1;
}

public OnFilterScriptExit()
{
    new insert[50];
    new File:totalAccount=fopen("totalAccount.ini", io_write);
    format(insert, sizeof(insert), "total accounts = %d", total_account);
    fwrite(totalAccount, insert);
    fclose(totalAccount);
    printf("New amount of registered accounts: %d", total_account);
    return 1;
}
At the register command
pawn Код:
total_account++;
Reply


Messages In This Thread
Help with total accounts plz - by Honest_Player - 01.09.2011, 11:07
Re: Help with total accounts plz - by emokidx - 01.09.2011, 11:10
Re: Help with total accounts plz - by Honest_Player - 01.09.2011, 11:13
Re: Help with total accounts plz - by Improvement™ - 01.09.2011, 20:55
Re: Help with total accounts plz - by Pinguinn - 01.09.2011, 21:17
Re: Help with total accounts plz - by Honest_Player - 02.09.2011, 16:46
Re: Help with total accounts plz - by Honest_Player - 02.09.2011, 22:14
Re: Help with total accounts plz - by VIZ3N - 03.06.2013, 01:35

Forum Jump:


Users browsing this thread: 2 Guest(s)