Component:ObjectGridAligner: Difference between revisions

From Resonite Wiki
Automated: update Fields, Categories
add some info
Line 2: Line 2:
<translate>
<translate>
<!--T:1-->
<!--T:1-->
{{stub}}
{{Infobox Component
{{Infobox Component
|Image=ObjectGridAlignerComponent.png
|Image=ObjectGridAlignerComponent.png
|Name=Object Grid Aligner
|Name=Object Grid Aligner
}}
}}
The '''ObjectGridAligner''' component aligns objects into a grid of items with x number of items per row.


<!--T:2-->
<!--T:2-->
== Fields ==
== Fields ==
{{Table ComponentFields
{{Table ComponentFields
|AutoAddChildren|Bool| Controls whether slots below this component's slot in the hierarchy are automatically added to <code>_targets</code>
|AutoAddChildren|Bool| Controls whether slots below this component's slot in the hierarchy are automatically added to <code>_targets</code>.
|ItemsPerRow|Int|
|ItemsPerRow|Int| How many items per row.
|CellSize|Float2|
|CellSize|Float2| The space between each item.
|LerpSpeed|Float|
|LerpSpeed|Float| How fast the items should move to align themselves in the specified grid arrangement.
|HorizontalAlignment|'''[[#Align|Align]]'''|TypeAdv4=true|
|HorizontalAlignment|'''[[#Align|Align]]'''|TypeAdv4=true| How to align the items horizontally.
|VerticalAlignment|'''[[#Align|Align]]'''|TypeAdv5=true|
|VerticalAlignment|'''[[#Align|Align]]'''|TypeAdv5=true| How to align the items vertically.
|RowAxis|'''[[#AxisDir|AxisDir]]'''|TypeAdv6=true|
|RowAxis|'''[[#AxisDir|AxisDir]]'''|TypeAdv6=true| The axis that items should be aligned on for the horizontal axis of the grid.
|ColumnAxis|'''[[#AxisDir|AxisDir]]'''|TypeAdv7=true|
|ColumnAxis|'''[[#AxisDir|AxisDir]]'''|TypeAdv7=true| The axis that items should be aligned on for the vertical axis of the grid.
|Items|{{RootFieldType|SyncList`1|[[#Item|Item]]}}|TypeAdv8=true|
|Items|{{RootFieldType|SyncList`1|[[#Item|Item]]}}|TypeAdv8=true| A list of items who's positions should be driven to place them into a grid alignment using this component's calculations.
}}
 
== Align ==
{{stub}}
Controls how the items should align themselves along the axis specified by the component.
{{Table EnumValues
|Neg|?| Aligns items so their values are always negative along the specified alignment axis (so if using x axis, x will always be negative for an item)
|Pos|?| Aligns items so their values are always positive along the specified alignment axis (so if using x axis, x will always be positive for an item)
|Mid|?| Aligns items so half are on the negative and half are on the positive along an axis, so they take up both directions equally.
}}
 
== AxisDir ==
{{stub}}
{{Table EnumValues
}}
 
== Item ==
{{stub}}
{{Table TypeFields
}}
}}



Revision as of 17:54, 4 December 2024

Component image 
Object Grid Aligner component as seen in the Scene Inspector

The ObjectGridAligner component aligns objects into a grid of items with x number of items per row.

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.
AutoAddChildren Bool Controls whether slots below this component's slot in the hierarchy are automatically added to _targets.
ItemsPerRow Int How many items per row.
CellSize Float2 The space between each item.
LerpSpeed Float How fast the items should move to align themselves in the specified grid arrangement.
HorizontalAlignment Align How to align the items horizontally.
VerticalAlignment Align How to align the items vertically.
RowAxis AxisDir The axis that items should be aligned on for the horizontal axis of the grid.
ColumnAxis AxisDir The axis that items should be aligned on for the vertical axis of the grid.
Items list of Item A list of items who's positions should be driven to place them into a grid alignment using this component's calculations.

Align

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


Controls how the items should align themselves along the axis specified by the component.

Values
Name Value Description
Neg ? Aligns items so their values are always negative along the specified alignment axis (so if using x axis, x will always be negative for an item)
Pos ? Aligns items so their values are always positive along the specified alignment axis (so if using x axis, x will always be positive for an item)
Mid ? Aligns items so half are on the negative and half are on the positive along an axis, so they take up both directions equally.

AxisDir

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


Values
Name Value Description

Item

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


Fields
Name Type Description

Usage

Examples

Related Components