This is a helper class for configuring physics settings of an ActorRigid. More...
#include <actorphysicssettings.h>
Public Member Functions | |
| ActorRigidPhysicsSettings (ActorRigid *Actor, btRigidBody *PhysicsObject) | |
| Standard Constructor. | |
| virtual | ~ActorRigidPhysicsSettings () |
| Class destructor. | |
| virtual void | ApplyForce (const Vector3 &Force) |
| Push/Apply force to an object. | |
| virtual void | ApplyTorque (const Vector3 &Torque) |
| Spin/Apply Torque to an object. | |
| virtual void | ClearStickyContacts () |
| Removes all the constraints currently active on this object. | |
| virtual Real | GetAngularDamping () const |
| Get the Angular damping. | |
| virtual Vector3 | GetAngularVelocity () const |
| Gets the Angular Velocity of this object. | |
| virtual Vector3 | GetForce () const |
| Get the total Force/Movement on the actor. | |
| virtual Vector3 | GetIndividualGravity () const |
| Gets the gravity being applied to this object. | |
| virtual Real | GetLinearDamping () const |
| Get the linear damping. | |
| virtual Vector3 | GetLinearVelocity () const |
| Gets the Linear Velocity of this object. | |
| virtual Vector3 | GetLocalInertia () const |
| Get the current intertia of the Actor. | |
| virtual Real | GetMass () const |
| Get the total Mass of the actor. | |
| virtual StickyData * | GetStickyData () const |
| Gets the struct storing the data related to sticky behavior. | |
| virtual Vector3 | GetTorque () const |
| Get the Torque/Rotation. | |
| virtual void | ProtoDeSerialize (const xml::Node &OneNode) |
| Take the data stored in an XML and overwrite this instance of this object with it. | |
| virtual void | ProtoSerialize (xml::Node &CurrentRoot) const |
| Convert this class to an xml::Node ready for serialization. | |
| virtual void | SetAngularVelocity (const Vector3 &AngVel) |
| Sets the Angular Velocity of this object. | |
| virtual void | SetCollisionShape (CollisionShape *Shape) |
| Sets the collision shape to be used. | |
| virtual void | SetDamping (const Real &LinDamping, const Real &AngDamping) |
| Sets the Damping for this object. | |
| virtual void | SetIndividualGravity (const Vector3 &Gravity) |
| Sets the gravity for only this object. | |
| virtual void | SetLinearVelocity (const Vector3 &LinVel) |
| Sets the Linear Velocity of this object. | |
| virtual void | SetMass (Real NewMass) |
| Change the mass of the object. | |
| virtual void | SetMass (Real NewMass, const Vector3 &NewInertia) |
| Change the mass of the object. | |
| virtual void | SetStickyData (const Whole &MaxNumContacts) |
| Sets the basic parameters for enabling sticky behavior with this actor. | |
Static Public Member Functions | |
| static String | SerializableName () |
| Get the name of the the XML tag this class will leave behind as its instances are serialized. | |
Protected Attributes | |
| btRigidBody * | ActorRB |
| Physics Object of the actor. | |
| ActorRigid * | RigidParent |
| The Actor this belongs to. | |
| StickyData * | StickyContacts |
| Data related to sticky behavior, if any is enabled. | |
This is a helper class for configuring physics settings of an ActorRigid.
This class contains functions for the configuring of physics specific settings of an ActorRigid. This class can only configure the ActorRigids physics. For configuring actor graphics, see ActorGraphicsSettings.
Definition at line 179 of file actorphysicssettings.h.
| Mezzanine::ActorRigidPhysicsSettings::ActorRigidPhysicsSettings | ( | ActorRigid * | Actor, |
| btRigidBody * | PhysicsObject | ||
| ) |
Standard Constructor.
| Actor | The actor this settings class configures. |
| PhysicsObject | The physics object belonging to the actor this class configures. |
Definition at line 177 of file actorphysicssettings.cpp.
| Mezzanine::ActorRigidPhysicsSettings::~ActorRigidPhysicsSettings | ( | ) | [virtual] |
Class destructor.
Definition at line 190 of file actorphysicssettings.cpp.
| void Mezzanine::ActorRigidPhysicsSettings::ApplyForce | ( | const Vector3 & | Force | ) | [virtual] |
Push/Apply force to an object.
| Force | The amount and direction of the force in a Vector3 |
Definition at line 285 of file actorphysicssettings.cpp.
| void Mezzanine::ActorRigidPhysicsSettings::ApplyTorque | ( | const Vector3 & | Torque | ) | [virtual] |
Spin/Apply Torque to an object.
| Torque | The amount and direction of the torque in a Vector3 |
Definition at line 288 of file actorphysicssettings.cpp.
| Real Mezzanine::ActorRigidPhysicsSettings::GetAngularDamping | ( | ) | const [virtual] |
Get the Angular damping.
Definition at line 258 of file actorphysicssettings.cpp.
| Vector3 Mezzanine::ActorRigidPhysicsSettings::GetAngularVelocity | ( | ) | const [virtual] |
Gets the Angular Velocity of this object.
Definition at line 270 of file actorphysicssettings.cpp.
| Vector3 Mezzanine::ActorRigidPhysicsSettings::GetForce | ( | ) | const [virtual] |
Get the total Force/Movement on the actor.
Definition at line 279 of file actorphysicssettings.cpp.
| Vector3 Mezzanine::ActorRigidPhysicsSettings::GetIndividualGravity | ( | ) | const [virtual] |
Gets the gravity being applied to this object.
This is the gravity applied to this object, which may or may not be the same as the world gravity.
Definition at line 276 of file actorphysicssettings.cpp.
| Real Mezzanine::ActorRigidPhysicsSettings::GetLinearDamping | ( | ) | const [virtual] |
Get the linear damping.
Definition at line 255 of file actorphysicssettings.cpp.
| Vector3 Mezzanine::ActorRigidPhysicsSettings::GetLinearVelocity | ( | ) | const [virtual] |
Gets the Linear Velocity of this object.
Definition at line 264 of file actorphysicssettings.cpp.
| Vector3 Mezzanine::ActorRigidPhysicsSettings::GetLocalInertia | ( | ) | const [virtual] |
Get the current intertia of the Actor.
Definition at line 294 of file actorphysicssettings.cpp.
| Real Mezzanine::ActorRigidPhysicsSettings::GetMass | ( | ) | const [virtual] |
Get the total Mass of the actor.
Definition at line 291 of file actorphysicssettings.cpp.
| StickyData * Mezzanine::ActorRigidPhysicsSettings::GetStickyData | ( | ) | const [virtual] |
Gets the struct storing the data related to sticky behavior.
Definition at line 249 of file actorphysicssettings.cpp.
| Vector3 Mezzanine::ActorRigidPhysicsSettings::GetTorque | ( | ) | const [virtual] |
Get the Torque/Rotation.
Definition at line 282 of file actorphysicssettings.cpp.
| void Mezzanine::ActorRigidPhysicsSettings::ProtoDeSerialize | ( | const xml::Node & | OneNode | ) | [virtual] |
Take the data stored in an XML and overwrite this instance of this object with it.
| OneNode | and xml::Node containing the data. |
Reimplemented from Mezzanine::ActorBasePhysicsSettings.
Definition at line 365 of file actorphysicssettings.cpp.
| void Mezzanine::ActorRigidPhysicsSettings::ProtoSerialize | ( | xml::Node & | CurrentRoot | ) | const [virtual] |
Convert this class to an xml::Node ready for serialization.
| CurrentRoot | The point in the XML hierarchy that all this quaternion should be appended to. |
Reimplemented from Mezzanine::ActorBasePhysicsSettings.
Definition at line 305 of file actorphysicssettings.cpp.
| String Mezzanine::ActorRigidPhysicsSettings::SerializableName | ( | ) | [static] |
Get the name of the the XML tag this class will leave behind as its instances are serialized.
Reimplemented from Mezzanine::ActorBasePhysicsSettings.
Definition at line 456 of file actorphysicssettings.cpp.
| void Mezzanine::ActorRigidPhysicsSettings::SetAngularVelocity | ( | const Vector3 & | AngVel | ) | [virtual] |
Sets the Angular Velocity of this object.
| AngVel | Vector3 representing the Angular Velocity to be set. |
Definition at line 267 of file actorphysicssettings.cpp.
| void Mezzanine::ActorRigidPhysicsSettings::SetCollisionShape | ( | CollisionShape * | Shape | ) | [virtual] |
Sets the collision shape to be used.
| Shape | The shape to be applied. |
Reimplemented from Mezzanine::WorldObjectPhysicsSettings.
Definition at line 198 of file actorphysicssettings.cpp.
| void Mezzanine::ActorRigidPhysicsSettings::SetDamping | ( | const Real & | LinDamping, |
| const Real & | AngDamping | ||
| ) | [virtual] |
Sets the Damping for this object.
Both of Linear Damping and Angular Damping default to zero. This is useful if you wish to simulate something like air resistance. Values can range from 0.0 to 1.0.
| LinDamping | Real representing the amount of Linear Damping(Movement) to be applied. |
| AngDamping | Real representing the amount of Angular Damping(Rotation) to be applied. |
Definition at line 252 of file actorphysicssettings.cpp.
| void Mezzanine::ActorRigidPhysicsSettings::SetIndividualGravity | ( | const Vector3 & | Gravity | ) | [virtual] |
Sets the gravity for only this object.
This value will override the world gravity. Should be called after adding to the world. When the object is added to the world the world gravity is applied to it.
| Gravity | Vector3 representing the direction and strength of gravity to be applied. |
Definition at line 273 of file actorphysicssettings.cpp.
| void Mezzanine::ActorRigidPhysicsSettings::SetLinearVelocity | ( | const Vector3 & | LinVel | ) | [virtual] |
Sets the Linear Velocity of this object.
| LinVel | Vector3 representing the Linear Velocity to be set. |
Definition at line 261 of file actorphysicssettings.cpp.
| void Mezzanine::ActorRigidPhysicsSettings::SetMass | ( | Real | NewMass | ) | [virtual] |
Change the mass of the object.
| NewMass | The amount of mass this should have. |
Definition at line 297 of file actorphysicssettings.cpp.
| void Mezzanine::ActorRigidPhysicsSettings::SetMass | ( | Real | NewMass, |
| const Vector3 & | NewInertia | ||
| ) | [virtual] |
Change the mass of the object.
| NewMass | The amount of mass this should have. |
| NewInertia | The new inertia the object has. |
Definition at line 300 of file actorphysicssettings.cpp.
| void Mezzanine::ActorRigidPhysicsSettings::SetStickyData | ( | const Whole & | MaxNumContacts | ) | [virtual] |
Sets the basic parameters for enabling sticky behavior with this actor.
| MaxNumContacts | The maximum number of object this object can stick to or have stuck to it. |
Definition at line 217 of file actorphysicssettings.cpp.
1.7.3