WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
Old 03-11-2009, 09:51 PM
nlfrnassimi nlfrnassimi is offline
Join Date: Feb 2009
Posts: 37

I have tried to link my view to my avatar and make it first point of view. I have assigned r key to make avatar and view go to a certain point and also created another view to be able to change my view. I have tried to look side, up and down by pressing certain keys but they don't work properly and another problem is that my animated path (r key ) doesn't work now.

Please take a look at my code. and tell me what are the mistakes that I have made.

import viz



view = viz.MainView

character = viz.add('vcc_male.cfg') # Add a CAL3D based avatar
character.state(1) # Activate the walking state

viewLink = character, view)
viewLink.setDstFlag( viz.LINK_HEAD)
viewLink.preTrans( [-.4, .1, 0] )

vizact.whilekeydown(viz.KEY_UP,character.rotate,1, 0,0,vizact.elapsed(-15),viz.REL_PARENT)
vizact.whilekeydown(viz.KEY_RIGHT,character.rotate ,0,1,0,vizact.elapsed(15),viz.REL_PARENT)
vizact.whilekeydown(viz.KEY_LEFT,character.rotate, 0,1,0,vizact.elapsed(-15),viz.REL_PARENT)

def characterWalk (key):
if key == 'r':
walk = vizact.walkTo([10,0,0],1,45)

viz.callback(viz.KEYBOARD_EVENT, characterWalk)

secondView = viz.addView()

def anotherView (key):
if key == 'v':

viz.callback(viz.KEYBOARD_EVENT, anotherView,priority=1)
Reply With Quote

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

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

Similar Threads
Thread Thread Starter Forum Replies Last Post
view problem nlfrnassimi Vizard 3 03-11-2009 09:33 PM
Manipulating Tracker View Micha Vizard 3 02-25-2008 11:05 AM
problem with stereo mode shivanangel Vizard 3 10-17-2006 10:58 AM
Moving view with object Xliben Vizard 2 07-25-2005 06:36 PM
keeping a 3d object in front of the view tavaksai Vizard 1 07-07-2004 10:33 AM

All times are GMT -7. The time now is 04:54 PM.

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