Changeset 5087 in orxonox.OLD for trunk/src/world_entities/test_entity.cc
- Timestamp:
- Aug 20, 2005, 5:39:13 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/world_entities/test_entity.cc
r5085 r5087 22 22 #include "md2Model.h" 23 23 #include "obb_tree.h" 24 #include "state.h" 25 #include "list.h" 24 26 25 27 using namespace std; … … 31 33 this->setClassID(CL_TEST_ENTITY, "TestEntity"); 32 34 35 this->md2Model = new MD2Model("models/droidika.md2", "models/droideka.pcx"); 33 36 // this->md2Model = new MD2Model("models/tris.md2", "models/tris.pcx"); 34 this->md2Model = new MD2Model("models/goblin.md2", "maps/goblin.bmp");35 this->obbTree = new OBBTree( 15, (sVec3D*)this->md2Model->data->pVertices, this->md2Model->data->numVertices);37 // this->md2Model = new MD2Model("models/goblin.md2", "maps/goblin.bmp"); 38 this->obbTree = new OBBTree(4, (sVec3D*)this->md2Model->data->pVertices, this->md2Model->data->numVertices); 36 39 37 this->md2Model->setAnim( STAND);40 this->md2Model->setAnim(RUN); 38 41 this->md2Model->debug(); 39 42 } … … 57 60 } 58 61 62 63 void TestEntity::collidesWith(WorldEntity* entity, const Vector& location) 64 { 65 if (entity->isA(CL_PROJECTILE)) 66 { 67 PRINTF(3)("collision %s vs %s @ (%f,%f,%f)\n", this->getName(), entity->getName(), location.x, location.y, location.z); 68 this->setVisibiliy(false); 69 State::getWorldEntityList()->remove(this); 70 } 71 } 59 72 60 73 void TestEntity::hit (WorldEntity* weapon, Vector* loc) {}
Note: See TracChangeset
for help on using the changeset viewer.