|
Creature Control for Unity v0.1
|
An antenna in a TargetRig which is used to control an antenna of a model.
Public Member Functions | |
| override void | MatchTo (Bone bone) |
| Function to match the target to the selected bone. | |
| override void | UpdateBones (Bone bone) |
| Update the pose of the bone from this target. | |
| virtual void | Unmatch () |
| Set properties for the case no matching bone exists. | |
| virtual void | Align () |
| Align the pose. | |
Public Attributes | |
| Transform | funiculusTarget |
| The funiculus target. | |
| Transform | endTarget |
| The end target of this antenna target chain. | |
| bool | inverseKinematics = false |
| Use inverse kinematics. | |
| Transform | ikTarget |
| The inverse kinematics target. | |
| Quaternion | targetToBoneFuniculus = Quaternion.identity |
| The rotation from the target to the funiculus bone. | |
| Rig | rig |
| The target Rig to which this target belongs. | |
| bool | isMatched = false |
| Is this target matched to a bone? | |
| Quaternion | targetToBone |
| The rotation to transform the target rotation into the rotation of the bone in the model. | |
Protected Member Functions | |
| void | InverseKinematics () |
| Calculate the inverse kinematics. | |
| Quaternion | ScapeRotation (Vector3 targetPosition) |
| Calculate the scape target orientation. | |
| void | UpdateScape (Transform scapeBone) |
| Update the scape bone orientation from its target. | |
| void | UpdateFuniculus (Transform funiculusBone) |
| Update the funiculus bone orientation from its target. | |
Properties | |
| Transform | scapeTarget [get] |
| The scape target. | |
| Quaternion | targetToBoneScape [get] |
| The rotation from the target to the scape bone. | |
|
virtual |
Function to match the target to the selected bone.
| bone | The bone to match to |
This will put the target at the bone position and orientation and calculate the targetToBone rotation When the bone is null, the value isMatched will become false
Reimplemented from Creatures.Target.
|
virtual |
Update the pose of the bone from this target.
| bone | The bone for which the pose is updated |
Reimplemented from Creatures.Target.
|
protected |
Calculate the scape target orientation.
| targetPosition | The inverse kinematics target position |
|
protected |
Update the scape bone orientation from its target.
| scapeBone |
|
protected |
Update the funiculus bone orientation from its target.
| funiculusBone |
|
virtualinherited |
Set properties for the case no matching bone exists.
Reimplemented in Creatures.LegTarget.
|
virtualinherited |
Align the pose.
This will make the pose of the creature symmetric
Reimplemented in Creatures.HeadTarget, Creatures.Insects.HeadTarget, and Creatures.TailTarget.