Changeset 6222 in orxonox.OLD for trunk/src/world_entities/weapons/aim.cc
Legend:
- Unmodified
- Added
- Removed
-
trunk
-
Property
svn:ignore
set to
Makefile.in
Makefile
configure
*.kdevelop
Doxyfile
config.log
config.h
config.status
stamp-h1
autom4te.cache
aclocal.m4
-
Property
svn:ignore
set to
-
trunk/src
-
Property
svn:ignore
set to
.deps
orxonox
Makefile
Makefile.in
-
Property
svn:ignore
set to
-
trunk/src/world_entities/weapons/aim.cc
r6142 r6222 21 21 #include "graphics_engine.h" 22 22 #include "state.h" 23 #include "list.h"24 23 #include "material.h" 25 24 #include "t_animation.h" … … 104 103 void Aim::searchTarget(float range) 105 104 { 106 //FIXME// 107 /* tIterator<WorldEntity>* iterator = State::getWorldEntityList()->getIterator(); 108 WorldEntity* entity = iterator->firstElement(); 109 while (likely(entity != NULL)) 105 std::list<WorldEntity*>::iterator entity; 106 107 for (entity = State::getObjectManager()->getObjectList(OM_GROUP_00).begin(); 108 entity != State::getObjectManager()->getObjectList(OM_GROUP_00).end(); 109 entity ++) 110 110 { 111 if ( entity->isA(CL_NPC) && this->source->getAbsCoor().x < entity->getAbsCoor().x && (this->source->getAbsCoor() - entity->getAbsCoor()).len() < range)111 if (this->source->getAbsCoor().x < (*entity)->getAbsCoor().x && (this->source->getAbsCoor() - (*entity)->getAbsCoor()).len() < range) 112 112 { 113 if (this->getParent() != entity)113 if (this->getParent() != (*entity)) 114 114 { 115 115 this->anim->replay(); 116 this->setParentSoft(entity, 5); 116 this->setParentSoft(*entity, 5); 117 return; 117 118 } 118 delete iterator;119 return;120 119 } 121 entity = iterator->nextElement();122 120 } 123 124 delete iterator;*/125 121 } 126 122
Note: See TracChangeset
for help on using the changeset viewer.