How to ease toward clamp range limit

I am building a controller with a limited range of movement. basically, the character can only move in a 30-degree arc from the centre using pitch and roll.
I’m using Clamp angle to stop the character from rotating beyond these limits. However, when the character reaches the -30 or 30 limits the stop is far too sudden and jolting.
I want to build a blueprint to ease or soften the last 10 degrees into a soft stop. I’ve looked at ease and interpolation but I’m struggling to make them work with the Clamp angle mode.
can anyone advise me on how soften the end of a rotation using the clamp angle?

Try something like this


The interp value is how quickly it will smoothly move between the given values in the clamp. This is how I make my rudders move smoothly on aircraft in my game but I adjusted it to fit into the code you provided. The clamp defines the values which are the limit of the angle.

I’ve never tried to use clamp angle but I think you can get around using it since it isn’t giving you the results you want.

@Dirge0matic Did you figure out?

I’m looking for a solution to the same problem and smooth out my -30 to 30 clamp.

use a curve y axis is your increment and the x axis is your angle, if u dont know how use a curve u can use a compare float node with a timeline, if the float is positive play the timeline and if is negative, reverse the timeline

Hi @Husky211

II’ve recorded a short video showcasing my WIP Game to illustrate the exact issue I’m facing.

I want to control the movement as I currently have it, but I would like the float value to gradually decrease smoothly when it reaches -30 or 30, instead of abruptly like it does now.

I’m not sure how to solve this. Could you possibly share a snippet of the setup to help me out? Thanks!

https://www.youtube.com/watch?v=TndEZfE8234

Here is my current example : https://blueprintue.com/blueprint/4-ajiv_w/

SmoothClamp.zip (56.4 KB)

Depending on the curve values and multiplier speed (set to 15 here) you will get different results.

1 Like