Passive/non-Dynamic rigid body via Haxe?

I’m trying to generate procedural terrain, and part of that involves setting the mesh rigid body to passive/non-Dynamic via Haxe. I have tried rb.body.activate(false) as well as rb.setActivationState() to multiple values without results.
Is this possible to do currently via Haxe?
Here’s how I’m implementing my rigid body currently If it helps:

var rb = new armory.trait.physics.RigidBody();
// Set as passive/non-Dynamic


Just set the mass to 0 as the first parameter of the RigidBody trait’s constructor:

var rb = new armory.trait.physics.RigidBody(0);

That will make the object passive.


Sorry to necro this, but it seems that now armory.trait.physics.RigidBody has no parameters on it’s constructor, and if I try to use armory.trait.physics.bullet.RigidBody(0) the rigid body is still active, how would you do now to create a passive rigid body or to alter other rigid body parameters?

has no parameters on it’s constructor

Have you looked at the implementation of the class for Bullet?

Alternatively the oimo implementation too:

1 Like

Thanks, after looking at the code for Bullet I realized I just neededd to set the params and flags, I missed that before.