#1
|
|||
|
|||
Physics - addThruster
Hello,
i applied a constant force on an object and i wanted to change its value Code:
F=[0,0,0] def UpdateThruster(): force=ball.addThruster(mode=viz.ABS_GLOBAL,force=F) vizact.ontimer(0,UpdateThruster) def onKeyDown(key): if key == ' ': F[2]=1 viz.callback(viz.KEYDOWN_EVENT,onKeyDown) so, when i press space once, the ball starts accelerating very fast please i need to apply a force and change its value anytime i want...how can i do this ?? Last edited by moneim230; 07-03-2010 at 11:45 AM. |
#2
|
|||
|
|||
You can zero out any forces already added with the <node3D>.reset method.
|
#3
|
|||
|
|||
Quote:
i have a question here is there a better way than this (calling a function with 0 timer) to update the value of the force actually i am working on a vehicle model and i need to get the inertia force applied when i leave the gas pedal |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
help with augmented reality and physics | Darkmax | Vizard | 1 | 06-12-2010 03:26 PM |
RE:Slide Joints and physics optimization | nige777 | Vizard | 4 | 06-22-2009 04:21 PM |
Physics and Haptics | jalvarez | Vizard | 3 | 07-16-2008 03:03 PM |
collision with physics enabled | joeymax | Vizard | 2 | 04-17-2008 02:49 PM |
another physics question | adimov | Vizard | 1 | 07-22-2004 03:56 PM |