Index: branches/christmas_branche/src/lib/event/event_handler.cc
===================================================================
--- branches/christmas_branche/src/lib/event/event_handler.cc	(revision 6167)
+++ branches/christmas_branche/src/lib/event/event_handler.cc	(revision 6169)
@@ -259,8 +259,8 @@
 {
   this->eventsGrabbed = grabEvents;
-//   if(!grabEvents)
-//     SDL_WM_GrabInput(SDL_GRAB_OFF);
-//   else
-//     SDL_WM_GrabInput(SDL_GRAB_ON);
+  if(!grabEvents)
+    SDL_WM_GrabInput(SDL_GRAB_OFF);
+  else
+    SDL_WM_GrabInput(SDL_GRAB_ON);
 }
 
Index: branches/christmas_branche/src/lib/graphics/importer/md2Model.cc
===================================================================
--- branches/christmas_branche/src/lib/graphics/importer/md2Model.cc	(revision 6167)
+++ branches/christmas_branche/src/lib/graphics/importer/md2Model.cc	(revision 6169)
@@ -156,4 +156,11 @@
 {
   this->animationState.localTime += time;
+
+  if( likely(this->animationState.localTime > 0.0))
+    this->animate();
+
+  static sVec3D verticesList[MD2_MAX_VERTICES]; /* performance: created only once in a lifetime */
+  this->processLighting();
+  this->interpolate(verticesList);
 }
 
@@ -164,14 +171,11 @@
  * FIXME
  */
-void MD2Model::draw()
-{
-  if( likely(this->animationState.localTime > 0.0))
-    this->animate();
-
-  glPushMatrix();
+void MD2Model::draw() const
+{
+//   glPushMatrix();
 
   this->renderFrame();
 
-  glPopMatrix();
+//   glPopMatrix();
 }
 
@@ -180,5 +184,5 @@
   \brief this is an internal function to render this special frame selected by animate()
 */
-void MD2Model::renderFrame()
+void MD2Model::renderFrame() const
 {
   static sVec3D verticesList[MD2_MAX_VERTICES]; /* performance: created only once in a lifetime */
@@ -191,6 +195,5 @@
   glCullFace(GL_BACK);
 
-  this->processLighting();
-  this->interpolate(verticesList);
+
   this->data->material->select();
 
@@ -406,4 +409,5 @@
         }
     }
+    PRINTF(4)("Finished loading the md2 file\n");
 
   delete [] buffer;
Index: branches/christmas_branche/src/lib/graphics/importer/md2Model.h
===================================================================
--- branches/christmas_branche/src/lib/graphics/importer/md2Model.h	(revision 6167)
+++ branches/christmas_branche/src/lib/graphics/importer/md2Model.h	(revision 6169)
@@ -143,5 +143,5 @@
   virtual ~MD2Model();
 
-  void draw();
+  virtual void draw() const;
 
   void setAnim(int type);
@@ -160,5 +160,5 @@
   void processLighting();
   void interpolate(sVec3D* verticesList);
-  void renderFrame();
+  void renderFrame() const;
 
 
Index: branches/christmas_branche/src/util/loading/resource_manager.cc
===================================================================
--- branches/christmas_branche/src/util/loading/resource_manager.cc	(revision 6167)
+++ branches/christmas_branche/src/util/loading/resource_manager.cc	(revision 6169)
@@ -389,5 +389,7 @@
               else
                 tmpResource->secFileName = NULL;
-              tmpResource->pointer = new MD2Data(fullName, tmpResource->secFileName);
+                tmpResource->pointer = new MD2Data(fullName, tmpResource->secFileName);
+//               tmpResource->pointer = new MD2Model(fullName, tmpResource->secFileName);
+
             }
               break;
Index: branches/christmas_branche/src/world_entities/space_ships/space_ship.cc
===================================================================
--- branches/christmas_branche/src/world_entities/space_ships/space_ship.cc	(revision 6167)
+++ branches/christmas_branche/src/world_entities/space_ships/space_ship.cc	(revision 6169)
@@ -267,11 +267,11 @@
   velocity += ((this->getAbsDirX())*travelSpeed-velocity)*airViscosity;
   velocity = (velocity.getNormalized())*travelSpeed;
-  
+
   //orient the spaceship in direction of the mouse
    rotQuat = Quaternion::quatSlerp( this->getAbsDir(),mouseDir,fabsf(time)*3);
-   if (this->getAbsDir().distance(rotQuat) > 0.001)  
+   if (this->getAbsDir().distance(rotQuat) > 0.001)
     this->setAbsDir( rotQuat);
    //this->setAbsDirSoft(mouseDir,5);
-   
+
   // this is the air friction (necessary for a smooth control)
   if(velocity.len() != 0) velocity -= velocity*0.01;
@@ -312,5 +312,5 @@
      //this->shiftCoor(this->getAbsDirX());
       accel += (this->getAbsDirX())*2;
-      
+
       /* Heli-Steuerung
          accel += (this->getAbsDirX()*2;
Index: branches/christmas_branche/src/world_entities/world_entity.cc
===================================================================
--- branches/christmas_branche/src/world_entities/world_entity.cc	(revision 6167)
+++ branches/christmas_branche/src/world_entities/world_entity.cc	(revision 6169)
@@ -21,4 +21,5 @@
 
 #include "model.h"
+#include "md2Model.h"
 #include "resource_manager.h"
 #include "load_param.h"
@@ -56,4 +57,5 @@
   this->objectListNumber = OM_INIT;
   this->objectListIterator = NULL;
+  this->supportsLOD = false;
 
   this->toList(OM_NULL);
@@ -117,4 +119,5 @@
               this->loadModel(lodFile, scaling, i);
           }
+          this->supportsLOD = true;
         return;
       }
@@ -134,5 +137,9 @@
       {
         PRINTF(4)("fetching MD2 file: %s\n", fileName);
-        this->setModel((Model*)ResourceManager::getInstance()->load(fileName, MD2, RP_CAMPAIGN), 0);
+//         MD2Model* m = (MD2Model*)ResourceManager::getInstance()->load(fileName, MD2, RP_CAMPAIGN);
+        MD2Model* m = new MD2Model(fileName, "/home/boenzlip/orxonox/data/maps/santa_claus.pcx");
+        m->debug();
+        //this->setModel((Model*)ResourceManager::getInstance()->load(fileName, MD2, RP_CAMPAIGN), 0);
+        this->setModel((Model*)m, 0);
       }
   }
@@ -154,10 +161,12 @@
   {
     Resource* resource = ResourceManager::getInstance()->locateResourceByPointer(this->models[modelNumber]);
-    if (resource != NULL)
-      ResourceManager::getInstance()->unload(resource, RP_LEVEL);
-    else
-      delete this->models[modelNumber];
-  }
+//     if (resource != NULL)
+    ResourceManager::getInstance()->unload(resource, RP_LEVEL);
+  }
+  else
+    delete this->models[modelNumber];
+
   this->models[modelNumber] = model;
+
 
 //   if (this->model != NULL)
@@ -281,35 +290,59 @@
 }
 
+
+/**
+ *  this functions draws the model automaticaly in multiple LOD
+ */
 void WorldEntity::drawLODsafe() const
 {
-  if (!this->models.empty())
-  {
-    glMatrixMode(GL_MODELVIEW);
-    glPushMatrix();
-
-    /* translate */
-    glTranslatef (this->getAbsCoor ().x,
-                  this->getAbsCoor ().y,
-                  this->getAbsCoor ().z);
-    Vector tmpRot = this->getAbsDir().getSpacialAxis();
-    glRotatef (this->getAbsDir().getSpacialAxisAngle(), tmpRot.x, tmpRot.y, tmpRot.z );
+  if (!unlikely(this->models.empty()))
+  {
+    if( likely(this->supportsLOD))
+    {
+      glMatrixMode(GL_MODELVIEW);
+      glPushMatrix();
+
+      /* translate */
+      glTranslatef (this->getAbsCoor ().x,
+                    this->getAbsCoor ().y,
+                    this->getAbsCoor ().z);
+      Vector tmpRot = this->getAbsDir().getSpacialAxis();
+      glRotatef (this->getAbsDir().getSpacialAxisAngle(), tmpRot.x, tmpRot.y, tmpRot.z );
 
 
     // This Draws the LOD's
-    float cameraDistance = (State::getCamera()->getAbsCoor() - this->getAbsCoor()).len();
-    if (cameraDistance > 30 && this->models.size() >= 3 && this->models[2] != NULL)
+      float cameraDistance = (State::getCamera()->getAbsCoor() - this->getAbsCoor()).len();
+      if (cameraDistance > 30 && this->models.size() >= 3 && this->models[2] != NULL)
+      {
+        this->models[2]->draw();
+      }
+      else if (cameraDistance > 10 && this->models.size() >= 2 && this->models[1] != NULL)
+      {
+        this->models[1]->draw();
+      }
+      else if (this->models.size() >= 1 && this->models[0] != NULL)
+      {
+        this->models[0]->draw();
+      }
+      glPopMatrix();
+    }
+    else // no LOD
     {
-       this->models[2]->draw();
+      glMatrixMode(GL_MODELVIEW);
+      glPushMatrix();
+
+      /* translate */
+      glTranslatef (this->getAbsCoor ().x,
+                    this->getAbsCoor ().y,
+                    this->getAbsCoor ().z);
+      Vector tmpRot = this->getAbsDir().getSpacialAxis();
+      glRotatef (this->getAbsDir().getSpacialAxisAngle(), tmpRot.x, tmpRot.y, tmpRot.z );
+
+      this->models[0]->draw();
+
+      glPopMatrix();
     }
-    else if (cameraDistance > 10 && this->models.size() >= 2 && this->models[1] != NULL)
-    {
-      this->models[1]->draw();
-    }
-    else if (this->models.size() >= 1 && this->models[0] != NULL)
-    {
-      this->models[0]->draw();
-    }
-    glPopMatrix();
-  }
+  }
+
 }
 
Index: branches/christmas_branche/src/world_entities/world_entity.h
===================================================================
--- branches/christmas_branche/src/world_entities/world_entity.h	(revision 6167)
+++ branches/christmas_branche/src/world_entities/world_entity.h	(revision 6169)
@@ -77,4 +77,5 @@
  private:
   std::vector<Model*>     models;             //!< The model that should be loaded for this entity.
+  bool                    supportsLOD;        //!< If this model format supports LOD (level of detail) this is true
   BVTree*                 obbTree;            //!< this is the obb tree reference needed for collision detection
 
