Creature Control for Unity v0.1
Loading...
Searching...
No Matches
Creatures.Bone.RangeOfMotion Class Reference

Description

The range of motion (RoM) for a bone.

Public Member Functions

 RangeOfMotion (float min, float max)
 Create a new range of motion.
float Clamp (float angle)
 Clamp an angle to the range of motion.

Public Attributes

float minimum
 The minimum angle in degrees.
float maximum
 The maximum angle in degrees.

Properties

bool isValid [get]
 Check if the RoM min value is smaller than the max value.

Constructor & Destructor Documentation

◆ RangeOfMotion()

Creatures.Bone.RangeOfMotion.RangeOfMotion ( float min,
float max )

Create a new range of motion.

Parameters
minThe minimum angle in degrees
maxThe maximum angle in degrees

Member Function Documentation

◆ Clamp()

float Creatures.Bone.RangeOfMotion.Clamp ( float angle)

Clamp an angle to the range of motion.

Parameters
angleThe angle to clamp
Returns
The clamped angle

The documentation for this class was generated from the following file: