Fangames > Programming Questions

Avoidance help

(1/1)

wolfy135:
As someone who is starting to get into game-making, and starting to make avoidances, I had a question of how to do a screen-tilt like some avoidances do, and the picture i have for example is LunarMagic from K3 because it was the first one to come to my head
(click to show/hide)Does anyone know the code of how to do this, or how they do it?
Thanks a ton if you get working code for me :D

YoSniper:
Assuming you're using Game Maker Pro (although maybe it's available in the Lite/Standard versions now,) you want to do:


--- Code: ---view_angle[0] = angle;
--- End code ---

Where angle is the angle counter-clockwise from horizontal in degrees. If you're only using the one view, you don't even need the [0] part.

Just remember to reset it to 0 after you're done.

wolfy135:
Where would I place this code, in the timeline step events of where I would want it, or somewhere else?

YoSniper:
Yes, timeline of Step Events would be where you want it.

wolfy135:
Alright, thanks Sniper! I'll test it out when I am able to get to my computer with my Game-Maker on it

Navigation

[0] Message Index

Go to full version