small change in gameloop