Yesterday, I posted this:
It was about creating a shield that can be controlled around the player.
Now, I would like to know, when the shield rotates around the player I want it to go only to fixed positions left, right and up.
How is this possible?
PS: I am new to these forums and I don't know if I have to post on the old one again, or create a new one.
Add a variable to the shield called "direction"
Set "direction" to angle(shield.x, shield.y, mouse.x, mouse.y)
Shield set angle to round(shield.direction/90)*90
It didn't work.
Those are my shield events
You have another event just below also changing the angle of the shield
Develop games in your browser. Powerful, performant & highly capable.
Thanks this worked!
One last request, how can I disable the direction that goes down?