Browse Source

Added const accessors for the BodyInterface

Jorrit Rouwe 3 years ago
parent
commit
a8f5c7904e
1 changed files with 2 additions and 0 deletions
  1. 2 0
      Jolt/Physics/PhysicsSystem.h

+ 2 - 0
Jolt/Physics/PhysicsSystem.h

@@ -58,7 +58,9 @@ public:
 	const PhysicsSettings &		GetPhysicsSettings() const									{ return mPhysicsSettings; }
 	const PhysicsSettings &		GetPhysicsSettings() const									{ return mPhysicsSettings; }
 
 
 	/// Access to the body interface. This interface allows to to create / remove bodies and to change their properties.
 	/// Access to the body interface. This interface allows to to create / remove bodies and to change their properties.
+	const BodyInterface &		GetBodyInterface() const									{ return mBodyInterfaceLocking; }
 	BodyInterface &				GetBodyInterface() 											{ return mBodyInterfaceLocking; }
 	BodyInterface &				GetBodyInterface() 											{ return mBodyInterfaceLocking; }
+	const BodyInterface &		GetBodyInterfaceNoLock() const								{ return mBodyInterfaceNoLock; } ///< Version that does not lock the bodies, use with great care!
 	BodyInterface & 			GetBodyInterfaceNoLock()									{ return mBodyInterfaceNoLock; } ///< Version that does not lock the bodies, use with great care!
 	BodyInterface & 			GetBodyInterfaceNoLock()									{ return mBodyInterfaceNoLock; } ///< Version that does not lock the bodies, use with great care!
 
 
 	/// Access to the broadphase interface that allows coarse collision queries
 	/// Access to the broadphase interface that allows coarse collision queries