So I am making a game in GML ( Game Maker Language ) where you a little rectangle with a sword in a maze. Enemies will come to you with life points and you will use your sword to kill them. The goal of the game is to get as many kills as possible before dying. I have done quite a bit so far but have had troubles with collision detection with the wall. My movement code for the player is: (player object) /// Exacute movement script step event: scr_movement_player(); (script scr_movement_player) ///scr_movement_player // Variables up = keyboard_check(ord('W')); down = keyboard_check(ord('S')); left = keyboard_check(ord('A')); right = keyboard_check(ord('D')); // Movement if(right) x += 7; if(left) x -= 7; if(down) x += 7; if(up) x -= 7; I've looked all over youtube to find any collision code but can't find any.