Playmaker Forum
PlayMaker Feedback => Action Requests => Topic started by: Kubold on July 08, 2012, 02:16:14 PM
-
I would gladly see something like Move to Target, but you should be able to pick certain axis. Right now you can only turn off vertical i think.
It should work like this script:
transform.position.z = Mathf.Lerp(transform.position.z, target.position.z, 0.5);
transform.position.y = Mathf.Lerp(transform.position.y, target.position.y, 0.5);
Basic use would be doing a camera follow a character in 2D sidescroller for example, but only in certain axis, with slight delay, without rotation.
-
Good idea. I'll look into the best way to add more control there...
In the meantime, you could use a Set Position action with Late Update checked to clamp certain axis of motion. Or you could combine lower level actions for more control. See attached screenshots.
It helps to think of actions as modular components that can be combined to get exactly the behavior you want
-
Awesome!!! Thanks a lot for fast reply!
-
First solution seems better for now, since Set Position gives a glitchy/flickering effect sometimes. It "teleports" the object instead of smoothly translating it (at least it looks that way).