More efficient if statements in game.animation