Look at is a component that is used to make one [[slot]] point to look at another slot via a SwingTwist interpolation.
Swing Twist is a concept that is too complicated to explain on this wiki, but essentially constrains the rotation on two axies when rotating to a point, locking it within a range. kind of like a turret.
<!--T:2-->
<!--T:2-->
== Fields ==
== Fields ==
{{Table ComponentFields
{{Table ComponentFields
|Target|Slot|
|Target|Slot| The slot to try to look at.
|TargetPoint|Float3|
|TargetPoint|Float3| The 3D point to look at when <code>Target</code> is not provided.
|_target|{{RootFieldType|FieldDrive`1|[[Type:FloatQ|FloatQ]]}}|TypeAdv9=true| The field to apply the rotation result to.
}}
}}
<!--T:3-->
<!--T:3-->
== Usage ==
== Usage ==
Attach the component to a slot and provide a <code>Target</code> or <code>TargetPoint</code> to make it look at or point at a position. It is recommended to put a slot under this component's slot to apply offsets to the rotation.
<!--T:4-->
<!--T:4-->
== Examples ==
== Examples ==
This can be used to make a piston base and rod look at each other to stay connected when the piston moves. this can also be used to make a tracking system.
Look at is a component that is used to make one slot point to look at another slot via a SwingTwist interpolation.
Swing Twist is a concept that is too complicated to explain on this wiki, but essentially constrains the rotation on two axies when rotating to a point, locking it within a range. kind of like a turret.
Attach the component to a slot and provide a Target or TargetPoint to make it look at or point at a position. It is recommended to put a slot under this component's slot to apply offsets to the rotation.
Examples
This can be used to make a piston base and rod look at each other to stay connected when the piston moves. this can also be used to make a tracking system.