Changeset 4732 in orxonox.OLD for orxonox/trunk
- Timestamp:
- Jun 29, 2005, 2:30:16 AM (20 years ago)
- Location:
- orxonox/trunk/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/lib/particles/particle_system.cc
r4727 r4732 26 26 #include "material.h" 27 27 #include "state.h" 28 #include "objModel.h"29 28 30 29 #include "tinyxml.h" … … 85 84 if (this->material) 86 85 delete this->material; 87 88 ResourceManager::getInstance()->unload(this->model);89 86 } 90 87 … … 97 94 98 95 this->material = NULL; 99 this->model = NULL;100 96 this->setMaxCount(PARTICLE_DEFAULT_MAX_COUNT); 101 97 this->count = 0; … … 129 125 .describe("sets the Conserve facrot of the Particles (1.0: they keep all their energy, 0.0:they keep no energy)"); 130 126 127 LoadParam<ParticleSystem>(root, "type", this, &ParticleSystem::setType) 128 .describe("sets the type of the Particles, (dot, spark, sprite or model)"); 129 131 130 const TiXmlElement* element = root->FirstChildElement(); 132 131 while (element != NULL) 133 132 { 134 LoadParam<ParticleSystem>(element, "type", this, &ParticleSystem::setType, true)135 .describe("sets the type of the Particles, (dot, spark, sprite or model)");136 133 137 134 // PER-PARTICLE-ATTRIBUTES: … … 495 492 } 496 493 else 497 printf("no model loaded onto ParticleSystem-%s\n", this->getName());494 PRINTF(2)("no model loaded onto ParticleSystem-%s\n", this->getName()); 498 495 } 499 496 break; -
orxonox/trunk/src/world_entities/world_entity.cc
r4700 r4732 67 67 if (this->model) 68 68 ResourceManager::getInstance()->unload(this->model, RP_LEVEL); 69 this->model = (Model*)ResourceManager::getInstance()->load(fileName, OBJ, RP_CAMPAIGN); 69 if (fileName != NULL) 70 { 71 PRINTF(4)("loading %s\n", fileName); 72 this->model = (Model*)ResourceManager::getInstance()->load(fileName, OBJ, RP_CAMPAIGN); 73 } 74 else 75 this->model = NULL; 70 76 } 71 77
Note: See TracChangeset
for help on using the changeset viewer.