Make cone fall over

Software: Away3D 4.x

dmk, Jr. Member
Posted: 28 August 2014 11:57 AM   Total Posts: 32

So I create a cone like this:

coneShape = new AWPConeShape(3528);
//Flip it upside down
coneShape.localScaling = new Vector3D(1,-1,1,1);
body = new AWPRigidBody(coneShapenull1);


Now why won’t it fall over? (if I placed a cone on its tip in the real world, it would fall over)



dmk, Jr. Member
Posted: 28 August 2014 12:09 PM   Total Posts: 32   [ # 1 ]

And similarly, I try to spin it with applyTorque- and it does spin, but then it never slows down and stops o_O

Tried setting friction but that didn’t change anything..


John Brookes, Moderator
Posted: 28 August 2014 06:02 PM   Total Posts: 732   [ # 2 ]

In the real world, things are not perfect.
vibrations air surfaces etc etc.
Some things you will have to fake (add forces)

edit just to add
Add some damping to the rotation


dmk, Jr. Member
Posted: 31 August 2014 11:57 AM   Total Posts: 32   [ # 3 ]

OK, I’m able to get it to fall over by doing two things… leaving either of these out results in the object standing on its tip

1) changing the center of mass

At least I think that’s what I’m doing… offset the Y position by some amount, and put the shape in a AWPCompoundShape, and then to make sure the visuals match I offset the mesh by that same amount and add that to an ObjectContainer3D. Those container AWPCompoundShape and ObjectContainer3D are what I then add that to the body/scene

2) Apply a force toward the top of the object

So now, when I also add the torqueImpulse… it does look kinda like a spinning top, but is going far too long… you mention damping- is there a setting for that somewhere?


dmk, Jr. Member
Posted: 31 August 2014 11:58 AM   Total Posts: 32   [ # 4 ]

To be clear- if I leave out changing the center of mass, it falls over but then stands up again. Kinda like those punching balloons smile



Away3D Forum

Member Login