Index: branches/atmospheric_engine/src/defs/class_id.h
===================================================================
--- branches/atmospheric_engine/src/defs/class_id.h	(revision 7376)
+++ branches/atmospheric_engine/src/defs/class_id.h	(revision 7379)
@@ -286,4 +286,8 @@
 
 
+  //CL_ATMOSPHERIC_ENGINE         =    0x        ,
+  //CL_SUN_EFFECTS                =    0x        ,
+  //CL_WEATHER_EFFECTS            =    0x        ,
+
   // Particles
   CL_PARTICLE_SYSTEM            =    0x00a02000,
Index: branches/atmospheric_engine/src/lib/graphics/Makefile.am
===================================================================
--- branches/atmospheric_engine/src/lib/graphics/Makefile.am	(revision 7376)
+++ branches/atmospheric_engine/src/lib/graphics/Makefile.am	(revision 7379)
@@ -17,4 +17,7 @@
 			   \
 			   effects/graphics_effect.cc \
+			   effects/atmospheric_engine.cc \
+			   effects/weather_effects.cc \
+			   effects/sun_effects.cc \
 			   effects/fog_effect.cc \
 			   effects/lense_flare.cc
@@ -35,4 +38,7 @@
 		 \
 		 effects/graphics_effect.h \
+		 effects/atmospheric_engine.h \
+		 effects/weather_effects.h \
+		 effects/sun_effects.h \
 		 effects/fog_effect.h \
 		 effects/lense_flare.h
Index: branches/atmospheric_engine/src/lib/graphics/effects/atmospheric_engine.cc
===================================================================
--- branches/atmospheric_engine/src/lib/graphics/effects/atmospheric_engine.cc	(revision 7379)
+++ branches/atmospheric_engine/src/lib/graphics/effects/atmospheric_engine.cc	(revision 7379)
@@ -0,0 +1,114 @@
+/*
+   orxonox - the future of 3D-vertical-scrollers
+
+   Copyright (C) 2004 orx
+
+   This program is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 2, or (at your option)
+   any later version.
+
+   ### File Specific:
+   main-programmer: Andreas Maechler, David Hasenfratz
+   co-programmer: ...
+*/
+
+#include "atmospheric_engine.h"
+
+#include "util/loading/resource_manager.h"
+
+
+#include "effects/fog_effect.h"
+
+
+
+#include "util/loading/load_param.h"
+#include "util/loading/factory.h"
+#include "class_list.h"
+
+
+using namespace std;
+
+
+
+/**
+ * @param root The XML-element to load the AtmosphericEngine from
+ */
+AtmosphericEngine::AtmosphericEngine()
+{
+  //this->setClassID(CL_ATMOSPHERIC_ENGINE, "AtmosphericEngine");
+  this->bActivated = false;
+}
+
+/**
+ *  The Pointer to this AtmosphericEngine
+*/
+AtmosphericEngine* AtmosphericEngine::singletonRef = NULL;
+
+
+/**
+ *  destroys a AtmosphericEngine
+ */
+AtmosphericEngine::~AtmosphericEngine()
+{
+  AtmosphericEngine::singletonRef = NULL;
+}
+
+
+/**
+ * @param root The XML-element to load the AtmosphericEngine from
+ */
+void AtmosphericEngine::loadParams(const TiXmlElement* root)
+{
+  LoadParamXML(root, "WeatherEffects", this, AtmosphericEngine, loadWeatherEffects);
+  LoadParamXML(root, "SunEffects", this, AtmosphericEngine, loadSunEffects);
+}
+
+/**
+ * @param root The XML-element to load WeatherEffects from
+ */
+void AtmosphericEngine::loadWeatherEffects(const TiXmlElement* root)
+{
+  LOAD_PARAM_START_CYCLE(root, element);
+  {
+    PRINTF(4)("element is: %s\n", element->Value());
+    Factory::fabricate(element);
+  }
+  LOAD_PARAM_END_CYCLE(element);
+}
+
+/**
+ * @param root The XML-element to load SunEffects from
+ */
+void AtmosphericEngine::loadSunEffects(const TiXmlElement* root)
+{
+  LOAD_PARAM_START_CYCLE(root, element);
+  {
+    PRINTF(4)("element is: %s\n", element->Value());
+    Factory::fabricate(element);
+  }
+  LOAD_PARAM_END_CYCLE(element);
+}
+
+
+/**
+ *  initializes the graphics effect
+ */
+bool AtmosphericEngine::init()
+{}
+
+
+
+/**
+ * draws the effect, if needed
+ */
+void AtmosphericEngine::draw() const
+{}
+
+
+
+/**
+ * ticks the effect if there is any time dependancy
+ */
+void AtmosphericEngine::tick(float dt)
+{}
Index: branches/atmospheric_engine/src/lib/graphics/effects/atmospheric_engine.h
===================================================================
--- branches/atmospheric_engine/src/lib/graphics/effects/atmospheric_engine.h	(revision 7379)
+++ branches/atmospheric_engine/src/lib/graphics/effects/atmospheric_engine.h	(revision 7379)
@@ -0,0 +1,48 @@
+/*!
+ * @file atmospheric_engine.h
+ *  
+ */
+
+#ifndef _ATMOSPHERIC_ENGINE_H
+#define _ATMOSPHERIC_ENGINE_H
+
+#include "base_object.h"
+
+
+class TiXmlElement;
+
+class AtmosphericEngine : public BaseObject
+{
+  public:
+    virtual ~AtmosphericEngine();
+
+    /** @returns a Pointer to the only object of this Class */
+    inline static AtmosphericEngine* getInstance() { if (!AtmosphericEngine::singletonRef) AtmosphericEngine::singletonRef = new AtmosphericEngine();  return AtmosphericEngine::singletonRef; };
+
+    virtual void loadParams(const TiXmlElement* root);
+
+    virtual bool init();
+
+    //virtual bool activate() = 0;
+    //virtual bool deactivate() = 0;
+
+    virtual void draw() const;
+    virtual void tick(float dt);
+
+    inline bool isActivated() const { return this->bActivated; }
+
+    void loadWeatherEffects(const TiXmlElement* root);
+    void loadSunEffects(const TiXmlElement* root);
+
+  private:
+
+    AtmosphericEngine();
+
+    static AtmosphericEngine*     singletonRef;       //!< Pointer to the only instance of this Class
+
+  protected:
+    bool              bActivated;
+};
+
+
+#endif /* _ATMOSPHERIC_ENGINE */
Index: branches/atmospheric_engine/src/lib/graphics/effects/fog_effect.cc
===================================================================
--- branches/atmospheric_engine/src/lib/graphics/effects/fog_effect.cc	(revision 7376)
+++ branches/atmospheric_engine/src/lib/graphics/effects/fog_effect.cc	(revision 7379)
@@ -1,4 +1,2 @@
-
-
 /*
    orxonox - the future of 3D-vertical-scrollers
@@ -12,8 +10,6 @@
 
 ### File Specific:
-   main-programmer: Patrick Boenzli
+   main-programmer: hdavid, amaechler
 */
-
-#define DEBUG_SPECIAL_MODULE DEBUG_MODULE_GRAPHICS
 
 #include "fog_effect.h"
@@ -31,17 +27,13 @@
 
 
-/**
- *  default constructor
- * @param root The XML-element to load the FogEffect from
- */
- FogEffect::FogEffect(const TiXmlElement* root)
+FogEffect::FogEffect(const TiXmlElement* root)
 {
-  this->setClassID(CL_FOG_EFFECT, "FogEffect");
-
+  //this->setClassID(CL_FOG_EFFECT, "FogEffect");
+/*
   this->fogMode = GL_LINEAR;
   this->fogDensity = 0.001f;
   this->fogStart = 10.0f;
   this->fogEnd = 1000.0f;
-
+*/
   if (root != NULL)
     this->loadParams(root);
@@ -51,7 +43,5 @@
 
 
-/**
- *  destroys a FogEffect
- */
+
 FogEffect::~FogEffect()
 {
@@ -60,36 +50,32 @@
 
 
-/**
- * @param root The XML-element to load the FogEffect from
- */
 void FogEffect::loadParams(const TiXmlElement* root)
 {
-  GraphicsEffect::loadParams(root);
+  WeatherEffects::loadParams(root);
 
+/*
+  LoadParam(root, "fog-mode", this, FogEffect, setFogMode);
 
-  LoadParam(root, "fog-mode", this, FogEffect, setFogMode)
-      .describe("sets the the fog mode {GL_LINEAR, GL_EXP, GL_EXP2}");
+  LoadParam(root, "fog-density", this, FogEffect, setFogDensity);
 
-  LoadParam(root, "fog-density", this, FogEffect, setFogDensity)
-      .describe("sets the the fog density of the exponentionl functions");
+  LoadParam(root, "fog-color", this, FogEffect, setFogColor);*/
 
-  LoadParam(root, "fog-color", this, FogEffect, setFogColor)
-      .describe("sets the fog color");
+  LoadParam(root, "test", this, FogEffect, setTest);
+
 
 }
 
+void FogEffect::setTest(int test)
+{
+  PRINTF(0)("\n\ntest: %i\n\n", test);
+}
 
-/**
- * initializes the fog effect
- */
 bool FogEffect::init()
 {}
 
 
-/**
- * activates the fog effect
- */
+
 bool FogEffect::activate()
-{
+{/*
   PRINTF(0)( "Enabling Fog Effect, mode: %i, density: %f, start: %f, end: %f, color %f, %f, %f\n", this->fogMode, this->fogDensity,
              this->fogStart, this->fogEnd, this->colorVector.x, this->colorVector.y, this->colorVector.z);
@@ -109,21 +95,16 @@
     //glFogi(GL_FOG_COORDINATE_SOURCE, GL_FOG_COORDINATE);
   }
-  glClearColor(0.5, 0.5, 0.5, 1.0);
+  glClearColor(0.5, 0.5, 0.5, 1.0);*/
 }
 
 
-/**
- * deactivates the fog effect
- */
+
 bool FogEffect::deactivate()
 {
-  glDisable(GL_FOG);
+  //glDisable(GL_FOG);
 }
 
 
-/**
- * converts a gl mode char to a GLint
- * @param mode the mode character
- */
+/*
 GLint FogEffect::stringToFogMode(const std::string& mode)
 {
@@ -137,3 +118,4 @@
     return -1;
 }
+*/
 
Index: branches/atmospheric_engine/src/lib/graphics/effects/fog_effect.h
===================================================================
--- branches/atmospheric_engine/src/lib/graphics/effects/fog_effect.h	(revision 7376)
+++ branches/atmospheric_engine/src/lib/graphics/effects/fog_effect.h	(revision 7379)
@@ -1,5 +1,4 @@
 /**
  * @file fog_effect.h
- *  atmospheric fog
  */
 
@@ -7,11 +6,7 @@
 #define _FOG_EFFECT
 
-#include "vector.h"
-#include "graphics_effect.h"
+#include "weather_effects.h"
 
-class TiXmlElement;
-
-//! A class that handles FogEffects. The FogEffectManager operates on this.
-class FogEffect : public GraphicsEffect
+class FogEffect : public WeatherEffects
 {
   public:
@@ -26,22 +21,25 @@
     virtual bool deactivate();
 
-    inline void setFogMode(const std::string& mode) { this->fogMode = this->stringToFogMode(mode); }
+
+    void setTest(int test);
+
+    /*inline void setFogMode(const std::string& mode) { this->fogMode = this->stringToFogMode(mode); }
     inline void setFogDensity(float density) { this->fogDensity = density; }
     inline void setFogRange(float start, float end) { this->fogStart = start; this->fogEnd = end; }
     inline void setFogColor(float r, float g, float b) { this->colorVector = Vector(r, g, b); }
+*/
+
+  private:
+    //GLint stringToFogMode(const std::string& mode);
 
 
   private:
-    GLint stringToFogMode(const std::string& mode);
-
-
-  private:
-    GLint                   fogMode;
+   /* GLint                   fogMode;
     GLfloat                 fogDensity;
     GLfloat                 fogStart;
     GLfloat                 fogEnd;
-    Vector                  colorVector;
+    Vector                  colorVector;*/
 };
 
 
-#endif /* _FOG_EFFECT */
+#endif  /* _FOG_EFFECT */
Index: branches/atmospheric_engine/src/lib/graphics/effects/sun_effects.cc
===================================================================
--- branches/atmospheric_engine/src/lib/graphics/effects/sun_effects.cc	(revision 7379)
+++ branches/atmospheric_engine/src/lib/graphics/effects/sun_effects.cc	(revision 7379)
@@ -0,0 +1,78 @@
+
+
+/*
+   orxonox - the future of 3D-vertical-scrollers
+
+   Copyright (C) 2004 orx
+
+   This program is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 2, or (at your option)
+   any later version.
+
+### File Specific:
+   main-programmer: Patrick Boenzli
+*/
+
+
+#include "sun_effects.h"
+
+#include "util/loading/load_param.h"
+
+
+using namespace std;
+
+
+
+/**
+ * @param root The XML-element to load the SunEffects from
+
+  @todo what to do, if no SunEffects-Slots are open anymore ???
+ */
+SunEffects::SunEffects(const TiXmlElement* root)
+{
+  //this->setClassID(CL_GRAPHICS_EFFECT, "SunEffects");
+  this->bActivated = false;
+}
+
+
+/**
+ *  destroys a SunEffects
+ */
+SunEffects::~SunEffects()
+{
+
+}
+
+
+/**
+ * @param root The XML-element to load the SunEffects from
+ */
+void SunEffects::loadParams(const TiXmlElement* root)
+{
+  BaseObject::loadParams(root);
+}
+
+
+/**
+ *  initializes the graphics effect
+ */
+bool SunEffects::init()
+{}
+
+
+
+/**
+ * draws the effect, if needed
+ */
+void SunEffects::draw() const
+{}
+
+
+
+/**
+ * ticks the effect if there is any time dependancy
+ */
+void SunEffects::tick(float dt)
+{}
+
Index: branches/atmospheric_engine/src/lib/graphics/effects/sun_effects.h
===================================================================
--- branches/atmospheric_engine/src/lib/graphics/effects/sun_effects.h	(revision 7379)
+++ branches/atmospheric_engine/src/lib/graphics/effects/sun_effects.h	(revision 7379)
@@ -0,0 +1,37 @@
+/*!
+ * @file sun_effects.h
+ *  
+ */
+
+#ifndef _SUN_EFFECTS_H
+#define _SUN_EFFECTS_H
+
+#include "base_object.h"
+
+
+class TiXmlElement;
+
+class SunEffects : public BaseObject
+{
+  public:
+    SunEffects(const TiXmlElement* root = NULL);
+    virtual ~SunEffects();
+
+    virtual void loadParams(const TiXmlElement* root);
+
+    virtual bool init();
+
+    virtual bool activate() = 0;
+    virtual bool deactivate() = 0;
+
+    virtual void draw() const;
+    virtual void tick(float dt);
+
+    inline bool isActivated() const { return this->bActivated; }
+
+  protected:
+    bool              bActivated;
+};
+
+
+#endif /* _SUN_EFFECTS */
Index: branches/atmospheric_engine/src/lib/graphics/effects/weather_effects.cc
===================================================================
--- branches/atmospheric_engine/src/lib/graphics/effects/weather_effects.cc	(revision 7379)
+++ branches/atmospheric_engine/src/lib/graphics/effects/weather_effects.cc	(revision 7379)
@@ -0,0 +1,74 @@
+
+
+/*
+   orxonox - the future of 3D-vertical-scrollers
+
+   Copyright (C) 2004 orx
+
+   This program is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 2, or (at your option)
+   any later version.
+
+### File Specific:
+   main-programmer: hdavid, amaechler
+*/
+
+
+#include "weather_effects.h"
+#include "util/loading/load_param.h"
+
+
+using namespace std;
+
+
+/**
+ * @param root The XML-element to load the WeatherEffects from
+ */
+WeatherEffects::WeatherEffects(const TiXmlElement* root)
+{
+  // this->setClassID(CL_WEATHER_EFFECTS, "WeatherEffects");
+  this->bActivated = false;
+}
+
+
+/**
+ *  destroys a WeatherEffects
+ */
+WeatherEffects::~WeatherEffects()
+{
+
+}
+
+
+/**
+ * @param root The XML-element to load the WeatherEffects from
+ */
+void WeatherEffects::loadParams(const TiXmlElement* root)
+{
+  BaseObject::loadParams(root);
+}
+
+
+/**
+ *  initializes the graphics effect
+ */
+bool WeatherEffects::init()
+{}
+
+
+
+/**
+ * draws the effect, if needed
+ */
+void WeatherEffects::draw() const
+{}
+
+
+
+/**
+ * ticks the effect if there is any time dependancy
+ */
+void WeatherEffects::tick(float dt)
+{}
+
Index: branches/atmospheric_engine/src/lib/graphics/effects/weather_effects.h
===================================================================
--- branches/atmospheric_engine/src/lib/graphics/effects/weather_effects.h	(revision 7379)
+++ branches/atmospheric_engine/src/lib/graphics/effects/weather_effects.h	(revision 7379)
@@ -0,0 +1,36 @@
+/*!
+ * @file weather_effects.h
+ *  
+ */
+
+#ifndef _WEATHER_EFFECTS_H
+#define _WEATHER_EFFECTS_H
+
+#include "base_object.h"
+
+
+class WeatherEffects : public BaseObject
+{
+  public:
+    WeatherEffects(const TiXmlElement* root = NULL);
+    virtual ~WeatherEffects();
+
+    virtual void loadParams(const TiXmlElement* root);
+
+    virtual bool init();
+
+    virtual bool activate() = 0;
+    virtual bool deactivate() = 0;
+
+    virtual void draw() const;
+    virtual void tick(float dt);
+
+    inline bool isActivated() const { return this->bActivated; }
+
+
+  protected:
+    bool              bActivated;
+};
+
+
+#endif /* _WEATHER_EFFECTS */
Index: branches/atmospheric_engine/src/story_entities/game_world_data.cc
===================================================================
--- branches/atmospheric_engine/src/story_entities/game_world_data.cc	(revision 7376)
+++ branches/atmospheric_engine/src/story_entities/game_world_data.cc	(revision 7379)
@@ -45,4 +45,5 @@
 
 #include "graphics_engine.h"
+#include "effects/atmospheric_engine.h"
 #include "event_handler.h"
 #include "sound_engine.h"
@@ -322,4 +323,5 @@
   LoadParamXML(root, "LightManager", LightManager::getInstance(), LightManager, loadParams);
   LoadParamXML(root, "GraphicsEngine", GraphicsEngine::getInstance(), GraphicsEngine, loadParams);
+  LoadParamXML(root, "AtmosphericEngine", AtmosphericEngine::getInstance(), AtmosphericEngine, loadParams);
 
   LoadParam(root, "Music", this, GameWorldData, setSoundTrack);
