Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 3559 in orxonox.OLD


Ignore:
Timestamp:
Mar 15, 2005, 12:44:19 PM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: now terrain is out of the World.cc and is a world-entity

Location:
orxonox/trunk/src
Files:
5 edited
2 copied

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/Makefile.am

    r3549 r3559  
    4242                 world_entities/environment.cc \
    4343                 world_entities/skysphere.cc \
     44                 world_entities/terrain.cc \
    4445                 world_entities/primitive.cc \
    4546                 ai/ai.cc \
     
    8788                 world_entities/shoot_rocket.h \
    8889                 world_entities/power_up.h \
     90                 world_entities/terrain.h \
    8991                 world_entities/primitive.h \
    9092                 ai/ai.h \
  • orxonox/trunk/src/Makefile.in

    r3558 r3559  
    5858        story_entity.$(OBJEXT) campaign.$(OBJEXT) world.$(OBJEXT) \
    5959        world_entity.$(OBJEXT) player.$(OBJEXT) environment.$(OBJEXT) \
    60         skysphere.$(OBJEXT) primitive.$(OBJEXT) ai.$(OBJEXT) \
    61         p_node.$(OBJEXT) null_parent.$(OBJEXT) helper_parent.$(OBJEXT) \
    62         data_tank.$(OBJEXT) fontset.$(OBJEXT) array.$(OBJEXT) \
    63         objModel.$(OBJEXT) model.$(OBJEXT) material.$(OBJEXT) \
    64         texture.$(OBJEXT) base_entity.$(OBJEXT) base_object.$(OBJEXT) \
    65         ini_parser.$(OBJEXT) list.$(OBJEXT) vector.$(OBJEXT) \
    66         matrix.$(OBJEXT) curve.$(OBJEXT) glmenu_imagescreen.$(OBJEXT)
     60        skysphere.$(OBJEXT) terrain.$(OBJEXT) primitive.$(OBJEXT) \
     61        ai.$(OBJEXT) p_node.$(OBJEXT) null_parent.$(OBJEXT) \
     62        helper_parent.$(OBJEXT) data_tank.$(OBJEXT) fontset.$(OBJEXT) \
     63        array.$(OBJEXT) objModel.$(OBJEXT) model.$(OBJEXT) \
     64        material.$(OBJEXT) texture.$(OBJEXT) base_entity.$(OBJEXT) \
     65        base_object.$(OBJEXT) ini_parser.$(OBJEXT) list.$(OBJEXT) \
     66        vector.$(OBJEXT) matrix.$(OBJEXT) curve.$(OBJEXT) \
     67        glmenu_imagescreen.$(OBJEXT)
    6768orxonox_OBJECTS = $(am_orxonox_OBJECTS)
    6869orxonox_LDADD = $(LDADD)
     
    8788@AMDEP_TRUE@    ./$(DEPDIR)/p_node.Po ./$(DEPDIR)/player.Po \
    8889@AMDEP_TRUE@    ./$(DEPDIR)/primitive.Po ./$(DEPDIR)/skysphere.Po \
    89 @AMDEP_TRUE@    ./$(DEPDIR)/story_entity.Po ./$(DEPDIR)/texture.Po \
     90@AMDEP_TRUE@    ./$(DEPDIR)/story_entity.Po ./$(DEPDIR)/terrain.Po \
     91@AMDEP_TRUE@    ./$(DEPDIR)/texture.Po \
    9092@AMDEP_TRUE@    ./$(DEPDIR)/track_manager.Po \
    9193@AMDEP_TRUE@    ./$(DEPDIR)/track_node.Po ./$(DEPDIR)/vector.Po \
     
    235237                 world_entities/environment.cc \
    236238                 world_entities/skysphere.cc \
     239                 world_entities/terrain.cc \
    237240                 world_entities/primitive.cc \
    238241                 ai/ai.cc \
     
    280283                 world_entities/shoot_rocket.h \
    281284                 world_entities/power_up.h \
     285                 world_entities/terrain.h \
    282286                 world_entities/primitive.h \
    283287                 ai/ai.h \
     
    403407@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/skysphere.Po@am__quote@
    404408@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/story_entity.Po@am__quote@
     409@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/terrain.Po@am__quote@
    405410@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/texture.Po@am__quote@
    406411@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/track_manager.Po@am__quote@
     
    537542@AMDEP_TRUE@@am__fastdepCXX_FALSE@      $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
    538543@am__fastdepCXX_FALSE@  $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o skysphere.obj `if test -f 'world_entities/skysphere.cc'; then $(CYGPATH_W) 'world_entities/skysphere.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/skysphere.cc'; fi`
     544
     545terrain.o: world_entities/terrain.cc
     546@am__fastdepCXX_TRUE@   if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT terrain.o -MD -MP -MF "$(DEPDIR)/terrain.Tpo" -c -o terrain.o `test -f 'world_entities/terrain.cc' || echo '$(srcdir)/'`world_entities/terrain.cc; \
     547@am__fastdepCXX_TRUE@   then mv -f "$(DEPDIR)/terrain.Tpo" "$(DEPDIR)/terrain.Po"; else rm -f "$(DEPDIR)/terrain.Tpo"; exit 1; fi
     548@AMDEP_TRUE@@am__fastdepCXX_FALSE@      source='world_entities/terrain.cc' object='terrain.o' libtool=no @AMDEPBACKSLASH@
     549@AMDEP_TRUE@@am__fastdepCXX_FALSE@      depfile='$(DEPDIR)/terrain.Po' tmpdepfile='$(DEPDIR)/terrain.TPo' @AMDEPBACKSLASH@
     550@AMDEP_TRUE@@am__fastdepCXX_FALSE@      $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
     551@am__fastdepCXX_FALSE@  $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o terrain.o `test -f 'world_entities/terrain.cc' || echo '$(srcdir)/'`world_entities/terrain.cc
     552
     553terrain.obj: world_entities/terrain.cc
     554@am__fastdepCXX_TRUE@   if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT terrain.obj -MD -MP -MF "$(DEPDIR)/terrain.Tpo" -c -o terrain.obj `if test -f 'world_entities/terrain.cc'; then $(CYGPATH_W) 'world_entities/terrain.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/terrain.cc'; fi`; \
     555@am__fastdepCXX_TRUE@   then mv -f "$(DEPDIR)/terrain.Tpo" "$(DEPDIR)/terrain.Po"; else rm -f "$(DEPDIR)/terrain.Tpo"; exit 1; fi
     556@AMDEP_TRUE@@am__fastdepCXX_FALSE@      source='world_entities/terrain.cc' object='terrain.obj' libtool=no @AMDEPBACKSLASH@
     557@AMDEP_TRUE@@am__fastdepCXX_FALSE@      depfile='$(DEPDIR)/terrain.Po' tmpdepfile='$(DEPDIR)/terrain.TPo' @AMDEPBACKSLASH@
     558@AMDEP_TRUE@@am__fastdepCXX_FALSE@      $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
     559@am__fastdepCXX_FALSE@  $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o terrain.obj `if test -f 'world_entities/terrain.cc'; then $(CYGPATH_W) 'world_entities/terrain.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/terrain.cc'; fi`
    539560
    540561primitive.o: world_entities/primitive.cc
  • orxonox/trunk/src/story_entities/world.cc

    r3556 r3559  
    3131#include "fontset.h"
    3232#include "track_node.h"
     33#include "terrain.h"
    3334
    3435using namespace std;
     
    299300  objectList = glGenLists(1);
    300301  glNewList (objectList, GL_COMPILE);
    301 
    302   glColor3f(1.0,0,0);
    303 
    304   int sizeX = 100;
    305   int sizeZ = 80;
    306   float length = 1000;
    307   float width = 200;
    308   float widthX = float (length /sizeX);
    309   float widthZ = float (width /sizeZ);
    310  
    311   float height [sizeX][sizeZ];
    312   Vector normal_vectors[sizeX][sizeZ];
    313  
    314  
    315   for ( int i = 0; i<sizeX-1; i+=1)
    316     for (int j = 0; j<sizeZ-1;j+=1)
    317       //height[i][j] = rand()/20046 + (j-25)*(j-25)/30;
    318 #ifdef __WIN32__
    319       height[i][j]=(sin((float)j/3)*rand()*i/182400)*.5;
    320 #else
    321       height[i][j]=(sin((float)j/3)*rand()*(long)i/6282450500.0)*.5;
    322 #endif
    323 
    324   //Die Huegel ein wenig glaetten
    325   for (int h=1; h<2;h++)
    326     for (int i=1;i<sizeX-2 ;i+=1 )
    327       for(int j=1;j<sizeZ-2;j+=1)
    328         height[i][j]=(height[i+1][j]+height[i][j+1]+height[i-1][j]+height[i][j-1])/4;
    329  
    330   //Berechnung von normalen Vektoren
    331   for(int i=1;i<sizeX-2;i+=1)
    332     for(int j=1;j<sizeZ-2 ;j+=1)
    333       {
    334         Vector v1 = Vector (widthX*(1),      height[i][j],      widthZ*(j) );
    335         Vector v2 = Vector (widthX*(i-1),    height[i-1][j],    widthZ*(j));
    336         Vector v3 = Vector (widthX*(i),      height[i][j+1],    widthZ*(j+1));
    337         Vector v4 = Vector (widthX*(i+1),    height[i+1][j],    widthZ*(j));
    338         Vector v5 = Vector (widthX*(i),      height[i][j-1],    widthZ*(j-1));
    339        
    340         Vector c1 = v2 - v1;
    341         Vector c2 = v3 - v1;
    342         Vector c3=  v4 - v1;
    343         Vector c4 = v5 - v1;
    344         Vector zero = Vector (0,0,0);
    345         normal_vectors[i][j]=c1.cross(v3-v5)+c2.cross(v4-v2)+c3.cross(v5-v3)+c4.cross(v2-v4);
    346         normal_vectors[i][j].normalize();
    347       }
    348 
    349   glBegin(GL_QUADS);
    350   int snowheight=3;
    351   for ( int i = 0; i<sizeX; i+=1)
    352     for (int j = 0; j<sizeZ;j+=1)
    353       {   
    354         Vector v1 = Vector (widthX*(i),      height[i][j]-20,       widthZ*(j)  -width/2);
    355         Vector v2 = Vector (widthX*(i+1),    height[i+1][j]-20,     widthZ*(j)  -width/2);
    356         Vector v3 = Vector (widthX*(i+1),    height[i+1][j+1]-20,   widthZ*(j+1)-width/2);
    357         Vector v4 = Vector (widthX*(i),      height[i][j+1]-20,     widthZ*(j+1)-width/2);
    358         float a[3];
    359         if(height[i][j]<snowheight){
    360           a[0]=0;
    361           a[1]=1.0-height[i][j]/10-.3;
    362           a[2]=0;
    363           glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
    364         }
    365         else{
    366             a[0]=1.0;
    367             a[1]=1.0;
    368             a[2]=1.0;
    369             glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
    370            
    371         }
    372         glNormal3f(normal_vectors[i][j].x, normal_vectors[i][j].y, normal_vectors[i][j].z);
    373         glVertex3f(v1.x, v1.y, v1.z);
    374         if(height[i+1][j]<snowheight){
    375           a[0]=0;
    376           a[1] =1.0-height[i+1][j]/10-.3;
    377           a[2]=0;
    378           glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
    379         }
    380         else{
    381           a[0]=1.0;
    382           a[1]=1.0;
    383           a[2]=1.0;
    384           glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
    385          
    386         }
    387         glNormal3f(normal_vectors[i+1][j].x, normal_vectors[i+1][j].y, normal_vectors[i+1][j].z);
    388         glVertex3f(v2.x, v2.y, v2.z);
    389         if(height[i+1][j+1]<snowheight){
    390           a[0]=0;
    391           a[1] =1.0-height[i+1][j+1]/10-.3;
    392           a[2]=0;
    393           glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
    394         }
    395         else{
    396           a[0]=1.0;
    397           a[1]=1.0;
    398           a[2]=1.0;
    399           glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
    400          
    401          
    402         }
    403         glNormal3f(normal_vectors[i+1][j+1].x, normal_vectors[i+1][j+1].y, normal_vectors[i+1][j+1].z);
    404         glVertex3f(v3.x, v3.y, v3.z);
    405         if(height[i][j+1]<snowheight){
    406           a[0]=0;
    407           a[1] =1.0-height[i+1][j+1]/10-.3;
    408           a[2]=0;
    409           glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
    410         }
    411         else{
    412           a[0]=1.0;
    413           a[1]=1.0;
    414           a[2]=1.0;
    415           glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
    416         }
    417         glNormal3f(normal_vectors[i][j+1].x, normal_vectors[i][j+1].y, normal_vectors[i][j+1].z);
    418         glVertex3f(v4.x, v4.y, v4.z);
    419        
    420       }
    421   glEnd();
    422 
     302 
    423303  trackManager->drawGraph(.01);
    424304  trackManager->debug(2);
    425305  glEndList();
    426306
    427 
     307  terrain = new Terrain();
     308  this->spawn(terrain);
    428309  // LIGHT initialisation
    429310  light = Light::getInstance();
  • orxonox/trunk/src/story_entities/world.h

    r3551 r3559  
    1919class Light;
    2020class FontSet;
     21class Terrain;
    2122
    2223
     
    7576  Skysphere* skySphere;         //!< The Environmental Heaven of orxonox \todo insert this to environment insted
    7677  Light* light;                 //!< The Lights of the Level
     78  Terrain* terrain;             //!< The Terrain of the World.
    7779
    7880  GLuint objectList;            //!< temporary: \todo this will be ereased soon
  • orxonox/trunk/src/world_entities/skysphere.cc

    r3544 r3559  
    7171  this->sphereObj = gluNewQuadric();
    7272  gluQuadricTexture(this->sphereObj, GL_TRUE);
    73   this->setRadius(250.0);
     73  this->setRadius(220.0);
    7474
    7575  this->skyMaterial = new Material("Sky");
  • orxonox/trunk/src/world_entities/terrain.cc

    r3558 r3559  
    1 
    2 
    31/*
    42   orxonox - the future of 3D-vertical-scrollers
     
    1715
    1816
    19 #include "proto_class.h"
     17#include "terrain.h"
    2018
    21 #include "stdincl.h" // maybe
     19#include "glincl.h"
    2220
    2321using namespace std;
     
    2624/**
    2725   \brief standard constructor
    28    \todo this constructor is not jet implemented - do it
     26
    2927*/
    30 ProtoClass::ProtoClass ()
     28Terrain::Terrain ()
    3129{
    32    this->setClassName ("ProtoClass");
     30   this->setClassName ("Terrain");
     31   this->build();
    3332}
    3433
     
    3837
    3938*/
    40 ProtoClass::~ProtoClass ()
     39Terrain::~Terrain ()
    4140{
    4241  // delete what has to be deleted here
     42  //  delete this->model;
     43 
     44  glDeleteLists(this->objectList, 1);
    4345}
    4446
    45 /**
    46    \brief nonsense - delete this method
    47    \param realy nothing to give
    48    \returns true or false - probably nothing?
    4947
    50    this is just to show the doxygen abilities (this for example is an extension for a long comment)
    51 */
    52 bool ProtoClass::doNonSense (int nothing) {}
     48void Terrain::build()
     49{
     50  objectList = glGenLists(1);
     51  glNewList (objectList, GL_COMPILE);
     52
     53  glColor3f(1.0,0,0);
     54
     55  int sizeX = 100;
     56  int sizeZ = 80;
     57  float length = 1000;
     58  float width = 200;
     59  float widthX = float (length /sizeX);
     60  float widthZ = float (width /sizeZ);
     61 
     62  float height [sizeX][sizeZ];
     63  Vector normal_vectors[sizeX][sizeZ];
     64 
     65 
     66  for ( int i = 0; i<sizeX-1; i+=1)
     67    for (int j = 0; j<sizeZ-1;j+=1)
     68      //height[i][j] = rand()/20046 + (j-25)*(j-25)/30;
     69#ifdef __WIN32__
     70      height[i][j]=(sin((float)j/3)*rand()*i/182400)*.5;
     71#else
     72      height[i][j]=(sin((float)j/3)*rand()*(long)i/6282450500.0)*.5;
     73#endif
     74
     75  //Die Huegel ein wenig glaetten
     76  for (int h=1; h<2;h++)
     77    for (int i=1;i<sizeX-2 ;i+=1 )
     78      for(int j=1;j<sizeZ-2;j+=1)
     79        height[i][j]=(height[i+1][j]+height[i][j+1]+height[i-1][j]+height[i][j-1])/4;
     80 
     81  //Berechnung von normalen Vektoren
     82  for(int i=1;i<sizeX-2;i+=1)
     83    for(int j=1;j<sizeZ-2 ;j+=1)
     84      {
     85        Vector v1 = Vector (widthX*(1),      height[i][j],      widthZ*(j) );
     86        Vector v2 = Vector (widthX*(i-1),    height[i-1][j],    widthZ*(j));
     87        Vector v3 = Vector (widthX*(i),      height[i][j+1],    widthZ*(j+1));
     88        Vector v4 = Vector (widthX*(i+1),    height[i+1][j],    widthZ*(j));
     89        Vector v5 = Vector (widthX*(i),      height[i][j-1],    widthZ*(j-1));
     90       
     91        Vector c1 = v2 - v1;
     92        Vector c2 = v3 - v1;
     93        Vector c3=  v4 - v1;
     94        Vector c4 = v5 - v1;
     95        Vector zero = Vector (0,0,0);
     96        normal_vectors[i][j]=c1.cross(v3-v5)+c2.cross(v4-v2)+c3.cross(v5-v3)+c4.cross(v2-v4);
     97        normal_vectors[i][j].normalize();
     98      }
     99
     100  glBegin(GL_QUADS);
     101  int snowheight=3;
     102  for ( int i = 0; i<sizeX; i+=1)
     103    for (int j = 0; j<sizeZ;j+=1)
     104      {   
     105        Vector v1 = Vector (widthX*(i),      height[i][j]-20,       widthZ*(j)  -width/2);
     106        Vector v2 = Vector (widthX*(i+1),    height[i+1][j]-20,     widthZ*(j)  -width/2);
     107        Vector v3 = Vector (widthX*(i+1),    height[i+1][j+1]-20,   widthZ*(j+1)-width/2);
     108        Vector v4 = Vector (widthX*(i),      height[i][j+1]-20,     widthZ*(j+1)-width/2);
     109        float a[3];
     110        if(height[i][j]<snowheight){
     111          a[0]=0;
     112          a[1]=1.0-height[i][j]/10-.3;
     113          a[2]=0;
     114          glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
     115        }
     116        else{
     117            a[0]=1.0;
     118            a[1]=1.0;
     119            a[2]=1.0;
     120            glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
     121           
     122        }
     123        glNormal3f(normal_vectors[i][j].x, normal_vectors[i][j].y, normal_vectors[i][j].z);
     124        glVertex3f(v1.x, v1.y, v1.z);
     125        if(height[i+1][j]<snowheight){
     126          a[0]=0;
     127          a[1] =1.0-height[i+1][j]/10-.3;
     128          a[2]=0;
     129          glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
     130        }
     131        else{
     132          a[0]=1.0;
     133          a[1]=1.0;
     134          a[2]=1.0;
     135          glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
     136         
     137        }
     138        glNormal3f(normal_vectors[i+1][j].x, normal_vectors[i+1][j].y, normal_vectors[i+1][j].z);
     139        glVertex3f(v2.x, v2.y, v2.z);
     140        if(height[i+1][j+1]<snowheight){
     141          a[0]=0;
     142          a[1] =1.0-height[i+1][j+1]/10-.3;
     143          a[2]=0;
     144          glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
     145        }
     146        else{
     147          a[0]=1.0;
     148          a[1]=1.0;
     149          a[2]=1.0;
     150          glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
     151         
     152         
     153        }
     154        glNormal3f(normal_vectors[i+1][j+1].x, normal_vectors[i+1][j+1].y, normal_vectors[i+1][j+1].z);
     155        glVertex3f(v3.x, v3.y, v3.z);
     156        if(height[i][j+1]<snowheight){
     157          a[0]=0;
     158          a[1] =1.0-height[i+1][j+1]/10-.3;
     159          a[2]=0;
     160          glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
     161        }
     162        else{
     163          a[0]=1.0;
     164          a[1]=1.0;
     165          a[2]=1.0;
     166          glMaterialfv(GL_FRONT,GL_DIFFUSE,a);
     167        }
     168        glNormal3f(normal_vectors[i][j+1].x, normal_vectors[i][j+1].y, normal_vectors[i][j+1].z);
     169        glVertex3f(v4.x, v4.y, v4.z);
     170       
     171      }
     172  glEnd();
     173  glEndList();
     174}
     175
     176
     177
     178void Terrain::draw ()
     179{
     180  glMatrixMode(GL_MODELVIEW);
     181  glPushMatrix();
     182  float matrix[4][4];
     183 
     184  /* translate */
     185  glTranslatef (this->getAbsCoor ().x,
     186                this->getAbsCoor ().y,
     187                this->getAbsCoor ().z);
     188  /* rotate */
     189  this->getAbsDir ().matrix (matrix);
     190  glMultMatrixf((float*)matrix);
     191
     192  glCallList(objectList);
     193  //  this->model->draw();
     194  glPopMatrix();
     195}
  • orxonox/trunk/src/world_entities/terrain.h

    r3558 r3559  
    11/*!
    2     \file proto_class.h
    3     \brief Definition of the proto class template, used quickly start work
    4     \todo Example: this shows how to use simply add a Marker that here has to be done something.
     2    \file terrain.h
     3    \brief Defines and handles the terrain of the World
    54
    6     The Protoclass exists, to help you quikly getting the run for how to develop in orxonox.
    7     It is an example for the CODING-CONVENTION, and a starting-point for every class.
     5    \todo implement it
     6
     7    The terrain should either be build from a Model a OBJModel or from a HeightMap.
    88*/
    99
    10 #ifndef _PROTO_CLASS_H
    11 #define _PROTO_CLASS_H
     10#ifndef _TERRAIN_H
     11#define _TERRAIN_H
    1212
    13 #include "what realy has to be included"
    14 #include "base_object.h"
     13#include "world_entity.h"
    1514
    1615// FORWARD DEFINITION \\
    17 class someClassWeNeed;
    1816
    19 
    20 /*class Test;*/ /* forward definition of class Test (without including it here!)*/
    21 
    22 //! A default class that aids you to start creating a new class
    23 /**
    24    here can be some longer description of this class
    25 */
    26 class ProtoClass : public BaseObject {
     17//! A Class to handle Terrain of orxonox
     18class Terrain : public WorldEntity
     19{
    2720
    2821 public:
    29   ProtoClass();
    30   virtual ~ProtoClass();
     22  Terrain();
     23  virtual ~Terrain();
    3124
    32   bool doNonSense (int nothing);
     25  void build();
     26  virtual void draw();
    3327
    3428 private:
    35   int nonSense;  //!< doxygen tag here like this for all the variables - delete this variable if you use this
    3629
     30  int objectList;
    3731};
    3832
    39 #endif /* _PROTO_CLASS_H */
     33#endif /* _TERRAIN_H */
Note: See TracChangeset for help on using the changeset viewer.