13.07.2012, 02:43
I think I did something, that is kinda.. working.
I have this piece of code.
minutes[playerid] = seconds[playerid]/60;
seconds[playerid] %= 60;
format(stringlolo,sizeof(stringlolo),"Paused - %d:%02d",minutes[playerid],seconds[playerid]);
Pausetext[playerid] = Create3DTextLabel(stringlolo,0x640000FF,X, Y, Z,15.0,0);
seconds[playerid]++;
Then
format(stringlolo,sizeof(stringlolo),"Paused - %d:%02d",minutes[playerid],seconds[playerid]);
Update3DTextLabelText(Pausetext[playerid],0x640000FF,stringlolo);
seconds[playerid]++;
But I have a little problem, when the seconds reach 60, the minutes go to 1 like normally, but when the seconds go to 1 again, the minutes go back to 0 and I dont know why.
I want it so the minutes show too, but it seems not to be working.
Somebody please help, thanks for your reply RoXor btw, it helped me.
I have this piece of code.
minutes[playerid] = seconds[playerid]/60;
seconds[playerid] %= 60;
format(stringlolo,sizeof(stringlolo),"Paused - %d:%02d",minutes[playerid],seconds[playerid]);
Pausetext[playerid] = Create3DTextLabel(stringlolo,0x640000FF,X, Y, Z,15.0,0);
seconds[playerid]++;
Then
format(stringlolo,sizeof(stringlolo),"Paused - %d:%02d",minutes[playerid],seconds[playerid]);
Update3DTextLabelText(Pausetext[playerid],0x640000FF,stringlolo);
seconds[playerid]++;
But I have a little problem, when the seconds reach 60, the minutes go to 1 like normally, but when the seconds go to 1 again, the minutes go back to 0 and I dont know why.
I want it so the minutes show too, but it seems not to be working.
Somebody please help, thanks for your reply RoXor btw, it helped me.