[Orxonox-commit 625] r3157 - in branches/pch/src/orxonox: gamestates objects objects/pickup sound

rgrieder at orxonox.net rgrieder at orxonox.net
Sat Jun 13 17:03:51 CEST 2009


Author: rgrieder
Date: 2009-06-13 17:03:51 +0200 (Sat, 13 Jun 2009)
New Revision: 3157

Modified:
   branches/pch/src/orxonox/gamestates/GSDedicated.cc
   branches/pch/src/orxonox/objects/RadarViewable.cc
   branches/pch/src/orxonox/objects/RadarViewable.h
   branches/pch/src/orxonox/objects/pickup/PickupInventory.cc
   branches/pch/src/orxonox/objects/pickup/PickupSpawner.cc
   branches/pch/src/orxonox/sound/CMakeLists.txt
   branches/pch/src/orxonox/sound/SoundBase.cc
   branches/pch/src/orxonox/sound/SoundBase.h
Log:
Small changes and cleaned out RadarViewable which saves me probably more than a minute when recompiling...

Modified: branches/pch/src/orxonox/gamestates/GSDedicated.cc
===================================================================
--- branches/pch/src/orxonox/gamestates/GSDedicated.cc	2009-06-13 14:57:55 UTC (rev 3156)
+++ branches/pch/src/orxonox/gamestates/GSDedicated.cc	2009-06-13 15:03:51 UTC (rev 3157)
@@ -32,7 +32,7 @@
 #include "core/CommandLine.h"
 #include "core/Game.h"
 #include "core/GameMode.h"
-#include "core/Iterator.h"
+#include "core/ObjectList.h"
 #include "network/Server.h"
 #include "objects/Tickable.h"
 #include "util/Sleep.h"

Modified: branches/pch/src/orxonox/objects/RadarViewable.cc
===================================================================
--- branches/pch/src/orxonox/objects/RadarViewable.cc	2009-06-13 14:57:55 UTC (rev 3156)
+++ branches/pch/src/orxonox/objects/RadarViewable.cc	2009-06-13 15:03:51 UTC (rev 3157)
@@ -29,15 +29,17 @@
 #include "RadarViewable.h"
 
 #include <OgreSceneManager.h>
+#include <OgreSceneNode.h>
+#include <OgreEntity.h>
+#include <OgreManualObject.h>
+
 #include "util/Debug.h"
-#include "util/Exception.h"
+#include "util/String.h"
 #include "core/CoreIncludes.h"
+#include "orxonox/tools/DynamicLines.h"
 #include "objects/worldentities/WorldEntity.h"
 #include "objects/Radar.h"
-#include "util/String.h"
-#include <OgreManualObject.h>
 #include "overlays/map/Map.h"
-#include "orxonox/tools/DynamicLines.h"
 
 namespace orxonox
 {

Modified: branches/pch/src/orxonox/objects/RadarViewable.h
===================================================================
--- branches/pch/src/orxonox/objects/RadarViewable.h	2009-06-13 14:57:55 UTC (rev 3156)
+++ branches/pch/src/orxonox/objects/RadarViewable.h	2009-06-13 15:03:51 UTC (rev 3157)
@@ -30,18 +30,14 @@
 #define _RadarViewable_H__
 
 #include "OrxonoxPrereqs.h"
+
 #include <string>
 #include <cassert>
+
 #include "util/Math.h"
 #include "util/Debug.h"
 #include "core/OrxonoxClass.h"
 
-#include <string>
-#include <OgreSceneNode.h>
-#include <OgreEntity.h>
-#include <OgreManualObject.h>
-#include "orxonox/tools/DynamicLines.h"
-
 namespace orxonox
 {
     /**
@@ -109,7 +105,7 @@
         void addMapEntity();
         void updateMapPosition();
         bool isHumanShip_;
-        inline std::string getUniqueId()
+        inline const std::string& getUniqueId()
         {
             return this->uniqueId_;
         }

Modified: branches/pch/src/orxonox/objects/pickup/PickupInventory.cc
===================================================================
--- branches/pch/src/orxonox/objects/pickup/PickupInventory.cc	2009-06-13 14:57:55 UTC (rev 3156)
+++ branches/pch/src/orxonox/objects/pickup/PickupInventory.cc	2009-06-13 15:03:51 UTC (rev 3157)
@@ -85,14 +85,14 @@
     void PickupInventory::toggleInventory()
     {
         if(PickupInventory::getSingleton()->isVisible()) {
-            GUIManager::getInstancePtr()->executeCode("hideGUI(\"PickupInventory\")");
-            GUIManager::getInstancePtr()->executeCode("hideCursor()");
+            GUIManager::getInstance().executeCode("hideGUI(\"PickupInventory\")");
+            GUIManager::getInstance().executeCode("hideCursor()");
             InputManager::getInstance().requestLeaveState("guiMouseOnly");
         }
         else
         {
-            GUIManager::getInstancePtr()->showGUI("PickupInventory");
-            GUIManager::getInstancePtr()->executeCode("showCursor()");
+            GUIManager::getInstance().showGUI("PickupInventory");
+            GUIManager::getInstance().executeCode("showCursor()");
             InputManager::getInstance().requestEnterState("guiMouseOnly");
         }
         PickupInventory::getSingleton()->setVisible(!PickupInventory::getSingleton()->isVisible());

Modified: branches/pch/src/orxonox/objects/pickup/PickupSpawner.cc
===================================================================
--- branches/pch/src/orxonox/objects/pickup/PickupSpawner.cc	2009-06-13 14:57:55 UTC (rev 3156)
+++ branches/pch/src/orxonox/objects/pickup/PickupSpawner.cc	2009-06-13 15:03:51 UTC (rev 3157)
@@ -94,8 +94,8 @@
 
         //  & load the GUI itself too, along with some empty windows
         //   = even less delays
-        GUIManager::getInstancePtr()->showGUI("PickupInventory");
-        GUIManager::getInstancePtr()->executeCode("hideGUI(\"PickupInventory\")");
+        GUIManager::getInstance().showGUI("PickupInventory");
+        GUIManager::getInstance().executeCode("hideGUI(\"PickupInventory\")");
         PickupInventory::getSingleton();
     }
     /**

Modified: branches/pch/src/orxonox/sound/CMakeLists.txt
===================================================================
--- branches/pch/src/orxonox/sound/CMakeLists.txt	2009-06-13 14:57:55 UTC (rev 3156)
+++ branches/pch/src/orxonox/sound/CMakeLists.txt	2009-06-13 15:03:51 UTC (rev 3157)
@@ -1,8 +1,4 @@
 ADD_SOURCE_FILES(ORXONOX_SRC_FILES
-    SoundManager.h
-    SoundBase.h
-    SoundMainMenu.h
-
     SoundManager.cc
     SoundBase.cc
     SoundMainMenu.cc

Modified: branches/pch/src/orxonox/sound/SoundBase.cc
===================================================================
--- branches/pch/src/orxonox/sound/SoundBase.cc	2009-06-13 14:57:55 UTC (rev 3156)
+++ branches/pch/src/orxonox/sound/SoundBase.cc	2009-06-13 15:03:51 UTC (rev 3157)
@@ -28,6 +28,7 @@
 
 #include "SoundBase.h"
 
+#include <string>
 #include <vector>
 #include <AL/alut.h>
 #include <vorbis/vorbisfile.h>
@@ -180,7 +181,7 @@
         return state;
     }
 
-    ALuint SoundBase::loadOggFile(std::string filename)
+    ALuint SoundBase::loadOggFile(const std::string& filename)
     {
         char inbuffer[4096];
         std::vector<char> outbuffer;

Modified: branches/pch/src/orxonox/sound/SoundBase.h
===================================================================
--- branches/pch/src/orxonox/sound/SoundBase.h	2009-06-13 14:57:55 UTC (rev 3156)
+++ branches/pch/src/orxonox/sound/SoundBase.h	2009-06-13 15:03:51 UTC (rev 3157)
@@ -56,7 +56,7 @@
         bool loadFile(std::string filename);
 
     private:
-        ALuint loadOggFile(std::string filename);
+        ALuint loadOggFile(const std::string& filename);
         ALuint source_;
         ALuint buffer_;
         WorldEntity* entity_;




More information about the Orxonox-commit mailing list