WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 03-23-2009, 01:29 AM
Moh200jo Moh200jo is offline
Member
 
Join Date: Feb 2009
Posts: 99
Avatar

My application requires the avatar to walk for unknown distance and direction; mouse or keyboard should control the direction. How vizard do that?
Any suggestion would be really appreciated.
Thanks,
Reply With Quote
  #2  
Old 03-24-2009, 09:06 AM
Jeff Jeff is offline
WorldViz Team Member
 
Join Date: Aug 2008
Posts: 2,471
Within your keyboard callback function get the avatar's position and, for example if viz.KEY_UP is pressed, create a walkTo action where the z value is incremented. Something like this

Code:
pos = avatar.getPosition()

if key == viz.KEY_UP:
	walk_Forward = vizact.walkTo([pos[0], pos[1], pos[2] + 3])
	avatar.addAction(walk_Forward)
Reply With Quote
Reply

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
Has user perception of avatar expressions been tested? Karla Vizard 3 10-28-2008 10:32 AM
Collision of an avatar with a quad Frank Verberne Vizard 8 06-04-2008 09:44 AM
Looking through the eyes of an avatar Frank Verberne Vizard 2 04-01-2008 05:52 AM
avatar neck too short aa-chris Vizard 2 10-16-2007 09:28 AM
Avatars in an array and link/unlink betancourtb82 Vizard 7 09-05-2006 04:06 PM


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


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