Whether an object should rotate positive or negative

I’m making an enemy ai that needs to get from a current angle to a final angle. I made it so that the angles are always 0-359, so all I need to do it determine if it would be faster to increase the angle until it reaches the goal or to decrease. The current and final angle can be changing in game so keep that in mind. I am brain dead rn so I don’t know what to do.
Current logic is in the enemy_base_1 object
(on the second level)

1 Like

Let it decide whether to rotate positively or negatively, that would make it smarter and stronger, but would be a bit more complex to code.

so I actually kinda did it, but I’m having a problem where it freaks out when going from 360 to 0, if anyone can take a look at that

I did it :’) it’s working

1 Like