Updated : gameLoop. Correcting the test functions for the game loop