Code:
float time = 1652 / 100.0;

int hours = (int)time;
int minutes = (time - hours) * 100;



hours is 16, minutes is 52.
Also, you are doing time calculation and storage wrong. What you really want is a variable that accumulates time in the smallest unit that you want to store and then calculate the time of day from there.


Also, Dico, I like your way of opening doors with tanks. All kidding aside, how are you going to take care of things like kerning with that?


Shitlord by trade and passion. Graphics programmer at Laminar Research.
I write blog posts at feresignum.com