BsCFixedJoint.cpp 938 B

12345678910111213141516171819202122232425262728293031323334353637
  1. //********************************** Banshee Engine (www.banshee3d.com) **************************************************//
  2. //**************** Copyright (c) 2016 Marko Pintera ([email protected]). All rights reserved. **********************//
  3. #include "BsCFixedJoint.h"
  4. #include "BsSceneObject.h"
  5. #include "BsCRigidbody.h"
  6. #include "BsCFixedJointRTTI.h"
  7. namespace BansheeEngine
  8. {
  9. CFixedJoint::CFixedJoint()
  10. :CJoint(mDesc)
  11. { }
  12. CFixedJoint::CFixedJoint(const HSceneObject& parent)
  13. : CJoint(parent, mDesc)
  14. {
  15. setName("FixedJoint");
  16. }
  17. SPtr<Joint> CFixedJoint::createInternal()
  18. {
  19. SPtr<Joint> joint = FixedJoint::create(mDesc);
  20. joint->_setOwner(PhysicsOwnerType::Component, this);
  21. return joint;
  22. }
  23. RTTITypeBase* CFixedJoint::getRTTIStatic()
  24. {
  25. return CFixedJointRTTI::instance();
  26. }
  27. RTTITypeBase* CFixedJoint::getRTTI() const
  28. {
  29. return CFixedJoint::getRTTIStatic();
  30. }
  31. }