- Home /
Moving object
Could somebody tell me how to move object? MOVE, not teleport. I want my object to change "localPosition.z" from 4 to -4 in 1 second for example. I was trying to do that but i have no idea. I want this as function.
Answer by Marzoa · Oct 27, 2014 at 08:58 PM
Use an Animator. You can put then a first key in which localPosition.z is 4 and another key 1 second later in which it is -4, and the intermediary values will be calculated by Unity on the fly.
You need to understand how Animators works, though.
Lol good idea :) I will just make legacy animation (i don't use $$anonymous$$ecanim) and change object position. Thanks :)
Your answer
Follow this Question
Related Questions
Animate an object to a new position... 1 Answer
How to move a cube to another cube 2 Answers
Sigh... Need help with moving object a distance over time 1 Answer
Make Object Move to another Object 1 Answer
Vector3.Lerp 1 Answer