Changed shift functions and edited exception throwing so the game works properly