$#include "Physics/Constraint.h" enum ConstraintType { CONSTRAINT_POINT = 0, CONSTRAINT_HINGE, CONSTRAINT_SLIDER, CONSTRAINT_CONETWIST }; class Constraint : public Component { void SetConstraintType(ConstraintType type); void SetOtherBody(RigidBody* body); void SetPosition(const Vector3& position); void SetRotation(const Quaternion& rotation); void SetAxis(const Vector3& axis); void SetOtherPosition(const Vector3& position); void SetOtherRotation(const Quaternion& rotation); void SetOtherAxis(const Vector3& axis); void SetWorldPosition(const Vector3& position); void SetHighLimit(const Vector2& limit); void SetLowLimit(const Vector2& limit); void SetERP(float erp); void SetCFM(float cfm); void SetDisableCollision(bool disable); PhysicsWorld* GetPhysicsWorld() const; ConstraintType GetConstraintType() const; RigidBody* GetOwnBody() const; RigidBody* GetOtherBody() const; const Vector3& GetPosition() const; const Quaternion& GetRotation() const; const Vector3& GetOtherPosition() const; const Quaternion& GetOtherRotation() const; Vector3 GetWorldPosition() const; const Vector2& GetHighLimit() const; const Vector2& GetLowLimit() const; float GetERP() const; float GetCFM() const; bool GetDisableCollision() const; tolua_readonly tolua_property__get_set PhysicsWorld* physicsWorld; tolua_property__get_set ConstraintType constraintType; tolua_readonly tolua_property__get_set RigidBody* ownBody; tolua_property__get_set RigidBody* otherBody; tolua_property__get_set Vector3& position; tolua_property__get_set Quaternion& rotation; tolua_property__get_set Vector3& axis; // Write only property. tolua_property__get_set Vector3& otherPosition; tolua_property__get_set Quaternion& otherRotation; tolua_property__get_set Vector3& otherAxis; // Write only property. tolua_property__get_set Vector3 worldPosition; tolua_property__get_set Vector2& highLimit; tolua_property__get_set Vector2& lowLimit; tolua_property__get_set float ERP; tolua_property__get_set float CFM; tolua_property__get_set bool disableCollision; }; ${ #define TOLUA_DISABLE_tolua_get_Constraint_axis_ref #define tolua_get_Constraint_axis_ref NULL #define TOLUA_DISABLE_tolua_get_Constraint_otherAxis_ref #define tolua_get_Constraint_otherAxis_ref NULL $}