Avatar standard

From Resonite Wiki
Revision as of 11:20, 6 August 2025 by Colin The Cat (talk | contribs) (Create Avatar Standard page)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Standardization is required for collaboration and shared assets. This is a proposal made by Colin The Cat which standardizes a list of Dynamic Variables on the "Avatar" namespace to make avatar systems interoperable and portable and enables artists to create assets which can easily be installed on avatars without using any developer tools.

Avatar systems are anything that goes on top of an avatar base. This includes ProtoFlux logic and other assets such as clothing or body parts.

All variables must be defined including their namespace to avoid them accidentally binding to the wrong namespace: Avatar/VariableName. The namespace must not rely on non-direct binding of variables.

Dynamic Variables
Name Type Purpose
Root Slot Root slot of the avatar.
User User The user that has the avatar equipped as assigned by the Avatar User Reference Assigner.
HasUser bool If the avatar is currently equipped.
IsAway bool If the user of the avatar is shown as away.
Base String Name of the avatar base. Examples: Davali, Mayu.
Name String Name of the avatar slot.
Bone.Name Slot All bones of the rig using the original bone names.
BodyNode.Name Slot All armature body nodes using Body Node names.
BodyNode.Name.Bone Slot The associated fake bone, if one is being used.
BodyNode.Name.Hidden bool If the body part should be hidden.
Proxy.Name Slot Proxies using the Body Node names.
RigCollidersEnabled bool As set by Component:VRIKAvatar rigCollidersEnabledStates.
Renderers Slot All renderers are children of this slot.
Renderer.Mesh SkinnedMeshRenderer
MeshRenderer
Renderer.Mesh.Enabled bool Defaults to true.
Material.Name IAssetProvider<Material>
Material.Name.Away IAssetProvider<Material> Material version when IsAway is true.
Menu Slot Radial menu items root slot.
Menu colorX Avatar menu color.
Menu IAssetProvider<Sprite> Avatar menu icon.
Systems Slots All systems are children of this slot.
Voice IWorldAudioDataSource Assigned by Avatar Voice Source Assigner.
VisemeAnalyzer VisemeAnalyzer
VisemeAnalyzer.Strength float Defaults to 1.
VisemeAnalyzer.VoiceOverride IWorldAudioDataSource Defaults to Voice.

Systems

Avatar systems can be installed by moving their root slot under Avatar/Systems. They can be deleted by moving them out of the avatar and deleting them after at least 5 ticks. This ensures that all driven parents are moved under the system slot.

Systems can install slots anywhere on the avatar by creating a Dynamic Reference Variable Driver for the parent field of the slot that needs to be somewhere outside of the system's hierarchy. The driver needs to stay under the system's hierarchy and the default value needs to be under it as well to ensure that all slots are removed from the avatar when the system is moved out. It is also recommended to add Destroy Proxies for all slots which are moved outside of the system's hierarchy.

A system can be used to store any customizations such as custom materials (including textures), avatar slot name, menu color/icon by creating a dynamic field on an asset loader (for assets) or a dynamic reference variable which have override on link enabled.

Tools

The process of creating the dynamic variables can be partially automated. A tool for creating them and for moving and installing systems can be found at the following record:

resrec:///U-1QbdepR26LI/R-7dc75818-8a95-4a6d-b3b8-3a9010cbf0af