Changeset 7711 in orxonox.OLD for trunk/src/subprojects
- Timestamp:
- May 18, 2006, 11:44:21 PM (19 years ago)
- Location:
- trunk/src/subprojects
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/subprojects/collision_detection/collision_detection.cc
r7157 r7711 48 48 //Terrain* c; 49 49 bool animateModel = false; 50 51 50 52 51 53 void Framework::moduleInit(int argc, char** argv) … … 76 78 // CDEngine::getInstance()->debugSpawnTree(9, (sVec3D*)mod->getVertexArray(), mod->getVertexArrayCount()); 77 79 78 79 80 entityList = new tList<WorldEntity>(); 81 82 // a = new TestEntity(); a->setName("Clown1"); 83 b = new CollisionTestEntity(); b->setName("Jaeger"); 80 entityList = new tList<WorldEntity>(); 81 84 82 if (argc > 1) 85 83 { 86 84 printf("Loading model %s\n", argv[1]); 87 b ->loadModel(argv[1]);85 b = new CollisionTestEntity(argv[1]); b->setName("Jaeger"); 88 86 } 89 // a = new Terrain(); 90 87 else 88 { 89 printf("----------------------- WARNING ---------------------\n\n"); 90 printf("no path specified, using default model: models/ships/fighter.obj\n\n"); 91 printf("----------------------- WARNING ---------------------\n"); 92 b = new CollisionTestEntity("models/test/cd_test_0.obj"); b->setName("Jaeger"); 93 } 91 94 // b->setRelCoor(0.0, 0.0, -20.0); 92 95 // b->setRelDir(Quaternion(-M_PI/2.0f, Vector(0.0, 1.0, 0.0))); 93 94 entityList->add(b); 96 if(b != NULL) 97 printf("model successfully loaded\n"); 98 entityList->add(b); 99 100 101 // a = new Terrain(); 102 103 95 104 // entityList->add(b); 96 105 … … 261 270 entity->draw(); 262 271 entity->drawBVTree(depth, drawMode); 263 printf("%i, %i\n", depth, drawMode);272 // printf("%i, %i\n", depth, drawMode); 264 273 entity = iterator->nextElement(); 265 274 } -
trunk/src/subprojects/collision_detection/collision_test_entity.cc
r7193 r7711 31 31 * creates an environment 32 32 */ 33 CollisionTestEntity::CollisionTestEntity ( ) : WorldEntity()33 CollisionTestEntity::CollisionTestEntity (const char* modelName) : WorldEntity() 34 34 { 35 35 this->init(); 36 this->loadModel( "models/ships/reaplow.obj");37 // this->loadModel("models/ships/figther.obj"); 36 this->loadModel(modelName, 1.0f, 0, 10); 37 /* this->buildObbTree(0);*/ 38 38 39 this->buildObbTree(10);40 39 } 41 40 … … 81 80 void CollisionTestEntity::tick (float time) {} 82 81 83 -
trunk/src/subprojects/collision_detection/collision_test_entity.h
r7157 r7711 19 19 20 20 public: 21 CollisionTestEntity ( );21 CollisionTestEntity (const char* modelName); 22 22 CollisionTestEntity (const TiXmlElement* root); 23 23 virtual ~CollisionTestEntity (); -
trunk/src/subprojects/framework.cc
r7256 r7711 34 34 LightManager::getInstance(); 35 35 36 const char* dataPath; 37 if ((dataPath = Preferences::getInstance()->getString(CONFIG_SECTION_DATA, CONFIG_NAME_DATADIR, ""))!= NULL) 36 std::string dataPath = //Preferences::getInstance()->getString(CONFIG_SECTION_DATA, CONFIG_NAME_DATADIR, ""); 37 "/home/boenzlip/orxonox/data/trunk/"; 38 printf("%s\n", dataPath.c_str()); 39 if (!dataPath.empty()) 38 40 { 39 41 if (!ResourceManager::getInstance()->setDataDir(dataPath)) … … 48 50 PRINTF(1)("The DataDirectory %s could not be verified\n" \ 49 51 " Please Change in File %s Section %s Entry %s to a suitable value\n", 50 ResourceManager::getInstance()->getDataDir() ,52 ResourceManager::getInstance()->getDataDir().c_str(), 51 53 DEFAULT_CONFIG_FILE, 52 54 CONFIG_SECTION_DATA,
Note: See TracChangeset
for help on using the changeset viewer.