Help with a public function.
#3

pawn Код:
new Seconds = 59;
new Minutes = 4;

public GameTime(playerid)
{
    if(Seconds || Minutes) {
        Seconds--;
        if(Seconds <= -1) {
            Minutes--;
            Seconds=59;
        }
        new TimeString[128];
        format(TimeString, 128, "~Y~~H~TIME LEFT: %02d:%02d", Minutes, Seconds);
        PlayerTextDrawSetString(playerid, Textdraw0[ playerid ], TimeString);
    }

    return 1;
}

SetTimer("GameTime", 1000, true);
The timer is set in ongamemodeinit and it's set to 1000 to update the TD..
Reply


Messages In This Thread
Help with a public function. - by Strier - 26.05.2013, 07:18
Re: Help with a public function. - by Revo - 26.05.2013, 07:39
Re: Help with a public function. - by Strier - 26.05.2013, 07:45
Re: Help with a public function. - by Strier - 26.05.2013, 17:53
Re: Help with a public function. - by Vince - 26.05.2013, 18:07
Re: Help with a public function. - by Strier - 26.05.2013, 23:39

Forum Jump:


Users browsing this thread: 1 Guest(s)