Update player location in relation to moving platform

Hello.

I followed a tutorial online for hanging on a ledge and climbing up. The tutorial works great, except on moving platforms. The player just hangs in place as the platform moves away.

Is there a way to get the updated transform for the platform and use it to update the player’s location so it will line up?

Thanks.

Tutorial I followed: Hanging on a Ledge

Edit: the player can shimmy along the edge.

Hey @ArtistGamedev!

Didn’t look at the tutorial you linked but the fix would be the same for this:

Simply attach the player character to the hit actor of your line traces like this:

Hope this helps! :innocent:

1 Like

Thanks for the response, @visagilis! I should have mentioned this before, but the player can shimmy along the edge while he climbs. I’m afraid attaching the player to the hit actor would lock him in place.

I apologize for any confusion.

Nope :blush: You can still move around

You may know exactly what it’s called but isn’t there a checkbox in actors settings that makes it to where the player will move with it when on top of it…saw another post addressing a similar issue like this a couple weeks ago

Nah this one is different. Because I interpreted this:

as the OP has the player character gripping a ledge, and has it’s movement mode set to flying. So we’re not on top of the moving platform. Also, that behavior where the player character moves with the object it’s standing on is enabled by default, so it wouldn’t be a problem.

1 Like

Yea I got that wasn’t sure if that could be modified in some way to make it work…what about attach actor to component?

Actor to actor did work in my testing, also should work for the OP. I think you suggested that assuming OP gave it a shot but couldn’t make it work, right?

Maybe in fact it won’t work as expected for some reason with the OP’s implementation of ledge climbing. So let us know how it goes @ArtistGamedev!

Thanks, @VisAgilis! This worked perfectly and you were absolutely right.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.