10.09.2011, 13:49
pawn Code:
if(Tsec<10) { // This Adds a 0 Before The Mins Display For it To look like an actual clock
//formats string
format(string,sizeof(string),"%d:%d0",THrs,Tsec);
}
if(Tsec>10) { // This Removes a 0 Before The Mins Display after it has reached 10
//formats string
format(string,sizeof(string),"%d:%d",THrs,Tsec);
}
if(THrs<10) {
//formats string
format(string,sizeof(string),"0%d:%d",THrs,Tsec);
}
Change the '%d' to '%02d'. This will show the 0 in front of the (1-9) in the minutes, aswell as the hours.