Changeset 1591 for code/branches/core3/src/orxonox
- Timestamp:
- Jun 12, 2008, 2:00:15 AM (17 years ago)
- Location:
- code/branches/core3/src/orxonox
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/core3/src/orxonox/GraphicsEngine.cc
r1586 r1591 47 47 #include "core/CoreIncludes.h" 48 48 #include "core/ConfigValueIncludes.h" 49 #include "core/Iterator.h" 49 50 #include "core/CommandExecutor.h" 50 51 #include "core/ConsoleCommand.h" … … 100 101 101 102 if (this->detailLevelParticle_ != old) 102 for ( Iterator<ParticleInterface>it = ObjectList<ParticleInterface>::begin(); it; ++it)103 for (ObjectList<ParticleInterface>::iterator it = ObjectList<ParticleInterface>::begin(); it; ++it) 103 104 it->detailLevelChanged(this->detailLevelParticle_); 104 105 } -
code/branches/core3/src/orxonox/Orxonox.cc
r1586 r1591 54 54 // core 55 55 #include "core/ConfigFileManager.h" 56 #include "core/Iterator.h" 56 57 #include "core/ConsoleCommand.h" 57 58 #include "core/Loader.h" … … 75 76 #include "GraphicsEngine.h" 76 77 #include "Settings.h" 78 77 79 78 80 // FIXME: is this really file scope? … … 169 171 Orxonox::getSingleton()->timefactor_ = factor; 170 172 171 for ( Iterator<ParticleInterface>it = ObjectList<ParticleInterface>::begin(); it; ++it)173 for (ObjectList<ParticleInterface>::iterator it = ObjectList<ParticleInterface>::begin(); it; ++it) 172 174 it->setSpeedFactor(it->getSpeedFactor() * change); 173 175 } … … 462 464 Core::tick((float)evt.timeSinceLastFrame); 463 465 // Call those objects that need the real time 464 for ( Iterator<TickableReal>it = ObjectList<TickableReal>::begin(); it; ++it)466 for (ObjectList<TickableReal>::iterator it = ObjectList<TickableReal>::begin(); it; ++it) 465 467 it->tick((float)evt.timeSinceLastFrame); 466 468 // Call the scene objects 467 for ( Iterator<Tickable>it = ObjectList<Tickable>::begin(); it; ++it)469 for (ObjectList<Tickable>::iterator it = ObjectList<Tickable>::begin(); it; ++it) 468 470 it->tick((float)evt.timeSinceLastFrame * this->timefactor_); 469 471 //AudioManager::tick(); -
code/branches/core3/src/orxonox/objects/NPC.cc
r1574 r1591 31 31 32 32 #include "core/CoreIncludes.h" 33 #include "core/Iterator.h" 33 34 34 35 namespace orxonox { … … 117 118 int numberOfNeighbour = 0; //number of observed neighbours 118 119 float distance = 0; // distance to the actual element 119 for( Iterator<WorldEntity>it = ObjectList<WorldEntity>::begin(); it; ++it) { //go through all elements120 for(ObjectList<WorldEntity>::iterator it = ObjectList<WorldEntity>::begin(); it; ++it) { //go through all elements 120 121 distance = getDistance(*it); //get distance between this and actual 121 122 if ((distance > 0) && (distance < SEPERATIONDISTANCE)) { //do only if actual is inside detectionradius … … 144 145 //float distance = 0; 145 146 //go through all elements 146 for( Iterator<NPC>it = ObjectList<NPC>::begin(); it; ++it) { //just working with 3 elements at the moment147 for(ObjectList<NPC>::iterator it = ObjectList<NPC>::begin(); it; ++it) { //just working with 3 elements at the moment 147 148 float distance = getDistance(*it); //get distance between this and actual 148 149 if ((distance > 0) && (distance < ALIGNMENTDISTANCE)) { //check if actual element is inside detectionradius … … 164 165 //float distance = 0; 165 166 //go through all elements 166 for( Iterator<NPC>it = ObjectList<NPC>::begin(); it; ++it) { //just working with 3 elements at the moment167 for(ObjectList<NPC>::iterator it = ObjectList<NPC>::begin(); it; ++it) { //just working with 3 elements at the moment 167 168 float distance = getDistance(*it); //get distance between this and actual 168 169 if ((distance > 0) && (distance < COHESIONDISTANCE)) { //check if actual element is inside detectionradius -
code/branches/core3/src/orxonox/objects/Projectile.cc
r1584 r1591 35 35 #include "core/Executor.h" 36 36 #include "core/ConfigValueIncludes.h" 37 #include "core/Iterator.h" 37 38 #include "tools/ParticleInterface.h" 38 39 … … 87 88 88 89 float radius; 89 for ( Iterator<Model>it = ObjectList<Model>::begin(); it; ++it)90 for (ObjectList<Model>::iterator it = ObjectList<Model>::begin(); it; ++it) 90 91 { 91 92 if ((*it) != this->owner_) -
code/branches/core3/src/orxonox/objects/SpaceShip.cc
r1586 r1591 41 41 #include "core/CoreIncludes.h" 42 42 #include "core/ConfigValueIncludes.h" 43 #include "core/Iterator.h" 43 44 #include "core/input/InputManager.h" 44 45 #include "core/XMLPort.h" … … 71 72 72 73 SpaceShip *SpaceShip::getLocalShip(){ 73 Iterator<SpaceShip>it;74 ObjectList<SpaceShip>::iterator it; 74 75 for(it = ObjectList<SpaceShip>::begin(); it; ++it){ 75 76 if( (it)->myShip_ ) -
code/branches/core3/src/orxonox/objects/SpaceShipAI.cc
r1566 r1591 72 72 SpaceShipAI::~SpaceShipAI() 73 73 { 74 for ( Iterator<SpaceShipAI>it = ObjectList<SpaceShipAI>::begin(); it; ++it)74 for (ObjectList<SpaceShipAI>::iterator it = ObjectList<SpaceShipAI>::begin(); it; ++it) 75 75 it->shipDied(this); 76 76 } … … 111 111 { 112 112 int i = 0; 113 for ( Iterator<SpaceShipAI>it = ObjectList<SpaceShipAI>::begin(); it; )113 for (ObjectList<SpaceShipAI>::iterator it = ObjectList<SpaceShipAI>::begin(); it; ) 114 114 { 115 115 (it++)->kill(); … … 259 259 this->forgetTarget(); 260 260 261 for ( Iterator<SpaceShip>it = ObjectList<SpaceShip>::begin(); it; ++it)261 for (ObjectList<SpaceShip>::iterator it = ObjectList<SpaceShip>::begin(); it; ++it) 262 262 { 263 263 if (it->getTeamNr() != this->getTeamNr())
Note: See TracChangeset
for help on using the changeset viewer.