Index: orxonox/trunk/src/lib/graphics/importer/md2Model.cc
===================================================================
--- orxonox/trunk/src/lib/graphics/importer/md2Model.cc	(revision 4280)
+++ orxonox/trunk/src/lib/graphics/importer/md2Model.cc	(revision 4281)
@@ -195,12 +195,12 @@
   sVec3D* nextVec;
 
-  currVec = &this->pVertices[this->numVertices * this->animationState.currentFrame];
-  nextVec = &this->pVertices[this->numVertices * this->animationState.nextFrame];
-
-  for(int i = 0; i < this->numFrames; ++i)
-    {
-      verticesList[i][0] = (currVec[i][0] + this->animationState.interpolationState * (nextVec[i][0] - currVec[i][0])) * this->scaleFactor;
-      verticesList[i][1] = (currVec[i][1] + this->animationState.interpolationState * (nextVec[i][1] - currVec[i][1])) * this->scaleFactor;
-      verticesList[i][2] = (currVec[i][2] + this->animationState.interpolationState * (nextVec[i][2] - currVec[i][2])) * this->scaleFactor;
+  currVec = &this->data->pVertices[this->data->numVertices * this->animationState.currentFrame];
+  nextVec = &this->data->pVertices[this->data->numVertices * this->animationState.nextFrame];
+
+  for(int i = 0; i < this->data->numFrames; ++i)
+    {
+      verticesList[i][0] = (currVec[i][0] + this->animationState.interpolationState * (nextVec[i][0] - currVec[i][0])) * this->data->scaleFactor;
+      verticesList[i][1] = (currVec[i][1] + this->animationState.interpolationState * (nextVec[i][1] - currVec[i][1])) * this->data->scaleFactor;
+      verticesList[i][2] = (currVec[i][2] + this->animationState.interpolationState * (nextVec[i][2] - currVec[i][2])) * this->data->scaleFactor;
     }
 }
@@ -247,5 +247,5 @@
 {
   static sVec3D verticesList[MD2_MAX_VERTICES]; /* performance: created only once in a lifetime */
-  int* pCommands = this->pGLCommands;
+  int* pCommands = this->data->pGLCommands;
 
   /* some face culling stuff */
@@ -257,5 +257,5 @@
   this->processLighting();
   this->interpolate(verticesList);
-  this->material->select();
+  this->data->material->select();
 
   /* draw the triangles */
@@ -274,5 +274,5 @@
       for(; i > 0; i--, pCommands += 3) /* down counting for loop, next 3 gl commands */
 	{
-	  glNormal3fv(anorms[this->pLightNormals[pCommands[2]]]);
+	  glNormal3fv(anorms[this->data->pLightNormals[pCommands[2]]]);
 	  glTexCoord2f( ((float *)pCommands)[0], 1.0-((float *)pCommands)[1] );
 	  glVertex3fv(verticesList[pCommands[2]]);
@@ -297,7 +297,7 @@
     }
 
-  if( this->animationState.currentFrame > (this->numFrames - 1) )
+  if( this->animationState.currentFrame > (this->data->numFrames - 1) )
     this->animationState.currentFrame = 0;
-  if( this->animationState.nextFrame > (this->numFrames - 1) )
+  if( this->animationState.nextFrame > (this->data->numFrames - 1) )
     this->animationState.nextFrame = 0;
 
@@ -317,10 +317,10 @@
 {
   PRINT(0)("==========================| MD2Model::debug() |===\n");
-  PRINT(0)("=  Model FileName:\t%s\n", this->fileName);
-  PRINT(0)("=  Skin FileName:\t%s\n", this->skinFileName);
-  PRINT(0)("=  Size in Memory:\t%i Bytes\n", this->header->frameSize * this->header->numFrames + 64); // 64bytes is the header size
-  PRINT(0)("=  Number of Vertices:\t%i\n", this->header->numVertices);
-  PRINT(0)("=  Number of Frames: \t%i\n", this->header->numFrames);
-  PRINT(0)("=  Height, Width\t\t%i, %i\n", this->header->skinHeight, this->header->skinWidth);
+  PRINT(0)("=  Model FileName:\t%s\n", this->data->fileName);
+  PRINT(0)("=  Skin FileName:\t%s\n", this->data->skinFileName);
+  PRINT(0)("=  Size in Memory:\t%i Bytes\n", this->data->header->frameSize * this->data->header->numFrames + 64); // 64bytes is the header size
+  PRINT(0)("=  Number of Vertices:\t%i\n", this->data->header->numVertices);
+  PRINT(0)("=  Number of Frames: \t%i\n", this->data->header->numFrames);
+  PRINT(0)("=  Height, Width\t\t%i, %i\n", this->data->header->skinHeight, this->data->header->skinWidth);
   PRINT(0)("===================================================\n\n");
 }
@@ -422,4 +422,5 @@
   this->skinFileName = new char[strlen(fileName)+1];
   strcpy(this->skinFileName, fileName);
+
   this->material = new Material("md2ModelTest");
   this->material->setDiffuseMap(fileName);
Index: orxonox/trunk/src/lib/graphics/importer/md2Model.h
===================================================================
--- orxonox/trunk/src/lib/graphics/importer/md2Model.h	(revision 4280)
+++ orxonox/trunk/src/lib/graphics/importer/md2Model.h	(revision 4281)
@@ -164,5 +164,5 @@
  private:
   MD2Data* data;
-
+  
   int numFrames;
   int numVertices;
@@ -177,4 +177,5 @@
   int* pLightNormals;
   glCommandVertex* pGLCommands2;
+  
 
   Material* material;
