Changeset 8166 in orxonox.OLD
- Timestamp:
- Jun 6, 2006, 1:33:36 AM (18 years ago)
- Location:
- branches/cr/src/lib/collision_reaction
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/cr/src/lib/collision_reaction/collision.cc
r8129 r8166 27 27 Collision::Collision () 28 28 { 29 this->entityA = NULL; 30 this->entityB = NULL; 31 32 this->bDispatched = false; 33 this->entityACollide = false; 34 this->entityBCollide = false; 29 this->flushCollisionEvents(); 35 30 } 36 31 -
branches/cr/src/lib/collision_reaction/collision_handle.cc
r8165 r8166 110 110 Collision* c; 111 111 if( this->collisionList.empty() || 112 ((this->collisionList.back())->getEntityA() != entityA && (this->collisionList.back())->getEntityB() != entityB )) 112 ((this->collisionList.back())->getEntityA() != entityA && (this->collisionList.back())->getEntityB() != entityB )) { 113 113 c = CREngine::getInstance()->popCollisionObject(); 114 c->collide(entityA, entityB); 115 this->collisionList.push_back(c); 116 } 114 117 else 115 118 c = this->collisionList.back(); 116 119 117 assert( entityA != NULL); 118 assert( entityB != NULL); 119 this->collisionList.push_back(c); 120 c->collide(entityA, entityB); 120 assert( c->getEntityA() != NULL); 121 assert( c->getEntityB() != NULL); 121 122 122 123 // now register it as a shared collision with the other collision entity … … 190 191 for(; it < this->collisionList.end(); it++) { 191 192 this->collisionReaction->reactToCollision(*it); 193 (*it)->flushCollisionEvents(); 192 194 } 193 195 -
branches/cr/src/lib/collision_reaction/cr_object_damage.cc
r8129 r8166 54 54 float damage; 55 55 56 assert(collision->getEntityA() != NULL); 57 assert(collision->getEntityB() != NULL); 58 56 59 PRINTF(0)("Dealing damage - Handling collision: %s vs %s\n", 57 60 collision->getEntityA()->getClassName(),
Note: See TracChangeset
for help on using the changeset viewer.