Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 6911 in orxonox.OLD for branches/current_cd/src/world_entities


Ignore:
Timestamp:
Jan 31, 2006, 7:12:41 PM (19 years ago)
Author:
patrick
Message:

cd: compiles again

Location:
branches/current_cd/src/world_entities
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/current_cd/src/world_entities/world_entity.cc

    r6909 r6911  
    204204 * @param depth the depth to calculate
    205205 */
    206 bool WorldEntity::buildObbTree(unsigned int depth)
    207 {
    208 <<<<<<< .working
     206bool WorldEntity::buildObbTree(int depth)
     207{
    209208  if (this->obbTree)
    210209    delete this->obbTree;
     
    212211  if (this->models[0] != NULL)
    213212  {
    214 =======
    215   if( this->model != NULL) {
    216 >>>>>>> .merge-right.r6905
    217     PRINTF(4)("creating obb tree\n");
    218 <<<<<<< .working
    219 
    220 
    221     this->obbTree = new OBBTree(depth, (sVec3D*)this->models[0]->getVertexArray(), this->models[0]->getVertexCount());
    222 =======
    223     //this->obbTree = new OBBTree(depth, (sVec3D*)this->model->getVertexArray(), this->model->getVertexCount());
    224     this->obbTree = new OBBTree(depth, *model->getModelInfo());
    225 >>>>>>> .merge-right.r6905
     213    this->obbTree = new OBBTree(depth, models[0]->getModelInfo());
    226214    return true;
    227215  }
     
    266254 * Implement behaviour like damage application or other miscellaneous collision stuff in this function
    267255 */
    268 void WorldEntity::collidesWith(const WorldEntity& entity, const Vector& location) const
     256void WorldEntity::collidesWith(WorldEntity* entity, const Vector& location)
    269257{
    270258  /**
  • branches/current_cd/src/world_entities/world_entity.h

    r6910 r6911  
    3939  void setModel(Model* model, unsigned int modelNumber = 0);
    4040  Model* getModel(unsigned int modelNumber = 0) const { return (this->models.size() > modelNumber)? this->models[modelNumber] : NULL; };
     41  bool buildObbTree(int depth);
    4142
    4243  inline void loadMD2Texture(const char* fileName) { this->md2TextureFileName = fileName; }
    43 
    44   bool buildObbTree(unsigned int depth);
    45   /** @returns a reference to the obb tree of this worldentity */
    46   BVTree* getOBBTree() const { return this->obbTree; };
    4744
    4845  /** @param visibility if the Entity should be visible (been draw) */
     
    5148  inline bool isVisible() const { return this->bVisible; };
    5249
    53 
    54 
    5550  virtual void postSpawn ();
    5651  virtual void leftWorld ();
    5752
    5853  virtual void tick (float time);
    59 
    6054  virtual void draw () const;
    6155
    62 
    6356  virtual void collidesWith (WorldEntity* entity, const Vector& location);
    64 
    6557  void drawBVTree(unsigned int depth, int drawMode) const;
    6658  /** @returns a reference to the obb tree of this worldentity */
    67   inline const BVTree* getOBBTree() const { return this->obbTree; };
    68 
     59  inline BVTree* getOBBTree() const { return this->obbTree; };
    6960
    7061
Note: See TracChangeset for help on using the changeset viewer.