Auto Updater..
#1

Hello, I have attempted to make an auto updater for the players scores and to set the world time, my code just doesn't seem to work, it prints out the time like I have scripted it to:

pawn Код:
forward secondupdater(playerid);
public secondupdater(playerid)
{
    new hour, minute, second;
    gettime(hour, minute, second);
    if(minute == 60 && second == 0)
    {
        hour++;
        SetPlayerScore(playerid, GetPlayerScore(playerid) + 1);
        SetWorldTime(hour);
        if(hour == 24)
        {
            hour = 0;
        }
    }
    printf("Hour: %d, Minutes: %d, Seconds: %d.", hour, minute, second);
    if(minute == 60 && second == 0)
    {
        printf("New Hour: %d.", hour);
    }
    return 1;
}
I just don't understand it, should it be a SetTimer or SetTimerEx also?
Reply


Messages In This Thread
Auto Updater.. - by Luis- - 19.07.2011, 12:49
Re: Auto Updater.. - by Famalamalam - 19.07.2011, 12:52
Re: Auto Updater.. - by Luis- - 19.07.2011, 12:58
Re: Auto Updater.. - by Famalamalam - 19.07.2011, 13:25
Re: Auto Updater.. - by Luis- - 19.07.2011, 13:29
Re: Auto Updater.. - by Famalamalam - 19.07.2011, 13:43
Re: Auto Updater.. - by wups - 19.07.2011, 14:47
Re: Auto Updater.. - by Famalamalam - 19.07.2011, 14:49

Forum Jump:


Users browsing this thread: 1 Guest(s)