WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #2  
Old 09-23-2005, 10:23 AM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
Hi,

You are mixing the term action and animation together, when they are two separate concepts. Vizard comes with the ability to create high-level actions that can be added to any node object. Take a look in the documentation under the Actions section for more info. In addition to this, avatars have the low-level ability to play/blend built-in animations.

When you call <avatar>.act() it actually creates an action which will execute the animation and adds it to the avatar. For backwards compatiblity with older scripts, whenever an action is finished it stops the avatars current built-in animations. To get around this you could do the following:
Code:
#Create an action that will execute animation 5
anim5 = vizact.animation(5)

#Add the action to the avatar on action pool 1
avatar.add(anim5,1)

def onactionend(obj,action,pool):
    if action == anim5:
        print 'Avatar has finished executing action 5'
avatar.callback(viz.ACTION_END_EVENT,onactionend)
The object anim5 is an instance of viz.ActionData which will be returned to all callback functions.

Hope this explains everything for you. I know that the documentation on this stuff is very sparse, so let me know if something is not clear.
Reply With Quote
 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 04:27 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
Copyright 2002-2023 WorldViz LLC