Changeset 4309 in orxonox.OLD for orxonox/branches/physics/src/subprojects
- Timestamp:
- May 26, 2005, 9:07:53 PM (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/branches/physics/src/subprojects/particles/framework.cc
r4308 r4309 173 173 174 174 case SDLK_1: 175 break; 175 { 176 ParticleEmitter* tmpEmit = ParticleEngine::getInstance()->getEmitterByNumber(1); 177 if (tmpEmit) 178 { 179 tmpEmit->setEmissionRate(tmpEmit->getEmissionRate() +1.0); 180 PRINT(3)("emissionRate set to %f\n", tmpEmit->getEmissionRate()); 181 } 182 } 183 break; 184 case SDLK_2: 185 { 186 ParticleEmitter* tmpEmit = ParticleEngine::getInstance()->getEmitterByNumber(1); 187 if (tmpEmit) 188 { 189 tmpEmit->setEmissionRate(tmpEmit->getEmissionRate() -1.0); 190 PRINT(3)("emissionRate set to %f\n", tmpEmit->getEmissionRate()); 191 } 192 } 193 break; 194 case SDLK_3: 195 { 196 ParticleEmitter* tmpEmit = ParticleEngine::getInstance()->getEmitterByNumber(1); 197 if (tmpEmit) 198 { 199 tmpEmit->setEmissionVelocity(tmpEmit->getEmissionVelocity() -.01); 200 PRINT(3)("emissionVelocity set to %f\n", tmpEmit->getEmissionVelocity()); 201 } 202 } 203 break; 204 case SDLK_4: 205 { 206 ParticleEmitter* tmpEmit = ParticleEngine::getInstance()->getEmitterByNumber(1); 207 if (tmpEmit) 208 { 209 tmpEmit->setEmissionVelocity(tmpEmit->getEmissionVelocity() + .01); 210 PRINT(3)("emissionVelocity set to %f\n", tmpEmit->getEmissionVelocity()); 211 } 212 } 213 break; 214 case SDLK_5: 215 { 216 ParticleEmitter* tmpEmit = ParticleEngine::getInstance()->getEmitterByNumber(1); 217 if (tmpEmit) 218 { 219 tmpEmit->setSpread(tmpEmit->getSpread() +.1); 220 PRINT(3)("emissionSpreadAngle set to %f\n", tmpEmit->getSpread()); 221 } 222 } 223 break; 224 case SDLK_6: 225 { 226 ParticleEmitter* tmpEmit = ParticleEngine::getInstance()->getEmitterByNumber(1); 227 if (tmpEmit) 228 { 229 tmpEmit->setSpread(tmpEmit->getSpread() -.1); 230 PRINT(3)("emissionSpreadAngle set to %f\n", tmpEmit->getSpread()); 231 } 232 } 233 break; 234 case SDLK_7: 235 { 236 ParticleEmitter* tmpEmit = ParticleEngine::getInstance()->getEmitterByNumber(1); 237 if (tmpEmit) 238 { 239 tmpEmit->setSize(tmpEmit->getSize() - 1.0); 240 PRINT(3)("EmitterSize set to %f\n", tmpEmit->getSize()); 241 } 242 } 243 break; 244 case SDLK_8: 245 { 246 ParticleEmitter* tmpEmit = ParticleEngine::getInstance()->getEmitterByNumber(1); 247 if (tmpEmit) 248 { 249 tmpEmit->setSize(tmpEmit->getSize() +1.0); 250 PRINT(3)("EmitterSize set to %f\n", tmpEmit->getSize()); 251 } 252 } 253 break; 254 case SDLK_9: 255 { 256 ParticleEmitter* tmpEmit = ParticleEngine::getInstance()->getEmitterByNumber(1); 257 if (tmpEmit) 258 { 259 if (tmpEmit->getType() == EMITTER_DOT) 260 tmpEmit->setType(EMITTER_PLANE); 261 else if (tmpEmit->getType() == EMITTER_PLANE) 262 tmpEmit->setType(EMITTER_CUBE); 263 else if (tmpEmit->getType() == EMITTER_CUBE) 264 tmpEmit->setType(EMITTER_DOT); 265 PRINT(3)("EmitterType set to %d\n", tmpEmit->getType()); 266 } 267 } 268 break; 269 176 270 } 177 271 break; … … 238 332 void Framework::printHelp(void) const 239 333 { 240 PRINT(0)("Help for the frameWork \n"); 241 PRINT(0)("----------------------"); 242 PRINT(0)("h - print Help\n"); 243 PRINT(0)("i - state Information\n"); 334 PRINT(0)(" Help for the frameWork\n"); 335 PRINT(0)("========================\n"); 336 PRINT(0)("h - print thisHelp\n"); 337 PRINT(0)("i - state Information\n\n"); 338 PRINT(0)("Emitter Properties\n"); 244 339 PRINT(0)("1,2 - increase/decrease emissionRate\n"); 245 340 PRINT(0)("3,4 - increase/decrease emission velocity\n"); 246 341 PRINT(0)("5,6 - increase/decrease spread angle\n"); 247 PRINT(0)("\n");248 342 PRINT(0)("7,8 - increase-decrease emitter-size\n"); 249 343 PRINT(0)("9 - swap emitterType\n");
Note: See TracChangeset
for help on using the changeset viewer.