Vehicle not moving properly

Hi,

I am trying to recreate the vehicle demo , and i am facing this problem, both the tires of my vehicle do not touch the track properly its something like this, the vehicle is moving and every thing else is fine ..

Image

how can i get this right ...

Thanks

Rrgards
Jin
Is fixedRotation = false for the car?
@Istvan - yes it is false , i h ave tested with true as well, but the vehicle just does not tilt on slopes and one of its wheels stay in air, any help will be great ...i have seen the parameters in demo also , cannot seem to find changing which parameter can get this problem sorted out ..

thanks again ...

Regards
Jin
Problem solved - i was able to solve the problem by recreating each object again including the one's that make up the bike, now my only problem is that any one can use the mouse to pick the bike up and throw it on stage how can i avoid that ....

Regards
Jin
allowDragging = false property should take care of that. Each object has its own property but the 'world' also has an allowDragging property that can disable allowDragging globally.

For my myWorld.allowDragging = false didn't work. So as mayobutter suggested, I disabled it with creating my own myWorld class that extends wck.World and then override the handleDragStart function with an empty function.
@istvan - thanks it worked .... 🙂

Regards
Jin
@Istvan , do you know how i can make sure that as the car moves on a track , it continues to stay in focus, i tried setting the "focuson" property of world to instance name of car but it does not seem to work ...

Regards
Jin
To create focus (i.e. camera target), use the focus property e.g. yourWorld.focus = targetDisplayObject;

That should take case of keeping the car in the center of the screen.
@istvan - thanks ,it helped ....

Regards
Jin

Original thread: https://box2d.org/forum/viewtopic.php?t=8811