Component:AvatarControllerSpawner: Difference between revisions

From Resonite Wiki
Automated: create new component page
 
add hopefully close enough info
 
Line 3: Line 3:
|Name=Avatar Controller Spawner
|Name=Avatar Controller Spawner
}}
}}
{{stub}}
The '''AvatarControllerSpawner''' component will spawn the corrosponding controller for the user when placed on an avatar under either the right or left hand.


== Usage ==
== Fields ==
{{Table ComponentFields
{{Table ComponentFields
|SpawnRoot|Slot|
|SpawnRoot|Slot| Where to spawn the model. (The Component attaches a slot called "root" under this when spawning the model, that becomes the model root)
|MaterialOverride|{{RootFieldType|AssetRef`1|[[Type:Material|Material]]}}|TypeAdv1=true|
|MaterialOverride|{{RootFieldType|AssetRef`1|[[Type:Material|Material]]}}|TypeAdv1=true| What material to replace the spawned model's materials with upon spawning.
|ControllerSpawned|{{RootFieldType|SyncDelegate`1|[[Type:Action`2|Action`2]]<[[Type:Slot|Slot]], [[Type:User|User]]>}}|TypeAdv2=true|
|ControllerSpawned|{{RootFieldType|SyncDelegate`1|[[Type:Action`2|Action`2]]<[[Type:Slot|Slot]], [[Type:User|User]]>}}|TypeAdv2=true| The component calls this method when it has finished spawning the model with the user that has this controller model, and the root slot of the spawned model.
|_sourceControllerInfo|'''[[Component:AvatarControllerInfo|AvatarControllerInfo]]'''|TypeAdv3=true|
|_sourceControllerInfo|'''[[Component:AvatarControllerInfo|AvatarControllerInfo]]'''|TypeAdv3=true| The controller info this component grabbed in order to find and generate the right model.
|_lastSpawned|{{RootFieldType|SyncType}}|TypeAdv4=true|
|_lastSpawned|{{RootFieldType|SyncType}}|TypeAdv4=true| The froox engine type of the last controller type this component generated.
}}
}}


== Behavior ==
== Usage ==
{{stub}}


== Examples ==
== Examples ==
Can be used to show what kind of controllers the user is using when they get into an avatar.


== See Also ==
== See Also ==
Line 22: Line 24:
[[Category:Components:Users:Common Avatar System{{#translation:}}|Avatar Controller Spawner]]
[[Category:Components:Users:Common Avatar System{{#translation:}}|Avatar Controller Spawner]]
[[Category:Components{{#translation:}}|Avatar Controller Spawner]]
[[Category:Components{{#translation:}}|Avatar Controller Spawner]]
[[Category:ComponentStubs]]

Latest revision as of 20:08, 7 February 2025

Component image 
Avatar Controller Spawner component as seen in the Scene Inspector

The AvatarControllerSpawner component will spawn the corrosponding controller for the user when placed on an avatar under either the right or left hand.

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.
SpawnRoot Slot Where to spawn the model. (The Component attaches a slot called "root" under this when spawning the model, that becomes the model root)
MaterialOverride Material What material to replace the spawned model's materials with upon spawning.
ControllerSpawned delegate of identity Action`2<Slot, User> The component calls this method when it has finished spawning the model with the user that has this controller model, and the root slot of the spawned model.
_sourceControllerInfo AvatarControllerInfo The controller info this component grabbed in order to find and generate the right model.
_lastSpawned direct SyncType The froox engine type of the last controller type this component generated.

Usage

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

Examples

Can be used to show what kind of controllers the user is using when they get into an avatar.

See Also