Is there any way to reverse a InterpToMovement Component

Hi. I need a little help using the InterpToMovement Component.
Is there any way to reverse it?
There are options for:
One Shot (A-B),
One Shot Reverse (A-B-A),
Loop Reset (A-B and then teleports back to A),
Ping Pong (A-B-A-B-A-B etc)
Ideally I’d like to be able to have one button make it go (A-B) and another button reverse it (B-A)
I’ve been playing around for a while but I’m not getting anywhere.
Any help is appreciated
Thanks

Hi SneakySteve83,

I don’t believe the InterpToMovement is the best thing to use for the functionality you are looking for. I would do something like this:

Here is the inside of that Timeline.

Let me know if the helps.

Cheers,

TJ

1 Like

Hi. Thanks for the reply.

The reason I was hoping to use the InterpToMovement component was because it works with collisions.
There will be other objects that can stop the platform from moving along its path.
When I’ve used a timeline its ignored anything in its way.
I also like the InterpToMovement components ability to have multiple positions.

This may or may not work for you. But with the setup above, you can make the platform stop when it hits other objects by enabling the Sweep checkbox on the SetRelativeLocation node. The timeline will continue when the object stops, so you would need to setup an ‘if sweep is true’ then ‘stop the timeline’.

You can also adjust the positions by feeding new values into the VInterpTo node. Changing the timeline on the fly is a bit limited, but you can setup some rather complex movements through the float track ahead of time.

If you want to use the InterpToMovement component, I would need to do some more experimenting to see it’s capable of doing what you want.

Ok thanks. I’ll have a look tomorrow when I get some free time.
Thanks for your help :slight_smile:

This page is top result in search engines for “Reverse InterpToMovement”, hence the necro-bump.

Solution:
Set behavior type to OneShot, then…

You can see here Initial Direction is -1.0 to reverse the completed InterpToMovement, followed by Restart and Activate.