StateTree Tools

Ready-made StateTree tools for Unreal Engine 5


Project maintained by StateTreeTools Hosted on GitHub Pages — Theme by mattgraham

Clamp Angle

Plugin: StateTreeToolsCore Category: Math | Float

Constrains an angle in degrees to lie within a specified angular range, wrapping the angle first so the comparison is performed in a consistent space. Use this to restrict a turret or camera yaw to an allowed arc, or to keep a rotation offset within a comfortable range.


Configuration

AngleDegrees

The angle in degrees to clamp.

MinAngleDegrees

The lower angular bound in degrees. Defaults to 0.

MaxAngleDegrees

The upper angular bound in degrees. Defaults to 360.

Result

AngleDegrees constrained to [MinAngleDegrees, MaxAngleDegrees].

Unreal Engine Version Notes

Property functions are not available in UE 5.4. This node requires UE 5.5 or later.


← Back to Math | Float · ← Back to home