Limiting the height my character can reach?

Hey Everyone! I’m wondering how would I make it so that once my Character reaches a certain height, he starts to go down?

Currently I have this.

So this is my problem. My character gets YEETed into the sky. Any solutions would be amazing!

2 Likes

1.) Simplest solution, increase gravity for the player from the movement component.
2.) Put an invisible geometry in the sky, preferably a block and not a plane as actors in movement can get calculated and popped through a plane with planes being so thin.
3.) On tick, or preferably a less frequent “timer by event”, check the players Z location, if greater than your preferred height, add a -z velocity, or increase gravity (from the movement component).
4.) As a player, Id prefer a smooth adjustment so, on Timer by event with a .5s looping, get z location and increment gravity (from the movement component) as the player goes higher, decreasing gravity as the player gets lower.

Good luck!

2 Likes

This is really helpful! I’ll give this a shot. Thank you for your input.

1 Like

Run a lessequal node whenever you’re setting your character height.