Here are some changes:
There are 3 variables to control the spinning, you don't actually need any of them!
Make sure to use delta-time (dt) when changing anything on every tick, like the animation speed.
I don't understand what events 45-46 are supposed to do, so I can't tell you how to fix them.