controlling 3d object in real time?

Previous topic - Next topic

mars_chaos89

how can control a 3d model using the mouse?

right now im using :

mousestate x,y,mbl,mbr
x_screen2world x,y,0,   wx,wy,wz

if mbl=true then
  x_movement wx,wy,wz
endif

the problem with this is that the model is following the mouse only when i hold the left button but when i release it when back to its original place...how can i make the model to stay at the position when i move it after i release the mouse button?

MrTAToad

The X_MOVEMENT command should be outside the IF statement, but with X_SCREEN2WORLD being inside

mars_chaos89