title: Unity C# Script Moving a character 2D
body: <p>I'm trying to make a script to control the character. I want the character to move a certain distance to the right while alternating LEFT ARROW and then RIGHT ARROW inputs. So ideally when i start the game, I press RIGHT ARROW - the character moves right say 10px, then press LEFT ARROW - the character moves right and this pattern continues on alternating and never allowing two of the same inputs after eachother eg: LEFT ARROW LEFT ARROW or RIGHT ARROW RIGHT ARROW.</p>