|
@@ -35,32 +35,35 @@ namespace bs
|
|
|
*/
|
|
*/
|
|
|
virtual void setIsTrigger(bool value) = 0;
|
|
virtual void setIsTrigger(bool value) = 0;
|
|
|
|
|
|
|
|
- /** Checks is the collider a trigger. */
|
|
|
|
|
|
|
+ /** @copydoc setIsTrigger() */
|
|
|
virtual bool getIsTrigger() const = 0;
|
|
virtual bool getIsTrigger() const = 0;
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
- * Changes whether the collider is a part of a rigidbody (non-static), or is on its own (static). You should change
|
|
|
|
|
- * this whenever you are attaching or detaching a collider from a rigidbody.
|
|
|
|
|
|
|
+ * Determines whether the collider is a part of a rigidbody (non-static), or is on its own (static). You should
|
|
|
|
|
+ * change this whenever you are attaching or detaching a collider from a rigidbody.
|
|
|
*/
|
|
*/
|
|
|
virtual void setIsStatic(bool value) = 0;
|
|
virtual void setIsStatic(bool value) = 0;
|
|
|
|
|
|
|
|
- /** Checks whether the collider is a part of a rigidbody (non-static), or is on its own (static). */
|
|
|
|
|
|
|
+ /** @copydoc setIsStatic() */
|
|
|
virtual bool getIsStatic() const = 0;
|
|
virtual bool getIsStatic() const = 0;
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
- * Sets the mass of the collider. Only relevant if the collider is part of a rigidbody. Ultimately this will
|
|
|
|
|
|
|
+ * Determines the mass of the collider. Only relevant if the collider is part of a rigidbody. Ultimately this will
|
|
|
* determine the total mass, center of mass and inertia tensors of the parent rigidbody (if they're being calculated
|
|
* determine the total mass, center of mass and inertia tensors of the parent rigidbody (if they're being calculated
|
|
|
* automatically).
|
|
* automatically).
|
|
|
*/
|
|
*/
|
|
|
virtual void setMass(float mass) { mMass = mass; }
|
|
virtual void setMass(float mass) { mMass = mass; }
|
|
|
|
|
|
|
|
- /** Returns the mass of the collider. */
|
|
|
|
|
|
|
+ /** @copydoc setMass() */
|
|
|
virtual float getMass() const { return mMass; }
|
|
virtual float getMass() const { return mMass; }
|
|
|
|
|
|
|
|
- /** Sets the material of the collider. The material determines how objects hitting the collider behave. */
|
|
|
|
|
|
|
+ /**
|
|
|
|
|
+ * Determines the physical material of the collider. The material determines how objects hitting the collider
|
|
|
|
|
+ * behave.
|
|
|
|
|
+ */
|
|
|
virtual void setMaterial(const HPhysicsMaterial& material);
|
|
virtual void setMaterial(const HPhysicsMaterial& material);
|
|
|
|
|
|
|
|
- /** Gets the material of the collider. The material determines how objects hitting the collider behave. */
|
|
|
|
|
|
|
+ /** @copydoc setMaterial() */
|
|
|
virtual HPhysicsMaterial getMaterial() const { return mMaterial; }
|
|
virtual HPhysicsMaterial getMaterial() const { return mMaterial; }
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
@@ -74,31 +77,31 @@ namespace bs
|
|
|
*/
|
|
*/
|
|
|
virtual void setContactOffset(float value) = 0;
|
|
virtual void setContactOffset(float value) = 0;
|
|
|
|
|
|
|
|
- /** Returns shape's contact offset in meters. See setContactOffset() to learn contact offset is. */
|
|
|
|
|
|
|
+ /** @copydoc setContactOffset() */
|
|
|
virtual float getContactOffset() const = 0;
|
|
virtual float getContactOffset() const = 0;
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
- * Sets at what distance should two objects resting on one another come to an equilibrium. The value used in the
|
|
|
|
|
- * runtime will be the sum of rest offsets for both interacting objects. This value is in meters. Cannot be larger
|
|
|
|
|
- * than contact offset.
|
|
|
|
|
|
|
+ * Determines at what distance should two objects resting on one another come to an equilibrium. The value used in
|
|
|
|
|
+ * the runtime will be the sum of rest offsets for both interacting objects. This value is in meters. Cannot be
|
|
|
|
|
+ * larger than contact offset.
|
|
|
*
|
|
*
|
|
|
* Also see setContactOffset().
|
|
* Also see setContactOffset().
|
|
|
*/
|
|
*/
|
|
|
virtual void setRestOffset(float value) = 0;
|
|
virtual void setRestOffset(float value) = 0;
|
|
|
|
|
|
|
|
- /** Returns shepe's rest offset in meters. See setRestOffset() to learn what contact offset is. */
|
|
|
|
|
|
|
+ /** @copydoc setRestOffset() */
|
|
|
virtual float getRestOffset() const = 0;
|
|
virtual float getRestOffset() const = 0;
|
|
|
|
|
|
|
|
- /** Sets the layer of the collider. Layer controls with which objects will the collider collide. */
|
|
|
|
|
|
|
+ /** Determines the layer of the collider. Layer controls with which objects will the collider collide. */
|
|
|
virtual void setLayer(UINT64 layer) = 0;
|
|
virtual void setLayer(UINT64 layer) = 0;
|
|
|
|
|
|
|
|
- /** Gets the layer of the collider. Layer controls with which objects will the collider collide. */
|
|
|
|
|
|
|
+ /** @copydoc setLayer() */
|
|
|
virtual UINT64 getLayer() const = 0;
|
|
virtual UINT64 getLayer() const = 0;
|
|
|
|
|
|
|
|
- /** Sets a value that determines which (if any) collision events are reported. */
|
|
|
|
|
|
|
+ /** Determines which (if any) collision events are reported. */
|
|
|
virtual void setCollisionReportMode(CollisionReportMode mode) = 0;
|
|
virtual void setCollisionReportMode(CollisionReportMode mode) = 0;
|
|
|
|
|
|
|
|
- /** Gets a value that determines which (if any) collision events are reported. */
|
|
|
|
|
|
|
+ /** @copydoc setCollisionReportMode() */
|
|
|
virtual CollisionReportMode getCollisionReportMode() const = 0;
|
|
virtual CollisionReportMode getCollisionReportMode() const = 0;
|
|
|
|
|
|
|
|
/** Enables continous collision detect for this collider. Only valid if the collider is a part of a rigidbody. */
|
|
/** Enables continous collision detect for this collider. Only valid if the collider is a part of a rigidbody. */
|