WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #2  
Old 10-06-2008, 08:36 AM
Andy Andy is offline
Member
 
Join Date: Mar 2008
Location: Germany
Posts: 36
For the second "problem" I found a posible solution:

Code:
if key == 'z': #forward
	origin.setPosition(
		(origin.getPosition()[0]+(math.sin(vizmat.DEG_TO_RAD*origin.getEuler()[0])*0.1)),
		(origin.getPosition()[1]),
		(origin.getPosition()[2]+(math.cos(vizmat.DEG_TO_RAD*origin.getEuler()[0])*0.1))
	)
if key == 'b': #backwards
	origin.setPosition(
		(origin.getPosition()[0]-(math.sin(vizmat.DEG_TO_RAD*origin.getEuler()[0])*0.1)),
		(origin.getPosition()[1]),
		(origin.getPosition()[2]-(math.cos(vizmat.DEG_TO_RAD*origin.getEuler()[0])*0.1))
	)
and so on

Do you know a better way?
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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Reading bone movement from animations Enlil Vizard 5 08-14-2008 02:29 PM
Mouse/Keyboard Movement joeymax Vizard 1 04-02-2007 10:43 AM
viewpoint movement spacefarer Vizard 4 12-02-2004 07:23 AM
eye movement epl Vizard 1 06-04-2004 12:29 PM
movement problems keastman Precision Position Tracker (PPT) 1 09-09-2003 11:41 AM


All times are GMT -7. The time now is 12:32 PM.


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