This is a way you can do stop button detection and use the timer for your projects. :) use it, no credit required
P.S. The timer auto-resets every time the green flag is clicked, it's not a part of the sprite.