Difference between revisions of "AvatarExtended"

From Virtual World Web Wiki
Jump to: navigation, search
(Documentation for the AvatarExtended class)
(Documentation for the AvatarExtended class)
 
Line 12: Line 12:
 
:{{CSharp|RuntimeLayerExtended MyAppearance {get;} }}
 
:{{CSharp|RuntimeLayerExtended MyAppearance {get;} }}
 
::
 
::
::The appearance modification layer specific to this specific avatar instance
+
::The appearance modification layer specific to this specific avatar instance, the "Run-Time Appearance". (layer identifier ''layer.avatar.appearance'')
  
 
:{{CSharp|string Title {get; set;} }}
 
:{{CSharp|string Title {get; set;} }}
Line 30: Line 30:
 
::
 
::
 
::Clones the specified avatar modification layer, optionally hiding the source layer
 
::Clones the specified avatar modification layer, optionally hiding the source layer
 +
 +
:{{CSharp|RuntimeLayerExtended CreateLayer(string identifier)}}
 +
::
 +
::Creates a new layer on the avatar immediately "over" (covering) the standard MyAppearance layer. If a layer with the specified identifier already exists it will just be returned.
 +
 +
:{{CSharp|RuntimeLayerExtended CreateLayerOver(string identifier, AvatarLayerExtended otherLayer)}}
 +
::
 +
::Creates a new layer on the avatar immediately "over" (covering) the specified existing layer. If a layer with the specified identifier already exists it will just be returned.
 +
 +
:{{CSharp|RuntimeLayerExtended CreateLayerUnder(string identifier, AvatarLayerExtended otherLayer)}}
 +
::
 +
::Creates a new layer on the avatar immediately "under" (covered by) the specified existing layer. If a layer with the specified identifier already exists it will just be returned.
  
 
:{{CSharp|void Destroy()}}
 
:{{CSharp|void Destroy()}}

Latest revision as of 15:35, 20 September 2019

Represents an avatar which is a collection of DOM nodes starting with a root DOMController object and managed by the Creature Manager component

  • This is a JavaScript visible object

Remarks [edit]

Properties

DOMControllerExtended Body {get;}
The DOMControllerExtended for the body of the avatar
RuntimeLayerExtended MyAppearance {get;}
The appearance modification layer specific to this specific avatar instance, the "Run-Time Appearance". (layer identifier layer.avatar.appearance)
string Title {get; set;}
The Title of the bot

Methods

void AddHookpoint(string name)
Creates a new managed hookpoint that can be affected by appearance modifiaction layers
void BeginUpdate()
Starts an update batch for this avatar. You MUST call EndUpdate before your changes (or any other changes) will be visible. You should not hold an update batch for more than a single call scope.
RuntimeLayerExtended CloneLayer(RuntimeLayerExtended layer, string cloneIdentifier, bool hideSource = true)
Clones the specified avatar modification layer, optionally hiding the source layer
RuntimeLayerExtended CreateLayer(string identifier)
Creates a new layer on the avatar immediately "over" (covering) the standard MyAppearance layer. If a layer with the specified identifier already exists it will just be returned.
RuntimeLayerExtended CreateLayerOver(string identifier, AvatarLayerExtended otherLayer)
Creates a new layer on the avatar immediately "over" (covering) the specified existing layer. If a layer with the specified identifier already exists it will just be returned.
RuntimeLayerExtended CreateLayerUnder(string identifier, AvatarLayerExtended otherLayer)
Creates a new layer on the avatar immediately "under" (covered by) the specified existing layer. If a layer with the specified identifier already exists it will just be returned.
void Destroy()
Destroys the bot
void EndUpdate()
Ends an update batch for this avatar.
RuntimeLayerExtended FindLayer(string layerName)
Searches for the specified avatar modification layer
string GetMetadata(string key)
Gets a metadata value from this avatar
bool HasLayer(string identifier)
Tests to see if the specified avatar modification layer exists on this avatar
void HideLayer(RuntimeLayerExtended layer)
Hides the specified avatar modification layer
bool HookpointOccupied(string name)
Checks to see if after building the avatar, a particular clothing hookpoint was occupied
void PlayEffect(Guid objectTypeID)
Instantiates the specified object type, which must be a DOMEffect node under the avatar's body as a transient, temporary node
void Rebuild()
Forces a complete avatar rebuild
void Remove(string hookpointPath)
Remove a piece of clothing
void RemoveLayer(RuntimeLayerExtended layer)
Removes the specified avatar modification layer
void Say(string message)
Broadcasts a chat message in the local chat channel that appears to be from the bot
void SetMetadata(string key, string value)
Sets a metadata value on this avatar
void ShowLayer(RuntimeLayerExtended layer)
Shows the specified avatar modification layer
void StartAnimation(string layerName, string animationName, bool looping)
Plays the requested animation on the requested layer
void StopAnimation(string layerName, string animationName)
Same as above, but for bots in a room rather than player avatars
void Wear(string hookpointPath, Guid objectTypeID)
Wear a piece of clothing