Value raises every second?
#6

Quote:
Originally Posted by [B2K
Hustler ]
I didn't use the line you gave but something simple like this?
pawn Код:
#define MAX_NUMBER 200 //change to the max number so number starts recounting from 0
new Number = 0;

SetTimer("IncreaseNumber",1000, true);

public IncreaseNumber()
{
    if(Number >= MAX_NUMBER)Number = 0;
    else Number++;
}
It doesn't work :\

I use it like this:
pawn Код:
#define MAX_TIMER 200

new TutTime = 0;
new TimerOfTut; //For killing timer when tutorial is ended

public TutTimer()
{
    if(TutTime >= MAX_TIMER)TutTime = 0;
    else TutTime++;
}

TimeOfTut = SetTimer("TutTimer",1000,true); // I tried without TimeOfTut - still doesn't work

if (TutTime == 0)
                {
                    SystemMsg(playerid,"Welcome to San Fierro!");
                                       
                }
                if (TutTime == 7)
                {
                    SystemMsg(playerid," ");
                    SystemMsg(playerid," ");
                }
                if (TutTime == 10)
                {
                    SystemMsg(playerid,"This is a RolePlay server which means you have to act like in real life.");
                    KillTimer(TimerOfTut);
                }
What's wrong with this.....
(It compiles without errors....)
Reply


Messages In This Thread
Value raises every second? - by SiJ - 27.05.2009, 09:41
Re: Value raises every second? - by member - 27.05.2009, 10:08
Re: Value raises every second? - by SiJ - 27.05.2009, 10:25
Re: Value raises every second? - by lol2112 - 27.05.2009, 11:05
Re: Value raises every second? - by SiJ - 27.05.2009, 11:58
Re: Value raises every second? - by SiJ - 27.05.2009, 14:27
Re: Value raises every second? - by lol2112 - 27.05.2009, 14:41
Re: Value raises every second? - by SiJ - 27.05.2009, 14:45
Re: Value raises every second? - by SiJ - 27.05.2009, 16:52
Re: Value raises every second? - by SiJ - 28.05.2009, 13:45

Forum Jump:


Users browsing this thread: 2 Guest(s)