Common Avatar Builder is a component that is part of every world that defines the spawning behavior and routines to do for all users when they spawn into a world. This can be used to add world settings menus, change what parts of a user get automatically set up, and so on.
<!--T:2-->
== Intoduction ==
{{stub}}
<!--T:3-->
<!--T:3-->
== Usage ==
== Fields ==
{{Table ComponentFields
{{Table ComponentFields
|LoadCloudAvatars|Bool| {{stub}}
|LoadCloudAvatars|Bool| Whether to load the User's set avatar, or load the default avatar instead.
|CustomAvatarTemplates|AvatarTemplate| {{stub}}
|CustomAvatarTemplates|{{RootFieldType|SyncList`1|[[#AvatarTemplate|CommonAvatarBuilder.AvatarTemplate]]}}|TypeAdv1=true| Avatars that user's will spawn into if they don't have a cloud avatar, or optionally force them into one of these templates.
|AutoInject|Slot| A slot that will automatically be duplicated and added as a child of an avatar when they join the world.
|AutoInject|Slot| A slot that will automatically be duplicated and added as a child of a user when they join the world. Certain components will use this to override user behavior when part of this slot's hierarchy, like [[Component:AvatarAudioConfiguration|Avatar Audio Configuration]] to name one.
|SetupNameBadges|Bool| {{stub}}
|SetupNameBadges|Bool| Whether to set up the user's default name badge when they spawn
|SetupIconBadges|Bool| {{stub}}
|SetupIconBadges|Bool| Whether to set up the user's default badges when they spawn.
|SetupServerVoice|Bool| {{stub}}
|SetupServerVoice|Bool| Only used in kiosk mode.
|SetupClientVoice|Bool| {{stub}}
|SetupClientVoice|Bool| Only used in kiosk mode.
|SetupServerTools|Bool| {{stub}}
|SetupServerTools|Bool| Only used in kiosk mode.
|SetupClientTools|Bool| {{stub}}
|SetupClientTools|Bool| Only used in kiosk mode.
|SetupLocomotion|Bool| {{stub}}
|SetupLocomotion|Bool| Whether to give the user the default locomotion modules when they spawn.
|AllowLocomotion|Bool| {{stub}}
|AllowLocomotion|Bool| Whether to allow the user to move using locomotion when they spawn.
|DefaultHostSilenced|Bool| {{stub}}
|DefaultHostSilenced|Bool| Whether the user should be default muted to the host when they spawn.
|DefaultClientSilenced|Bool| {{stub}}
|DefaultClientSilenced|Bool| Whether the user should be default muted on their end when they spawn.
|LocomotionModules|Slot| {{stub}}
|LocomotionModules|Slot| The slot full of locomotion modules that the user will have by default after they spawn.
|ForceDefaultLocomotionModule|ILocomotionModule| The locomotion to enable for the user by default when spawning rather than the one in that user's locomotion settings set in their dash.
|SyncActiveLocomotionModule|Bool| {{stub}}
|FindUserPreferredModule|Bool| Whether to try to spawn the user into their preferred locomotion module they set in settings.
|SetupItemShelves|Bool| {{stub}}
|SetupItemShelves|Bool| Whether to add item shelves to the user when they spawn.
|SetupCircularMenus|Bool| {{stub}}
|ParentClientsToServer|Bool| Parents users that join under the host user's slot (yes this is what it does)
|ParentClientsToServer|Bool| {{stub}}
|AlignTracking|Bool| used in Kiosk mode in dash space to show Debug tracking visuals
|AlignTracking|Bool| {{stub}}
|EmptyAvatarSlotHandler|IEmptyAvatarSlotHandler| Uses this component to handle empty slots like head and hands on a spawning avatar.
|FillEmptySlots|Bool| Whether to fill empty AvatarObjectSlots with default head and hand objects if they are missing on their loaded avatar.
|FillEmptySlots|Bool| {{stub}}
}}
== Sync Delegates ==
{{Table ComponentTriggers
|SetupPositionStream:[[Type:Action`2|Action`2]]<[[Type:ValueStream`1|ValueStream`1]]<[[Type:Float3|Float3]]>, [[Type:Int|Int]]>|[[Type:Action`2|Action`2]]<[[Type:ValueStream`1|ValueStream`1]]<[[Type:Float3|Float3]]>, [[Type:Int|Int]]>|true| Used internally.
|SetupRotationStream:[[Type:Action`2|Action`2]]<[[Type:ValueStream`1|ValueStream`1]]<[[Type:FloatQ|FloatQ]]>, [[Type:Int|Int]]>|[[Type:Action`2|Action`2]]<[[Type:ValueStream`1|ValueStream`1]]<[[Type:FloatQ|FloatQ]]>, [[Type:Int|Int]]>|true| Used internally.
|LocomotionControllerInitialized:[[Type:Action`1|Action`1]]<[[Component:LocomotionController|LocomotionController]]>|[[Type:Action`1|Action`1]]<[[Component:LocomotionController|LocomotionController]]>|true| Used internally.
|UpdateLocomotionModules:[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| Updates the locomotion modules on every user with the ones specified with this component.
}}
== AvatarTemplate ==
{{Table TypeFields
|TemplateRoot|Slot| The avatar to use if this is chosen.
|OnlyForRole|'''[[#Role|Role]]'''|TypeAdv1=true| What role this choice should apply to.
|Weight|Float| The likelyness compared to other choices to choose this.
|MaxUsers|Int| How many users at maximum could be assigned this avatar at any given moment.
|BlockCloudAvatar|Bool| Whether the user's [[Favorites|Favorited]] avatar should be ignored.
}}
=== Role ===
{{Table EnumValues
|Anyone|0| Anyone will get the avatar.
|HostOnly|1| Only the host may get this avatar.
|GuestOnly|2| Only guests may get this avatar.
}}
}}
<!--T:4-->
<!--T:4-->
== Behavior ==
== Behavior ==
{{stub}}
This component gets read and executed every time a user respawns or joins into a world.
<!--T:5-->
<!--T:5-->
== Examples ==
== Examples ==
{{stub}}
Found under [[Root]] in every world, and is used to control user spawning.
[[Category:Components With Nested Types{{#translation:}}|Common Avatar Builder]]
Latest revision as of 22:58, 18 March 2025
This article or section is a Stub. You can help the Resonite Wiki by expanding it.
Component image
CommonAvatarBuilder component as seen in the Scene Inspector
Common Avatar Builder is a component that is part of every world that defines the spawning behavior and routines to do for all users when they spawn into a world. This can be used to add world settings menus, change what parts of a user get automatically set up, and so on.
A slot that will automatically be duplicated and added as a child of a user when they join the world. Certain components will use this to override user behavior when part of this slot's hierarchy, like Avatar Audio Configuration to name one.