Description
Controls whether this shape has solid collisions. When set to true
, the shape will interact with other solid objects in the physics simulation, allowing for realistic collision responses. When set to false
, the shape will not participate in solid collision detection, effectively making it non-collidable with other solid objects.
Usage
To enable or disable solid collisions for a PhysicsShape
, set the EnableSolidCollisions
property to true
or false
respectively. This can be useful for dynamically changing the collision behavior of objects in your game.
Example
// Example of enabling solid collisions for a PhysicsShape
PhysicsShape shape = new PhysicsShape();
shape.EnableSolidCollisions = true; // Enable solid collisions
// Example of disabling solid collisions for a PhysicsShape
shape.EnableSolidCollisions = false; // Disable solid collisions