- Timestamp:
- Oct 4, 2015, 9:12:21 PM (9 years ago)
- Location:
- code/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk
-
code/trunk/src/orxonox/collisionshapes/CollisionShape.cc
r10216 r10624 41 41 #include "CompoundCollisionShape.h" 42 42 #include "WorldEntityCollisionShape.h" 43 #include "Scene.h" 43 44 44 45 namespace orxonox 45 46 { 46 RegisterAbstractClass(CollisionShape).inheritsFrom (Class(BaseObject)).inheritsFrom(Class(Synchronisable));47 RegisterAbstractClass(CollisionShape).inheritsFrom<BaseObject>().inheritsFrom<Synchronisable>(); 47 48 48 49 /** … … 74 75 { 75 76 // Detach from parent CompoundCollisionShape. 76 if (this->isInitialized() && this->parent_) 77 this->parent_->detach(this); 77 if (this->isInitialized()) 78 { 79 if (this->getScene() && this->getScene()->isUpdatingPhysics()) 80 orxout(internal_error) << "Don't destroy collision shapes while the physics is updated! This will lead to crashes. Try to use destroyLater() instead" << endl; 81 82 if (this->parent_) 83 this->parent_->detach(this); 84 85 if (this->collisionShape_) 86 delete this->collisionShape_; 87 } 78 88 } 79 89
Note: See TracChangeset
for help on using the changeset viewer.