Changeset 4919 in orxonox.OLD for orxonox/trunk/src
- Timestamp:
- Jul 21, 2005, 12:49:18 PM (19 years ago)
- Location:
- orxonox/trunk/src
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/lib/collision_detection/cd_engine.cc
r4918 r4919 20 20 #include "debug.h" 21 21 #include "abstract_model.h" 22 #include "list.h" 23 22 24 #include "world_entity.h" 23 #include "list.h" 25 #include "terrain.h" 26 #include "player.h" 27 28 #include "spatial_separation.h" 29 #include "quadtree.h" 30 #include "quadtree_node.h" 31 24 32 25 33 using namespace std; … … 93 101 void CDEngine::checkCollisionGround() 94 102 { 95 103 Quadtree* q = this->terrain->ssp->getQuadtree(); 104 q->getQuadtreeFromPosition(this->player->getAbsCoor()); 96 105 97 106 } -
orxonox/trunk/src/lib/collision_detection/cd_engine.h
r4918 r4919 16 16 class OBBTree; 17 17 class Terrain; 18 class Player; 18 19 19 20 … … 47 48 inline void setEntityList(tList<WorldEntity>* entityList) { this->entityList = entityList; } 48 49 inline void setTerrain(Terrain* terrain) { this->terrain = terrain; } 50 inline void setPlayer(Player* player) { this->player = player; } /* only for debug purposes \todo: delete*/ 49 51 50 52 void drawBV(int depth, int drawMode) const; … … 72 74 73 75 Terrain* terrain; //!< this it a ref to the terrain, serving as a ground for all WE 76 Player* player; 74 77 }; 75 78 -
orxonox/trunk/src/lib/graphics/spatial_separation/spatial_separation.h
r4889 r4919 33 33 Quadtree* createQuadtree(AbstractModel* model); 34 34 35 inline Quadtree* getQuadtree() { return this->quadtree; } 35 36 36 37 void drawQuadtree(); -
orxonox/trunk/src/story_entities/world.cc
r4918 r4919 377 377 // if we load a 'Player' we use it as localPlayer 378 378 //todo do this more elegant 379 if( element->Value() != NULL && !strcmp( element->Value(), "Player")) localPlayer = (Player*) created; 379 if( element->Value() != NULL && !strcmp( element->Value(), "Player")) 380 { 381 localPlayer = (Player*) created; 382 CDEngine::getInstance()->setPlayer(localPlayer); 383 } 380 384 if( element->Value() != NULL && !strcmp( element->Value(), "SkyBox")) sky = (SkyBox*) created; 381 385 if( element->Value() != NULL && !strcmp( element->Value(), "Terrain")) -
orxonox/trunk/src/world_entities/terrain.h
r4889 r4919 37 37 virtual void draw(); 38 38 39 public: 40 SpatialSeparation* ssp; 41 39 42 private: 40 43 int objectList; 41 SpatialSeparation* ssp; 44 42 45 }; 43 46
Note: See TracChangeset
for help on using the changeset viewer.