R
rodrick160
Guest
Im using a script that essentially checks whether there is a wall in the direction your about to move in, and if not, moves you there. I'm not looking for anything fancy, just a simple formula using hspeed and vspeed and maybe some other variables that will set it to move the same speed diagonally as it does horizontally and vertically. Thanks!
My movement script:
My movement script:
Code:
///Move Up
if !(collision_rectangle(x+1,y-var_speed,x+31,y,obj_wall,false,true))
vspeed=var_speed*-1
else
vspeed=0