mine checks if its more than or equal to 5, so if mine misses a 5, it will work when it becomes a 6, but yours checks if its only 5, if your script misses the 5, it does nothing.
speed isnt everything..
Seeing a lot of bad code from you.
i paste good code if i test it first, normally i dont test it..