Pulling my hair out over this one as I’m used to Unity:
//Create Original Vector Variable transform.position = (0,0,0) //Create out target Vector that we want to move to Vector3 target = transform.position; //Set X variable to 50 target.x = 50.0f; //We changed x to 50, and set the new value, but the other values (Y,Z) remain constant transform.position = target;
So now our own transform.position = (50,0,0)
See this is what I tried to do initially, by getting the Y value of our Target and creating a vector out of it, I’ve tried a few other methods and I know this doesn’t work because pulling the Y value to a vector sets all 3 vectors to the same value for some reason.
Any ideas on how I can do this? I’m just trying to lerp between three different points while the object is constantly moving forward, but I want to keep my X and Z values from changing.