23.06.2010, 14:07
Sometime ago I did a race and that's what I used:
Race Starts:
Race ends:
Then you just format the values tmin, tsec, tmsec into a string with %d. Oryou can do w/e you want, like formating the number with %2d, etc.
Hope you understand.
Edit:
Race Starts:
pawn Код:
new tick;
tick = tickcount();
SetPVarInt(playerid, "RaceTime", tick);
pawn Код:
new tick, calc, tmin, tsec, tmsec;
tick = tickcount();
calc = tick - GetPVarInt(playerid, "RaceTime");
ConvertTime(calc, tmin, tsec, tmsec);
Hope you understand.
Edit:
pawn Код:
stock ConvertTime(Milliseconds, &rMin, &rS, &rMS) //don't know the creator
{
rMin = Milliseconds/60000;
Milliseconds -= rMin*60000;
rS = Milliseconds/1000;
Milliseconds -= rS*1000;
rMS = Milliseconds;
}

