Ok so i am attempting to make a turn based tactical battle system in my game.
Right now each sprite has a timer instance variable and every tick a number is added to that variable (modified by the sprites speed), once that variable reaches a certain number (100) it is that sprites "turn".
I can handle all of that and get that to work right but i want to know if there is a way to display the next 5 sprites in order of how filled their turn timer is and how close they are to getting the next turn?
And then if a turn timer gets added to or subtracted to (like a spell boosting speed) have the order of displayed sprites change?
This would require me to compare the timers of all of the different sprites and im not exactly sure how to do that.