Component:ReferenceField

From Resonite Wiki
Revision as of 17:53, 27 January 2025 by 989onan (talk | contribs) (add more)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Component image 
Reference Field component as seen in the Scene Inspector

Reference Field is a component that is able to store a reference for later use, as long as the reference still exists by then.

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.
Reference T A field that can be used to store any reference type.

Usage

This can be used in tandem with a Reference Grab Receiver Component as a place to store the value received by said component. This component's Reference field can be accessed with ProtoFlux.

Using this as a Data Model Store is considered bad practice due to it making your code harder to read, use, and transfer.

Examples

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


See Also