|
#1
|
|||
|
|||
help with slider code
Code:
import viz viz.go() #Initialize avatar male = viz.add('vcc_male.cfg') male.setPosition(0,0,5) male.setEuler(180,0,0) ANIM = 6 DUR = male.getDuration(ANIM) #Start animation male.execute(ANIM) male.setAnimationSpeed(ANIM,0) #Speed must be set after animation is executed #Use slider to modify animation time slider = viz.addSlider(pos=(0.5,0.1,0)) def myslider(pos): male.setAnimationTime(ANIM,pos*DUR-0.01) vizact.onslider(slider,myslider) This code is helpful but I am stuck on trying to get my avatar to make more actions. how do I get my avatar to jump, in other words more than one action.. Thank you |
#2
|
|||
|
|||
That example code uses the ANIM variable to control which action of the avatar to play. If you change the value to another animation number, then the slider will control a different animation.
|
#3
|
|||
|
|||
I understand that part because I experimented with it..what I want to do is to either have multiple sliders to control different actions or from a push of a button have teh actions automatically change I was thinking of adding an "if" statement to do that but I am still having problems. any suggestions? you have been a great deal of help.
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
meaning of code | yak | Vizard | 3 | 07-15-2009 01:18 PM |
Any ideas on linking chess 3ds file with source code? | djones1010 | Vizard | 1 | 04-24-2009 09:56 PM |
Trying to integrate Source Code with Vizard | djones1010 | Vizard | 1 | 03-10-2009 02:58 PM |
Vizmenu slider bug? | Gladsomebeast | Vizard | 2 | 10-22-2008 08:05 PM |
Vizard Tip of the Month: Use Tasks to Simplify your Code | Gladsomebeast | Vizard | 5 | 05-02-2008 04:30 PM |