G
GalaxyKitten
Guest
Hi there, I currently have an enemy that sticks to walls. When a corner approaches, it will change its degree to 90 degrees to match that.
Imagine a box, the enemy will crawl all around it, up the walls, upside down, nice and good! But when it reaches a slope, it goes crazy because it tries to flip 90 degrees on a 45 degree angle for example. What would be the best way for it to just match the slope or angle its currently on?
My Code: https://pastebin.com/raw/kUDx4hMb
Thank you!
Imagine a box, the enemy will crawl all around it, up the walls, upside down, nice and good! But when it reaches a slope, it goes crazy because it tries to flip 90 degrees on a 45 degree angle for example. What would be the best way for it to just match the slope or angle its currently on?
My Code: https://pastebin.com/raw/kUDx4hMb
Thank you!