- Home /
Question by
Jake_Branca · Dec 27, 2014 at 08:31 PM ·
movement
Making a 2D player move along the x axis with 2 UI Buttons
Hey guys, I'm wondering how to make a 2D player move along the x axis with 2 UI Buttons. I am using C# but Javascript will also work. If anybody has an answer, I would be extremely thankful.
Comment
Answer by Graham-Dunnett · Dec 27, 2014 at 08:32 PM
Well, if one button is pressed subtract a value from x, and if the other button is pressed, add a value to x.
Thanks but do you have the code for that? I am a beginner coder.
Your answer