Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 6456 in orxonox.OLD for trunk/src/world_entities/environments


Ignore:
Timestamp:
Jan 10, 2006, 12:09:58 AM (19 years ago)
Author:
bensch
Message:

Water draws itself

Location:
trunk/src/world_entities/environments
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/world_entities/environments/water.cc

    r6455 r6456  
    2929Water::Water(const TiXmlElement* root)
    3030{
     31  this->setClassID(CL_WATER, "Water");
     32  this->toList(OM_ENVIRON_NOTICK);
     33
    3134  this->resX = this->resY = 10;
    3235  this->sizeX = this->sizeY = 1.0;
     
    3538  if (root != NULL)
    3639    this->loadParams(root);
     40
     41  this->rebuildGrid();
    3742}
    3843
    3944Water::~Water()
    4045{
     46  delete this->grid;
    4147
    4248}
     
    6167  this->grid = new Grid(this->sizeX, this->sizeY, this->resX, this->resY);
    6268
     69  this->setModel(this->grid, 0);
    6370}
    6471
     
    7178void Water::setSize(float sizeX, float sizeY)
    7279{
     80  printf("%f %f\n", sizeX, sizeY);
     81
    7382  this->sizeX = sizeX;
    7483  this->sizeY = sizeY;
    7584}
    7685
     86
     87void Water::tick(float dt)
     88{
     89
     90}
  • trunk/src/world_entities/environments/water.h

    r6455 r6456  
    3030   void rebuildGrid();
    3131
     32   void tick(float dt);
     33
    3234  private:
    3335    Grid*           grid;            //!< The water-surface-model to render with
Note: See TracChangeset for help on using the changeset viewer.