Component:SnapTarget: Difference between revisions

From Resonite Wiki
Automated: update Fields, Categories
behavior
Line 4: Line 4:
|Name=SnapTarget
|Name=SnapTarget
}}
}}
== Introduction ==
The '''SnapTarget''' component allows a slot with a [[Snapper (Component)|Snapper Component]] to attach to this [[slot]].
The '''SnapTarget''' component allows a slot with a [[Snapper (Component)|Snapper Component]] to attach to this [[slot]].
== Usage ==
== Usage ==
Line 21: Line 20:


== Behavior ==
== Behavior ==
{{stub}}
Allows the slot containing this component to receive [[Component:Snapper|snappable]] slots, the Snapper slots will enter the hierarchy of the Snap Target slot and be positioned to the center. The SnapperWhitelist allows you to reference specific snappers that you want to allow to link with the Snap Target. The SnapperKeywordWhitelist allows snappers with the same keyword to link with the Snap Target.
 
== Examples ==
== Examples ==
{{stub}}
{{stub}}

Revision as of 01:38, 20 April 2024

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


Component image 
SnapTarget component as seen in the Scene Inspector

The SnapTarget component allows a slot with a Snapper Component to attach to this slot.

Usage

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.
SnapperWhitelist list of Snapper List of Snappers that are allowed to attach to this component
SnapperKeywordWhitelist direct SyncFieldList`1<String> List of keywords to match against a corresponding Snapper
Filters direct SyncDelegateList`1<SnapperFilter> This article or section is a Stub. You can help the Resonite Wiki by expanding it.
DirectSnapOnly Bool Unused
MaximumSnapDistance Float The maximum distance the Snapper can snap with the Target. This value drives the SphereCollider radius
MaximumAngleDeviation Float This article or section is a Stub. You can help the Resonite Wiki by expanding it.
AnimationTime Float The time it takes for the Snapper to lerp to the Target
AutoSnap Bool This article or section is a Stub. You can help the Resonite Wiki by expanding it.
_snapColliderRadius field drive of Float The radius drive reference of the SphereCollider
proxySphere SphereCollider Reference of the SphereCollider that is added on adding the SnapTarget to a slot

Behavior

Allows the slot containing this component to receive snappable slots, the Snapper slots will enter the hierarchy of the Snap Target slot and be positioned to the center. The SnapperWhitelist allows you to reference specific snappers that you want to allow to link with the Snap Target. The SnapperKeywordWhitelist allows snappers with the same keyword to link with the Snap Target.

Examples

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


Related Components