Vizard 7 » Command Index » Vizard objects » node3d » <node3d:avatar>.getConfigValue
7.7

<node3d:avatar>.getConfigValue

Returns a configuration value

<node3d:avatar>.getConfigValue(  
name  
default = ''  
)  
name
Name of configuration value
default = ''
Default value to return if config value does not exist.

Remarks

This command will return the specified configuration value of the avatar. A configuration value is declared in the avatars cfg file. If the value does not exist, 'default' will be returned.

The value will have all leading and trailing whitespace removed. If the value is surrounded by double quotations marks, then the entire string inside the quotations will be returned.

Here is a list of optional values that are used by Vizard:

Name

jaw_bone

Name of the bone to use for speech actions.

head_mesh

Name of the mesh representing the head. Vizard will automatically hide this mesh when a face is attached to the avatar.

neck_bone

Name of the bone Vizard will use to connect the neck vertices of a face to the avatar.

head_bone

Name of the bone Vizard will use to connect the face to the avatar.

idle_anim

The animation number that Vizard will use to place the avatar in an idle state.

Return Value

String value

Example

Example cfg file:
.
.
.
head_mesh = head.cmf
jaw_bone = skel_Jaw
walk_animation = 2

Example code:
#This will print out 'head.cmf'
print(avatar.getConfigValue('head_mesh'))

#This will print out 'skel_Jaw'
print(avatar.getConfigValue('jaw_bone'))

#This will print out '2'
print(avatar.getConfigValue('walk_animation'))

#This will print out 'default'
print(avatar.getConfigValue('non existent option','default'))