This is probably a really simple task that I’m having issue with.
All I’m wanting to do is move a 2D plane object in the X and Y axis depending on how my joypads thumbstick is pressed (can’t use a GUI texture, as it needs to be a plane. Too long to explain).
When I run my game, my plane moves miles away as opposed to the movement I want it to do. Right now, the code I have attached to my plane is as follows:
The update method
xMin1 += Input.GetAxisRaw("LeftRight");
yMin1 += Input.GetAxisRaw("UpDown");
// targetPlane is a public game object
targetPlane.transform.position = new Vector3(xMin1, yMin1, 2.5f);
Is there something I’m missing, or doing just completely wrong?
As I said, all I’m really trying to do is have a plane move in either the X or Y axis, in front the camera , depending on how the joystick is pressed.
I’d appreciate any help that you can give.