[Orxonox-commit 7278] r11893 - in code/branches/RacingBots_FS18: data/levels src/modules/gametypes

andera at orxonox.net andera at orxonox.net
Thu Apr 19 16:11:27 CEST 2018


Author: andera
Date: 2018-04-19 16:11:27 +0200 (Thu, 19 Apr 2018)
New Revision: 11893

Modified:
   code/branches/RacingBots_FS18/data/levels/newnewnewspacerace.oxw
   code/branches/RacingBots_FS18/src/modules/gametypes/SpaceRaceController.cc
Log:
new botpointer.mesh added. Bug at the end of the game found not fixed yet

Modified: code/branches/RacingBots_FS18/data/levels/newnewnewspacerace.oxw
===================================================================
--- code/branches/RacingBots_FS18/data/levels/newnewnewspacerace.oxw	2018-04-19 14:07:18 UTC (rev 11892)
+++ code/branches/RacingBots_FS18/data/levels/newnewnewspacerace.oxw	2018-04-19 14:11:27 UTC (rev 11893)
@@ -495,31 +495,31 @@
 </SpaceRaceManager>
    <Arrow>
       <attached>
-       <Model scale="5" mesh="tutorialpointer3.mesh"/>
+       <Model scale="5" mesh="botpointer4.mesh"/>
       </attached>
       <controller>
         <ArrowController accuracy = 2000>
           <gpspoints>
-            <Model mesh="cube.mesh" scale=1.5 position="1000,30,0"/>
-            <Model mesh="cube.mesh" scale=1.5 position="3000,200,100"/>
-            <Model mesh="cube.mesh" scale=1.5 position="5000,100,500"/>
-            <Model mesh="cube.mesh" scale=1.5 position="8000,-150,150"/>
-            <Model mesh="cube.mesh" scale=1.5 position="10000,-200,200"/>
-            <Model mesh="cube.mesh" scale=1.5 position="13000,200,400"/>
-            <Model mesh="cube.mesh" scale=1.5 position="15000,0,0"/>
-            <Model mesh="cube.mesh" scale=1.5 position="18000,150,-150"/>
-            <Model mesh="cube.mesh" scale=1.5 position="21000,200,-120"/>
-            <Model mesh="cube.mesh" scale=1.5 position="24000,-150,-80"/>
-            <Model mesh="cube.mesh" scale=1.5 position="27000,-200,0"/>
-            <Model mesh="cube.mesh" scale=1.5 position="30000,-300,900"/>
-            <Model mesh="cube.mesh" scale=1.5 position="33000,600,60"/>
-            <Model mesh="cube.mesh" scale=1.5 position="35000,120,20"/>
-            <Model mesh="cube.mesh" scale=1.5 position="38000,-200,0"/>
-            <Model mesh="cube.mesh" scale=1.5 position="41000,30,-50"/>
-            <Model mesh="cube.mesh" scale=1.5 position="44000,90,0"/>
-            <Model mesh="cube.mesh" scale=1.5 position="47000,120,30"/>
-            <Model mesh="cube.mesh" scale=1.5 position="50000,0,100"/>
-            <Model mesh="cube.mesh" scale=1.5 position="53000,0,0"/>
+            <Model mesh="cube.mesh" scale=2 position="1000,30,0"/>
+            <Model mesh="cube.mesh" scale=2 position="3000,200,100"/>
+            <Model mesh="cube.mesh" scale=2 position="5000,100,500"/>
+            <Model mesh="cube.mesh" scale=2 position="8000,-150,150"/>
+            <Model mesh="cube.mesh" scale=2 position="10000,-200,200"/>
+            <Model mesh="cube.mesh" scale=2 position="13000,200,400"/>
+            <Model mesh="cube.mesh" scale=2 position="15000,0,0"/>
+            <Model mesh="cube.mesh" scale=2 position="18000,150,-150"/>
+            <Model mesh="cube.mesh" scale=2 position="21000,200,-120"/>
+            <Model mesh="cube.mesh" scale=2 position="24000,-150,-80"/>
+            <Model mesh="cube.mesh" scale=2 position="27000,-200,0"/>
+            <Model mesh="cube.mesh" scale=2 position="30000,-300,900"/>
+            <Model mesh="cube.mesh" scale=2 position="33000,600,60"/>
+            <Model mesh="cube.mesh" scale=2 position="35000,120,20"/>
+            <Model mesh="cube.mesh" scale=2 position="38000,-200,0"/>
+            <Model mesh="cube.mesh" scale=2 position="41000,30,-50"/>
+            <Model mesh="cube.mesh" scale=2 position="44000,90,0"/>
+            <Model mesh="cube.mesh" scale=2 position="47000,120,30"/>
+            <Model mesh="cube.mesh" scale=2 position="50000,0,100"/>
+            <Model mesh="cube.mesh" scale=2 position="53000,0,0"/>
 
             
 

Modified: code/branches/RacingBots_FS18/src/modules/gametypes/SpaceRaceController.cc
===================================================================
--- code/branches/RacingBots_FS18/src/modules/gametypes/SpaceRaceController.cc	2018-04-19 14:07:18 UTC (rev 11892)
+++ code/branches/RacingBots_FS18/src/modules/gametypes/SpaceRaceController.cc	2018-04-19 14:11:27 UTC (rev 11893)
@@ -19,7 +19,7 @@
  *   along with this program; if not, write to the Free Software
  *   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
  *
- *  Created on: Oct 8, 2012
+ *  Created on: Oct 8, 2012findCheck
  *      Author: purgham
  */
 
@@ -126,8 +126,10 @@
                     //orxout() << currentCheckpoint->getCheckpointIndex()<<endl;
                     continue;
                 }
-                if (findCheckpoint(checkpointIndex) == nullptr)
+                if (findCheckpoint(checkpointIndex) == nullptr){
+                    orxout()<<"nullpointer @ SpaceraceController line 130"<< endl;
                     orxout(internal_warning) << "Problematic Point: " << checkpointIndex << endl;
+                }
                 else
                     numberOfWays += rekSimulationCheckpointsReached(findCheckpoint(checkpointIndex), zaehler);
             }
@@ -222,9 +224,11 @@
 
     RaceCheckPoint* SpaceRaceController::findCheckpoint(int index) const
     {
-        for (RaceCheckPoint* checkpoint : this->checkpoints_)
+        for (RaceCheckPoint* checkpoint : this->checkpoints_){
             if (checkpoint->getCheckpointIndex() == index)
                 return checkpoint;
+        }
+
         return nullptr;
     }
 
@@ -327,6 +331,7 @@
         lastPositionSpaceship = this->getControllableEntity()->getPosition();
        
         this->boostControl();
+        if (nextRaceCheckpoint_ == nullptr) orxout() << "nextRaceCheckpoint_ equals to nullpointer look @line 334 SpaceRaceController.cc" << endl;
         this->moveToPosition(nextRaceCheckpoint_->getPosition());
         this->boostControl();
     }



More information about the Orxonox-commit mailing list