Component:LineTransform: Difference between revisions

From Resonite Wiki
Automated: update Fields, Categories
add info
 
Line 1: Line 1:
<!--T:1-->
<!--T:1-->
{{stub}}
{{Infobox Component
{{Infobox Component
|Image=LineTransformComponent.png
|Image=LineTransformComponent.png
|Name=Line Transform
|Name=Line Transform
}}
}}
The '''LineTransform''' component is a transform driver component used to position an object between two points or slots.


<!--T:2-->
<!--T:2-->
== Fields ==
== Fields ==
{{Table ComponentFields
{{Table ComponentFields
|Point0|Float3| {{stub}}
|Point0|Float3| The point in local space to transform from.
|Point1|Float3| {{stub}}
|Point1|Float3| The point in local space to transform to.
|Point0Anchor|{{RootFieldType|TransformRelayRef}}|TypeAdv2=true| {{stub}}
|Point0Anchor|{{RootFieldType|TransformRelayRef}}|TypeAdv2=true| acts as a slot to offset <code>Point0</code> in global space.
|Point1Anchor|{{RootFieldType|TransformRelayRef}}|TypeAdv3=true| {{stub}}
|Point1Anchor|{{RootFieldType|TransformRelayRef}}|TypeAdv3=true| acts as a slot to offset <code>Point1</code> in global space.
|LinePositionType|PositionType| {{stub}}
|LinePositionType|PositionType| How to calculate the position on the line using <code>LinePoint</code> for the slot this component is on.
|PlanePositionType|PositionType| {{stub}}
|PlanePositionType|PositionType| How to calculate the position on the line using <code>LinePoint</code> for the slot this component is on.
|LinePoint|Float| {{stub}}
|LinePoint|Float| Where on the line specified by <code>Point0</code> and <code>Point1</code> in percentage or relative distance that the slot this component is on should be positioned.
|OffsetPoint|Float3| {{stub}}
|OffsetPoint|Float3| The offset from the point found by <code>LinePoint</code> slot this component is on should be.
|RotationOffset|FloatQ| {{stub}}
|RotationOffset|FloatQ| The rotation offset from looking along the line.
|_position|{{RootFieldType|FieldDrive`1|[[Type:Float3|Float3]]}}|TypeAdv9=true| {{stub}}
|_position|{{RootFieldType|FieldDrive`1|[[Type:Float3|Float3]]}}|TypeAdv9=true| drives the target field with the position found by <code>LinePoint</code> plus <code>OffsetPoint</code> rotated by <code>RotationOffset</code> and "looking down the line rotation" around the point found by <code>LinePoint</code>.
|_rotation|{{RootFieldType|FieldDrive`1|[[Type:FloatQ|FloatQ]]}}|TypeAdv10=true| {{stub}}
|_rotation|{{RootFieldType|FieldDrive`1|[[Type:FloatQ|FloatQ]]}}|TypeAdv10=true| drives the target field with <code>RotationOffset</code> and "looking down the line rotation"
|AllowRepositioning|Bool| {{stub}}
|AllowRepositioning|Bool| Allow grabbing of the slot this component is on to move the object and change <code>LinePoint</code>
|RepositionOffset|Bool| {{stub}}
|RepositionOffset|Bool| Whether grabbing changes <code>OffsetPoint</code> as well.
}}
}}


<!--T:3-->
<!--T:3-->
== Usage ==
== Usage ==
{{stub}}
Can be used to position an object along a track like a slider.


<!--T:4-->
<!--T:4-->
Line 32: Line 32:
{{stub}}
{{stub}}


[[Category:ComponentStubs]]
== See Also ==
 
[[Category:Components:Transform:Drivers{{#translation:}}|Line Transform]]
[[Category:Components:Transform:Drivers{{#translation:}}|Line Transform]]
[[Category:Components{{#translation:}}|Line Transform]]
[[Category:Components{{#translation:}}|Line Transform]]

Latest revision as of 23:50, 22 January 2025

Component image 
Line Transform component as seen in the Scene Inspector

The LineTransform component is a transform driver component used to position an object between two points or slots.

Fields

Fields
Name Type Description
persistent Bool Determines whether or not this item will be saved to the server.
UpdateOrder Int Controls the order in which this component is updated.
Enabled Bool Controls whether or not this component is enabled. Some components stop their functionality when this field is disabled, but some don't.
Point0 Float3 The point in local space to transform from.
Point1 Float3 The point in local space to transform to.
Point0Anchor direct TransformRelayRef acts as a slot to offset Point0 in global space.
Point1Anchor direct TransformRelayRef acts as a slot to offset Point1 in global space.
LinePositionType PositionType How to calculate the position on the line using LinePoint for the slot this component is on.
PlanePositionType PositionType How to calculate the position on the line using LinePoint for the slot this component is on.
LinePoint Float Where on the line specified by Point0 and Point1 in percentage or relative distance that the slot this component is on should be positioned.
OffsetPoint Float3 The offset from the point found by LinePoint slot this component is on should be.
RotationOffset FloatQ The rotation offset from looking along the line.
_position field drive of Float3 drives the target field with the position found by LinePoint plus OffsetPoint rotated by RotationOffset and "looking down the line rotation" around the point found by LinePoint.
_rotation field drive of FloatQ drives the target field with RotationOffset and "looking down the line rotation"
AllowRepositioning Bool Allow grabbing of the slot this component is on to move the object and change LinePoint
RepositionOffset Bool Whether grabbing changes OffsetPoint as well.

Usage

Can be used to position an object along a track like a slider.

Examples

This article or section is a Stub. You can help the Resonite Wiki by expanding it.


See Also