Index: code/branches/resource/src/core/Core.cc
===================================================================
--- code/branches/resource/src/core/Core.cc	(revision 3354)
+++ code/branches/resource/src/core/Core.cc	(revision 3355)
@@ -364,5 +364,4 @@
         guiManager_ = new GUIManager(renderWindow);
 
-        GameMode::setShowsGraphics(true);
         bGraphicsLoaded_ = true;
     }
@@ -378,5 +377,4 @@
 
         bGraphicsLoaded_ = false;
-        GameMode::setShowsGraphics(false);
     }
 
Index: code/branches/resource/src/core/CorePrereqs.h
===================================================================
--- code/branches/resource/src/core/CorePrereqs.h	(revision 3354)
+++ code/branches/resource/src/core/CorePrereqs.h	(revision 3355)
@@ -170,6 +170,6 @@
     // game states
     class Game;
-    struct GameStateConstrParams;
     class GameState;
+    struct GameStateInfo;
     struct GameStateTreeNode;
 
Index: code/branches/resource/src/core/Game.cc
===================================================================
--- code/branches/resource/src/core/Game.cc	(revision 3354)
+++ code/branches/resource/src/core/Game.cc	(revision 3355)
@@ -48,4 +48,5 @@
 #include "CoreIncludes.h"
 #include "ConfigValueIncludes.h"
+#include "GameMode.h"
 #include "GameState.h"
 
@@ -59,5 +60,5 @@
     SetConsoleCommandShortcutExternAlias(stop_game, "exit");
 
-    std::map<std::string, Game::GameStateInfo> Game::gameStateDeclarations_s;
+    std::map<std::string, GameStateInfo> Game::gameStateDeclarations_s;
     Game* Game::singletonRef_s = 0;
 
@@ -143,6 +144,5 @@
             // Only create the states appropriate for the game mode
             //if (GameMode::showsGraphics || !it->second.bGraphicsMode)
-            GameStateConstrParams params = { it->second.stateName, it->second.bIgnoreTickTime };
-            gameStates_[getLowercase(it->second.stateName)] = GameStateFactory::fabricate(it->second.className, params);
+            gameStates_[getLowercase(it->second.stateName)] = GameStateFactory::fabricate(it->second);
         }
 
@@ -292,8 +292,8 @@
                 // Add tick time for most of the states
                 uint64_t timeBeforeTick;
-                if ((*it)->ignoreTickTime())
+                if ((*it)->getInfo().bIgnoreTickTime)
                     timeBeforeTick = this->gameClock_->getRealMicroseconds();
                 (*it)->update(*this->gameClock_);
-                if ((*it)->ignoreTickTime())
+                if ((*it)->getInfo().bIgnoreTickTime)
                     this->subtractTickTime(static_cast<int32_t>(this->gameClock_->getRealMicroseconds() - timeBeforeTick));
             }
@@ -517,7 +517,28 @@
     /*** Internal ***/
 
+    void Game::loadGraphics()
+    {
+        if (!GameMode::bShowsGraphics_s)
+        {
+            core_->loadGraphics();
+            GameMode::bShowsGraphics_s = true;
+        }
+    }
+
+    void Game::unloadGraphics()
+    {
+        if (GameMode::bShowsGraphics_s)
+        {
+            core_->unloadGraphics();
+            GameMode::bShowsGraphics_s = false;
+        }
+    }
+
     void Game::loadState(GameState* state)
     {
         this->bChangingState_ = true;
+        // If state requires graphics, load it
+        if (state->getInfo().bGraphicsMode)
+            this->loadGraphics();
         state->activate();
         if (!this->activeStates_.empty())
@@ -538,4 +559,10 @@
         {
             state->deactivate();
+            // Check if graphis is still required
+            bool graphicsRequired = false;
+            for (unsigned i = 0; i < activeStates_.size(); ++i)
+                graphicsRequired |= activeStates_[i]->getInfo().bGraphicsMode;
+            if (!graphicsRequired)
+                this->unloadGraphics();
         }
         catch (const std::exception& ex)
@@ -549,9 +576,9 @@
     std::map<std::string, Game::GameStateFactory*> Game::GameStateFactory::factories_s;
 
-    /*static*/ GameState* Game::GameStateFactory::fabricate(const std::string& className, const GameStateConstrParams& params)
-    {
-        std::map<std::string, GameStateFactory*>::const_iterator it = factories_s.find(className);
+    /*static*/ GameState* Game::GameStateFactory::fabricate(const GameStateInfo& info)
+    {
+        std::map<std::string, GameStateFactory*>::const_iterator it = factories_s.find(info.className);
         assert(it != factories_s.end());
-        return it->second->fabricate(params);
+        return it->second->fabricateInternal(info);
     }
 
Index: code/branches/resource/src/core/Game.h
===================================================================
--- code/branches/resource/src/core/Game.h	(revision 3354)
+++ code/branches/resource/src/core/Game.h	(revision 3355)
@@ -61,4 +61,13 @@
     class GameConfiguration;
 
+    //! Helper object required before GameStates are being constructed
+    struct GameStateInfo
+    {
+        std::string stateName;
+        std::string className;
+        bool bIgnoreTickTime;
+        bool bGraphicsMode;
+    };
+
     /**
     @brief
@@ -97,5 +106,5 @@
         public:
             virtual ~GameStateFactory() { }
-            static GameState* fabricate(const std::string& className, const GameStateConstrParams& params);
+            static GameState* fabricate(const GameStateInfo& info);
             template <class T>
             static void createFactory(const std::string& className)
@@ -103,5 +112,5 @@
             static void destroyFactories();
         private:
-            virtual GameState* fabricate(const GameStateConstrParams& params) = 0;
+            virtual GameState* fabricateInternal(const GameStateInfo& info) = 0;
             static std::map<std::string, GameStateFactory*> factories_s;
         };
@@ -110,14 +119,6 @@
         {
         public:
-            GameState* fabricate(const GameStateConstrParams& params)
-                { return new T(params); }
-        };
-
-        struct GameStateInfo
-        {
-            std::string stateName;
-            std::string className;
-            bool bIgnoreTickTime;
-            bool bGraphicsMode;
+            GameState* fabricateInternal(const GameStateInfo& info)
+                { return new T(info); }
         };
 
@@ -129,4 +130,7 @@
 
         Game(Game&); // don't mess with singletons
+
+        void loadGraphics();
+        void unloadGraphics();
 
         void loadState(GameState* state);
Index: code/branches/resource/src/core/GameMode.h
===================================================================
--- code/branches/resource/src/core/GameMode.h	(revision 3354)
+++ code/branches/resource/src/core/GameMode.h	(revision 3355)
@@ -41,5 +41,5 @@
     class _CoreExport GameMode
     {
-        friend class Core;
+        friend class Game;
 
         public:
@@ -59,6 +59,8 @@
             ~GameMode();
 
-            static void setShowsGraphics(bool val) { bShowsGraphics_s = val; updateIsMaster(); }
-            static void updateIsMaster  ()         { bIsMaster_s      = (bHasServer_s || bIsStandalone_s); }
+            static void updateIsMaster()
+            {
+                bIsMaster_s = (bHasServer_s || bIsStandalone_s);
+            }
 
             static bool bShowsGraphics_s;                   //!< global variable that tells whether to show graphics
Index: code/branches/resource/src/core/GameState.cc
===================================================================
--- code/branches/resource/src/core/GameState.cc	(revision 3354)
+++ code/branches/resource/src/core/GameState.cc	(revision 3355)
@@ -38,4 +38,5 @@
 #include "util/Exception.h"
 #include "util/OrxAssert.h"
+#include "Game.h"
 
 namespace orxonox
@@ -45,7 +46,6 @@
         Constructor only initialises variables and sets the name permanently.
     */
-    GameState::GameState(const GameStateConstrParams& params)
-        : name_(params.name)
-        , bIgnoreTickTime_(params.bIgnoreTickTime)
+    GameState::GameState(const GameStateInfo& info)
+        : info_(info)
         , parent_(0)
     {
@@ -65,4 +65,9 @@
     {
         OrxAssert(this->activity_.active == false, "Deleting an active GameState is a very bad idea..");
+    }
+
+    const std::string& GameState::getName() const
+    {
+        return info_.stateName;
     }
 
@@ -107,5 +112,5 @@
         else
         {
-            ThrowException(GameState, "Game state '" + name_ + "' doesn't have a child named '"
+            ThrowException(GameState, "Game state '" + this->getName() + "' doesn't have a child named '"
                 + state->getName() + "'.");
         }
Index: code/branches/resource/src/core/GameState.h
===================================================================
--- code/branches/resource/src/core/GameState.h	(revision 3354)
+++ code/branches/resource/src/core/GameState.h	(revision 3355)
@@ -45,14 +45,4 @@
     /**
     @brief
-        Helper class to group construction parameters for better genericity.
-    */
-    struct GameStateConstrParams
-    {
-        std::string name;
-        bool bIgnoreTickTime;
-    };
-
-    /**
-    @brief
         An implementation of a tree to manage game states.
         This leads to a certain hierarchy that is created at runtime.
@@ -87,12 +77,11 @@
 
     public:
-        GameState(const GameStateConstrParams& params);
+        GameState(const GameStateInfo& info);
         virtual ~GameState();
 
-        const std::string& getName() const { return name_; }
-        State getActivity()          const { return this->activity_; }
-        GameState* getParent()       const { return this->parent_; }
-
-        bool ignoreTickTime()        const { return this->bIgnoreTickTime_; }
+        const std::string& getName()   const;
+        State getActivity()            const { return activity_; }
+        GameState* getParent()         const { return parent_; }
+        const GameStateInfo& getInfo() const { return info_; }
 
         void addChild(GameState* state);
@@ -111,7 +100,6 @@
         void updateInternal(const Clock& time);
 
-        const std::string                        name_;
+        const GameStateInfo&                     info_;
         State                                    activity_;
-        const bool                               bIgnoreTickTime_;
         GameState*                               parent_;
         std::map<std::string, GameState*>        children_;
