Hello.
What I'm suggesting here is a GetTimer() function, which simply returns the number of cycles left on a timer. My reason for this is twofold. Firstly, sometimes you'll want to be able to do something in the middle of a timer, without setting up another timer. Secondly, it would provide a way to see whether or not a timer is running, without incurring the IsTimerExpired()'s OFF state.
Basically with that second reason, what I'm suggesting, is a function similar to IsTimerExpired(), but where it never goes into an OFF state. It always returns true or false depending on whether it's counting down or not. In this case, it would be something along the lines of if(GetTimer(1) > 0).
This is because there have been numerous times that OFF state feature of IsTimerExpired() has caused me headaches, simply because I've either forgotten about it or it runs counter-productive to what I'm trying to accomplish. A quick look through the forums for problems that people have had with timers, and it seems as though I'm not the only one.
The thing is though, that OFF state is very useful. But it'd be nice if we had a function which didn't have it. And being able to get the exact time left on a timer, would do exactly that.
Alternatively, a IsTimerRunning() function, which returns true if the timer is above 0, or false if it's below 0, could also work. But that would be much more limiting.
I really hope this feature isn't something that's already in the editor. I've looked through the manual, and couldn't see any mention of it.
But none the less, thanks for hearing me out.
EDIT:
By the way, I know you can do this by simply implementing your own timers. But to me, it really seems like it's something that should be part of the editor itself.
What I'm suggesting here is a GetTimer() function, which simply returns the number of cycles left on a timer. My reason for this is twofold. Firstly, sometimes you'll want to be able to do something in the middle of a timer, without setting up another timer. Secondly, it would provide a way to see whether or not a timer is running, without incurring the IsTimerExpired()'s OFF state.
Basically with that second reason, what I'm suggesting, is a function similar to IsTimerExpired(), but where it never goes into an OFF state. It always returns true or false depending on whether it's counting down or not. In this case, it would be something along the lines of if(GetTimer(1) > 0).
This is because there have been numerous times that OFF state feature of IsTimerExpired() has caused me headaches, simply because I've either forgotten about it or it runs counter-productive to what I'm trying to accomplish. A quick look through the forums for problems that people have had with timers, and it seems as though I'm not the only one.
The thing is though, that OFF state is very useful. But it'd be nice if we had a function which didn't have it. And being able to get the exact time left on a timer, would do exactly that.
Alternatively, a IsTimerRunning() function, which returns true if the timer is above 0, or false if it's below 0, could also work. But that would be much more limiting.
I really hope this feature isn't something that's already in the editor. I've looked through the manual, and couldn't see any mention of it.
But none the less, thanks for hearing me out.
EDIT:
By the way, I know you can do this by simply implementing your own timers. But to me, it really seems like it's something that should be part of the editor itself.