Changeset 10109 in orxonox.OLD for branches/playability/src
- Timestamp:
- Dec 19, 2006, 11:14:27 PM (18 years ago)
- Location:
- branches/playability/src/world_entities
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/playability/src/world_entities/projectiles/hbolt.cc
r10104 r10109 117 117 { 118 118 printf("Collision with HBolt\n"); 119 if (this->hitEntity != entity /* && entity->isA(CL_NPC)*/|| entity == this->target)119 if (this->hitEntity != entity && entity->isA(CL_NPC) || entity == this->target) 120 120 this->destroy( entity ); 121 121 this->hitEntity = entity; 122 122 dynamic_cast<SpaceShip*>(entity)->damage( this->getPhysDamage(), this->getElecDamage()); 123 //this->deactivate();123 this->deactivate(); 124 124 } 125 125 -
branches/playability/src/world_entities/projectiles/swarm_projectile.cc
r10104 r10109 137 137 this->hitEntity = entity; 138 138 dynamic_cast<SpaceShip*>(entity)->damage(this->getPhysDamage(),this->getElecDamage()); 139 this->destroy( NULL);139 this->destroy(this); 140 140 } 141 141 … … 243 243 this->lastDir = this->curDir; 244 244 this->curDir = this->velocity; 245 if( (this->getAbsCoor() - this->target->getAbsCoor()).len() < 1) // FIXME Temp fake workaround for collision :)245 if( (this->getAbsCoor() - this->target->getAbsCoor()).len() < 3) // FIXME Temp fake workaround for collision :) 246 246 { 247 247 dynamic_cast<WorldEntity*>(target)->destroy( this); … … 256 256 { 257 257 258 printf("THIS SHOULD WORK!\n");258 // printf("THIS SHOULD WORK!\n"); 259 259 260 260 Projectile::destroy( killer ); -
branches/playability/src/world_entities/space_ships/space_ship.cc
r10107 r10109 376 376 this->secWeaponMan.showCrosshair(); 377 377 this->toList( OM_GROUP_01 ); 378 /*378 379 379 for(ObjectList<PNode>::const_iterator it = this->getNodesChildren().begin(); it != this->getNodesChildren().end(); it++) 380 380 { 381 381 if( likely( dynamic_cast<Weapon*>(*it) != NULL)) 382 382 dynamic_cast<WorldEntity*>(*it)->toList( OM_GROUP_01); 383 } */383 } 384 384 //dynamic_cast<Element2D*>(this->secWeaponMan.getFixedTarget())->setVisibility( true); 385 385 //this->attachCamera(); … … 391 391 this->secWeaponMan.hideCrosshair(); 392 392 this->toList( OM_GROUP_00); 393 /*393 394 394 for(ObjectList<PNode>::const_iterator it = this->getNodesChildren().begin(); it != this->getNodesChildren().end(); it++) 395 395 { 396 396 if( likely( dynamic_cast<Weapon*>(*it) != NULL)) 397 397 dynamic_cast<WorldEntity*>(*it)->toList( OM_GROUP_00); 398 } */398 } 399 399 //dynamic_cast<Element2D*>(this->secWeaponMan.getFixedTarget())->setVisibility( false); 400 400 //this->detachCamera(); -
branches/playability/src/world_entities/weapons/heavy_blaster.cc
r10046 r10109 101 101 pj->setAbsCoor(this->getEmissionPoint()); 102 102 pj->setAbsDir(this->getAbsDir()); 103 pj->toList(OM_GROUP_01_PROJ); 103 104 pj->activate(); 104 105 } -
branches/playability/src/world_entities/weapons/light_blaster.cc
r10046 r10109 98 98 pj->setAbsCoor(this->getEmissionPoint()); 99 99 pj->setAbsDir(this->getAbsDir()); 100 pj->toList(OM_GROUP_01_PROJ); 100 101 pj->activate(); 101 102 } -
branches/playability/src/world_entities/weapons/medium_blaster.cc
r10098 r10109 100 100 pj->setAbsCoor(this->getEmissionPoint()); 101 101 pj->setAbsDir(this->getAbsDir()); 102 pj->toList(OM_GROUP_01_PROJ); 102 103 pj->activate(); 103 104 } -
branches/playability/src/world_entities/weapons/swarm_launcher.cc
r10107 r10109 163 163 pj->setAbsDir(this->getAbsDir()); 164 164 dynamic_cast<SwarmProjectile*>(pj)->setTarget( (PNode*)(*eIterator) ); 165 pj->toList(OM_GROUP_01_PROJ); 165 166 pj->activate(); 166 167 167 } 168 168 }
Note: See TracChangeset
for help on using the changeset viewer.