I seem to be having an issue with .rehash and my script that I have that uses timers. I read somewhere, not sure where, that by doing the first if statement that it would keep the initial timer from being started again upon a rehash. What happens is that every time I rehash I get a new instance so I get my message printing to a channel more then every thirty minutes if $var = 1. I will get it like 3 times every 30 minutes.
So put that code in instead of the first if statement and that does a search for a prexisting timer associated with start right? And if it doesn't find out then executes code where the comment is?
I left alot out because it is a lot of code and I don't have it all at work with me. The main part that I am concerned with is that the initial timer is being run each time I rehash my bot creating multiple instances which gets annoying because it messages the channel, so if I rehash the bot instead of getting a message every 30 minutes I might get one every 15 minutees depending on how long the previous timer has been running.
Does that make sense?
What is an easy way to see all timers that are active and running?