I’d like to know the C# code to do the following: Make the character move ahead constantly, make it turn to the left or right as press the left/right buttons, and when the button is no longer pressed, make the character return to the original position (straight ahead). Can anyone help me?
Are you looking for a standard character controller? To move forward/backward/left/right?
I wont do it all for you but look into transform.forward and transform.right and transform.up
if you want to go backwards you would subtract rather than add etc…
Just look it up and it should be findable… Look in the unity docs too
How to attribute this to the character? I’m not getting.
I think you need some basic tutorials like here:
http://walkerboystudio.com/html/unity_training___free__.html#unity3game1