Changeset 5456 in orxonox.OLD for trunk/src/world_entities
- Timestamp:
- Oct 30, 2005, 12:54:23 AM (19 years ago)
- Location:
- trunk/src/world_entities
- Files:
-
- 4 edited
- 4 copied
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/world_entities/Makefile.am
r5450 r5456 19 19 weapons/weapon_manager.cc \ 20 20 weapons/weapon.cc \ 21 weapons/projectile.cc \22 21 weapons/test_gun.cc \ 23 22 weapons/turret.cc \ 23 weapons/projectile.cc \ 24 24 weapons/test_bullet.cc \ 25 weapons/rocket.cc \ 26 weapons/laser.cc \ 25 27 weapons/crosshair.cc \ 26 28 power_ups/power_up.cc \ -
trunk/src/world_entities/Makefile.in
r5450 r5456 56 56 player.lo npc.lo npc2.lo environment.lo skysphere.lo skybox.lo \ 57 57 terrain.lo satellite.lo character_attributes.lo test_entity.lo \ 58 weapon_manager.lo weapon.lo projectile.lo test_gun.lo \59 turret.lo test_bullet.lo crosshair.lo power_up.lo \60 turret_power_up.lo58 weapon_manager.lo weapon.lo test_gun.lo turret.lo \ 59 projectile.lo test_bullet.lo rocket.lo laser.lo crosshair.lo \ 60 power_up.lo turret_power_up.lo 61 61 libORXworld_entities_la_OBJECTS = \ 62 62 $(am_libORXworld_entities_la_OBJECTS) … … 67 67 @AMDEP_TRUE@ ./$(DEPDIR)/character_attributes.Plo \ 68 68 @AMDEP_TRUE@ ./$(DEPDIR)/crosshair.Plo \ 69 @AMDEP_TRUE@ ./$(DEPDIR)/environment.Plo ./$(DEPDIR)/ npc.Plo \70 @AMDEP_TRUE@ ./$(DEPDIR)/npc 2.Plo ./$(DEPDIR)/player.Plo \71 @AMDEP_TRUE@ ./$(DEPDIR)/p ower_up.Plo \72 @AMDEP_TRUE@ ./$(DEPDIR)/projectile.Plo \69 @AMDEP_TRUE@ ./$(DEPDIR)/environment.Plo ./$(DEPDIR)/laser.Plo \ 70 @AMDEP_TRUE@ ./$(DEPDIR)/npc.Plo ./$(DEPDIR)/npc2.Plo \ 71 @AMDEP_TRUE@ ./$(DEPDIR)/player.Plo ./$(DEPDIR)/power_up.Plo \ 72 @AMDEP_TRUE@ ./$(DEPDIR)/projectile.Plo ./$(DEPDIR)/rocket.Plo \ 73 73 @AMDEP_TRUE@ ./$(DEPDIR)/satellite.Plo ./$(DEPDIR)/skybox.Plo \ 74 74 @AMDEP_TRUE@ ./$(DEPDIR)/skysphere.Plo ./$(DEPDIR)/terrain.Plo \ … … 235 235 weapons/weapon_manager.cc \ 236 236 weapons/weapon.cc \ 237 weapons/projectile.cc \238 237 weapons/test_gun.cc \ 239 238 weapons/turret.cc \ 239 weapons/projectile.cc \ 240 240 weapons/test_bullet.cc \ 241 weapons/rocket.cc \ 242 weapons/laser.cc \ 241 243 weapons/crosshair.cc \ 242 244 power_ups/power_up.cc \ … … 340 342 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/crosshair.Plo@am__quote@ 341 343 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/environment.Plo@am__quote@ 344 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/laser.Plo@am__quote@ 342 345 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/npc.Plo@am__quote@ 343 346 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/npc2.Plo@am__quote@ … … 345 348 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/power_up.Plo@am__quote@ 346 349 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/projectile.Plo@am__quote@ 350 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rocket.Plo@am__quote@ 347 351 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/satellite.Plo@am__quote@ 348 352 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/skybox.Plo@am__quote@ … … 430 434 @am__fastdepCXX_FALSE@ $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o weapon.lo `test -f 'weapons/weapon.cc' || echo '$(srcdir)/'`weapons/weapon.cc 431 435 436 test_gun.o: weapons/test_gun.cc 437 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_gun.o -MD -MP -MF "$(DEPDIR)/test_gun.Tpo" -c -o test_gun.o `test -f 'weapons/test_gun.cc' || echo '$(srcdir)/'`weapons/test_gun.cc; \ 438 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/test_gun.Tpo" "$(DEPDIR)/test_gun.Po"; else rm -f "$(DEPDIR)/test_gun.Tpo"; exit 1; fi 439 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/test_gun.cc' object='test_gun.o' libtool=no @AMDEPBACKSLASH@ 440 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/test_gun.Po' tmpdepfile='$(DEPDIR)/test_gun.TPo' @AMDEPBACKSLASH@ 441 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 442 @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_gun.o `test -f 'weapons/test_gun.cc' || echo '$(srcdir)/'`weapons/test_gun.cc 443 444 test_gun.obj: weapons/test_gun.cc 445 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_gun.obj -MD -MP -MF "$(DEPDIR)/test_gun.Tpo" -c -o test_gun.obj `if test -f 'weapons/test_gun.cc'; then $(CYGPATH_W) 'weapons/test_gun.cc'; else $(CYGPATH_W) '$(srcdir)/weapons/test_gun.cc'; fi`; \ 446 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/test_gun.Tpo" "$(DEPDIR)/test_gun.Po"; else rm -f "$(DEPDIR)/test_gun.Tpo"; exit 1; fi 447 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/test_gun.cc' object='test_gun.obj' libtool=no @AMDEPBACKSLASH@ 448 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/test_gun.Po' tmpdepfile='$(DEPDIR)/test_gun.TPo' @AMDEPBACKSLASH@ 449 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 450 @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_gun.obj `if test -f 'weapons/test_gun.cc'; then $(CYGPATH_W) 'weapons/test_gun.cc'; else $(CYGPATH_W) '$(srcdir)/weapons/test_gun.cc'; fi` 451 452 test_gun.lo: weapons/test_gun.cc 453 @am__fastdepCXX_TRUE@ if $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_gun.lo -MD -MP -MF "$(DEPDIR)/test_gun.Tpo" -c -o test_gun.lo `test -f 'weapons/test_gun.cc' || echo '$(srcdir)/'`weapons/test_gun.cc; \ 454 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/test_gun.Tpo" "$(DEPDIR)/test_gun.Plo"; else rm -f "$(DEPDIR)/test_gun.Tpo"; exit 1; fi 455 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/test_gun.cc' object='test_gun.lo' libtool=yes @AMDEPBACKSLASH@ 456 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/test_gun.Plo' tmpdepfile='$(DEPDIR)/test_gun.TPlo' @AMDEPBACKSLASH@ 457 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 458 @am__fastdepCXX_FALSE@ $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_gun.lo `test -f 'weapons/test_gun.cc' || echo '$(srcdir)/'`weapons/test_gun.cc 459 460 turret.o: weapons/turret.cc 461 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT turret.o -MD -MP -MF "$(DEPDIR)/turret.Tpo" -c -o turret.o `test -f 'weapons/turret.cc' || echo '$(srcdir)/'`weapons/turret.cc; \ 462 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/turret.Tpo" "$(DEPDIR)/turret.Po"; else rm -f "$(DEPDIR)/turret.Tpo"; exit 1; fi 463 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/turret.cc' object='turret.o' libtool=no @AMDEPBACKSLASH@ 464 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/turret.Po' tmpdepfile='$(DEPDIR)/turret.TPo' @AMDEPBACKSLASH@ 465 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 466 @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o turret.o `test -f 'weapons/turret.cc' || echo '$(srcdir)/'`weapons/turret.cc 467 468 turret.obj: weapons/turret.cc 469 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT turret.obj -MD -MP -MF "$(DEPDIR)/turret.Tpo" -c -o turret.obj `if test -f 'weapons/turret.cc'; then $(CYGPATH_W) 'weapons/turret.cc'; else $(CYGPATH_W) '$(srcdir)/weapons/turret.cc'; fi`; \ 470 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/turret.Tpo" "$(DEPDIR)/turret.Po"; else rm -f "$(DEPDIR)/turret.Tpo"; exit 1; fi 471 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/turret.cc' object='turret.obj' libtool=no @AMDEPBACKSLASH@ 472 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/turret.Po' tmpdepfile='$(DEPDIR)/turret.TPo' @AMDEPBACKSLASH@ 473 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 474 @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o turret.obj `if test -f 'weapons/turret.cc'; then $(CYGPATH_W) 'weapons/turret.cc'; else $(CYGPATH_W) '$(srcdir)/weapons/turret.cc'; fi` 475 476 turret.lo: weapons/turret.cc 477 @am__fastdepCXX_TRUE@ if $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT turret.lo -MD -MP -MF "$(DEPDIR)/turret.Tpo" -c -o turret.lo `test -f 'weapons/turret.cc' || echo '$(srcdir)/'`weapons/turret.cc; \ 478 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/turret.Tpo" "$(DEPDIR)/turret.Plo"; else rm -f "$(DEPDIR)/turret.Tpo"; exit 1; fi 479 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/turret.cc' object='turret.lo' libtool=yes @AMDEPBACKSLASH@ 480 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/turret.Plo' tmpdepfile='$(DEPDIR)/turret.TPlo' @AMDEPBACKSLASH@ 481 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 482 @am__fastdepCXX_FALSE@ $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o turret.lo `test -f 'weapons/turret.cc' || echo '$(srcdir)/'`weapons/turret.cc 483 432 484 projectile.o: weapons/projectile.cc 433 485 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT projectile.o -MD -MP -MF "$(DEPDIR)/projectile.Tpo" -c -o projectile.o `test -f 'weapons/projectile.cc' || echo '$(srcdir)/'`weapons/projectile.cc; \ … … 454 506 @am__fastdepCXX_FALSE@ $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o projectile.lo `test -f 'weapons/projectile.cc' || echo '$(srcdir)/'`weapons/projectile.cc 455 507 456 test_gun.o: weapons/test_gun.cc457 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_gun.o -MD -MP -MF "$(DEPDIR)/test_gun.Tpo" -c -o test_gun.o `test -f 'weapons/test_gun.cc' || echo '$(srcdir)/'`weapons/test_gun.cc; \458 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/test_gun.Tpo" "$(DEPDIR)/test_gun.Po"; else rm -f "$(DEPDIR)/test_gun.Tpo"; exit 1; fi459 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/test_gun.cc' object='test_gun.o' libtool=no @AMDEPBACKSLASH@460 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/test_gun.Po' tmpdepfile='$(DEPDIR)/test_gun.TPo' @AMDEPBACKSLASH@461 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@462 @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_gun.o `test -f 'weapons/test_gun.cc' || echo '$(srcdir)/'`weapons/test_gun.cc463 464 test_gun.obj: weapons/test_gun.cc465 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_gun.obj -MD -MP -MF "$(DEPDIR)/test_gun.Tpo" -c -o test_gun.obj `if test -f 'weapons/test_gun.cc'; then $(CYGPATH_W) 'weapons/test_gun.cc'; else $(CYGPATH_W) '$(srcdir)/weapons/test_gun.cc'; fi`; \466 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/test_gun.Tpo" "$(DEPDIR)/test_gun.Po"; else rm -f "$(DEPDIR)/test_gun.Tpo"; exit 1; fi467 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/test_gun.cc' object='test_gun.obj' libtool=no @AMDEPBACKSLASH@468 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/test_gun.Po' tmpdepfile='$(DEPDIR)/test_gun.TPo' @AMDEPBACKSLASH@469 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@470 @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_gun.obj `if test -f 'weapons/test_gun.cc'; then $(CYGPATH_W) 'weapons/test_gun.cc'; else $(CYGPATH_W) '$(srcdir)/weapons/test_gun.cc'; fi`471 472 test_gun.lo: weapons/test_gun.cc473 @am__fastdepCXX_TRUE@ if $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_gun.lo -MD -MP -MF "$(DEPDIR)/test_gun.Tpo" -c -o test_gun.lo `test -f 'weapons/test_gun.cc' || echo '$(srcdir)/'`weapons/test_gun.cc; \474 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/test_gun.Tpo" "$(DEPDIR)/test_gun.Plo"; else rm -f "$(DEPDIR)/test_gun.Tpo"; exit 1; fi475 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/test_gun.cc' object='test_gun.lo' libtool=yes @AMDEPBACKSLASH@476 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/test_gun.Plo' tmpdepfile='$(DEPDIR)/test_gun.TPlo' @AMDEPBACKSLASH@477 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@478 @am__fastdepCXX_FALSE@ $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_gun.lo `test -f 'weapons/test_gun.cc' || echo '$(srcdir)/'`weapons/test_gun.cc479 480 turret.o: weapons/turret.cc481 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT turret.o -MD -MP -MF "$(DEPDIR)/turret.Tpo" -c -o turret.o `test -f 'weapons/turret.cc' || echo '$(srcdir)/'`weapons/turret.cc; \482 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/turret.Tpo" "$(DEPDIR)/turret.Po"; else rm -f "$(DEPDIR)/turret.Tpo"; exit 1; fi483 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/turret.cc' object='turret.o' libtool=no @AMDEPBACKSLASH@484 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/turret.Po' tmpdepfile='$(DEPDIR)/turret.TPo' @AMDEPBACKSLASH@485 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@486 @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o turret.o `test -f 'weapons/turret.cc' || echo '$(srcdir)/'`weapons/turret.cc487 488 turret.obj: weapons/turret.cc489 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT turret.obj -MD -MP -MF "$(DEPDIR)/turret.Tpo" -c -o turret.obj `if test -f 'weapons/turret.cc'; then $(CYGPATH_W) 'weapons/turret.cc'; else $(CYGPATH_W) '$(srcdir)/weapons/turret.cc'; fi`; \490 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/turret.Tpo" "$(DEPDIR)/turret.Po"; else rm -f "$(DEPDIR)/turret.Tpo"; exit 1; fi491 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/turret.cc' object='turret.obj' libtool=no @AMDEPBACKSLASH@492 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/turret.Po' tmpdepfile='$(DEPDIR)/turret.TPo' @AMDEPBACKSLASH@493 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@494 @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o turret.obj `if test -f 'weapons/turret.cc'; then $(CYGPATH_W) 'weapons/turret.cc'; else $(CYGPATH_W) '$(srcdir)/weapons/turret.cc'; fi`495 496 turret.lo: weapons/turret.cc497 @am__fastdepCXX_TRUE@ if $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT turret.lo -MD -MP -MF "$(DEPDIR)/turret.Tpo" -c -o turret.lo `test -f 'weapons/turret.cc' || echo '$(srcdir)/'`weapons/turret.cc; \498 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/turret.Tpo" "$(DEPDIR)/turret.Plo"; else rm -f "$(DEPDIR)/turret.Tpo"; exit 1; fi499 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/turret.cc' object='turret.lo' libtool=yes @AMDEPBACKSLASH@500 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/turret.Plo' tmpdepfile='$(DEPDIR)/turret.TPlo' @AMDEPBACKSLASH@501 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@502 @am__fastdepCXX_FALSE@ $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o turret.lo `test -f 'weapons/turret.cc' || echo '$(srcdir)/'`weapons/turret.cc503 504 508 test_bullet.o: weapons/test_bullet.cc 505 509 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_bullet.o -MD -MP -MF "$(DEPDIR)/test_bullet.Tpo" -c -o test_bullet.o `test -f 'weapons/test_bullet.cc' || echo '$(srcdir)/'`weapons/test_bullet.cc; \ … … 525 529 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 526 530 @am__fastdepCXX_FALSE@ $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_bullet.lo `test -f 'weapons/test_bullet.cc' || echo '$(srcdir)/'`weapons/test_bullet.cc 531 532 rocket.o: weapons/rocket.cc 533 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT rocket.o -MD -MP -MF "$(DEPDIR)/rocket.Tpo" -c -o rocket.o `test -f 'weapons/rocket.cc' || echo '$(srcdir)/'`weapons/rocket.cc; \ 534 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/rocket.Tpo" "$(DEPDIR)/rocket.Po"; else rm -f "$(DEPDIR)/rocket.Tpo"; exit 1; fi 535 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/rocket.cc' object='rocket.o' libtool=no @AMDEPBACKSLASH@ 536 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/rocket.Po' tmpdepfile='$(DEPDIR)/rocket.TPo' @AMDEPBACKSLASH@ 537 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 538 @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o rocket.o `test -f 'weapons/rocket.cc' || echo '$(srcdir)/'`weapons/rocket.cc 539 540 rocket.obj: weapons/rocket.cc 541 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT rocket.obj -MD -MP -MF "$(DEPDIR)/rocket.Tpo" -c -o rocket.obj `if test -f 'weapons/rocket.cc'; then $(CYGPATH_W) 'weapons/rocket.cc'; else $(CYGPATH_W) '$(srcdir)/weapons/rocket.cc'; fi`; \ 542 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/rocket.Tpo" "$(DEPDIR)/rocket.Po"; else rm -f "$(DEPDIR)/rocket.Tpo"; exit 1; fi 543 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/rocket.cc' object='rocket.obj' libtool=no @AMDEPBACKSLASH@ 544 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/rocket.Po' tmpdepfile='$(DEPDIR)/rocket.TPo' @AMDEPBACKSLASH@ 545 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 546 @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o rocket.obj `if test -f 'weapons/rocket.cc'; then $(CYGPATH_W) 'weapons/rocket.cc'; else $(CYGPATH_W) '$(srcdir)/weapons/rocket.cc'; fi` 547 548 rocket.lo: weapons/rocket.cc 549 @am__fastdepCXX_TRUE@ if $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT rocket.lo -MD -MP -MF "$(DEPDIR)/rocket.Tpo" -c -o rocket.lo `test -f 'weapons/rocket.cc' || echo '$(srcdir)/'`weapons/rocket.cc; \ 550 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/rocket.Tpo" "$(DEPDIR)/rocket.Plo"; else rm -f "$(DEPDIR)/rocket.Tpo"; exit 1; fi 551 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/rocket.cc' object='rocket.lo' libtool=yes @AMDEPBACKSLASH@ 552 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/rocket.Plo' tmpdepfile='$(DEPDIR)/rocket.TPlo' @AMDEPBACKSLASH@ 553 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 554 @am__fastdepCXX_FALSE@ $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o rocket.lo `test -f 'weapons/rocket.cc' || echo '$(srcdir)/'`weapons/rocket.cc 555 556 laser.o: weapons/laser.cc 557 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT laser.o -MD -MP -MF "$(DEPDIR)/laser.Tpo" -c -o laser.o `test -f 'weapons/laser.cc' || echo '$(srcdir)/'`weapons/laser.cc; \ 558 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/laser.Tpo" "$(DEPDIR)/laser.Po"; else rm -f "$(DEPDIR)/laser.Tpo"; exit 1; fi 559 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/laser.cc' object='laser.o' libtool=no @AMDEPBACKSLASH@ 560 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/laser.Po' tmpdepfile='$(DEPDIR)/laser.TPo' @AMDEPBACKSLASH@ 561 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 562 @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o laser.o `test -f 'weapons/laser.cc' || echo '$(srcdir)/'`weapons/laser.cc 563 564 laser.obj: weapons/laser.cc 565 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT laser.obj -MD -MP -MF "$(DEPDIR)/laser.Tpo" -c -o laser.obj `if test -f 'weapons/laser.cc'; then $(CYGPATH_W) 'weapons/laser.cc'; else $(CYGPATH_W) '$(srcdir)/weapons/laser.cc'; fi`; \ 566 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/laser.Tpo" "$(DEPDIR)/laser.Po"; else rm -f "$(DEPDIR)/laser.Tpo"; exit 1; fi 567 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/laser.cc' object='laser.obj' libtool=no @AMDEPBACKSLASH@ 568 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/laser.Po' tmpdepfile='$(DEPDIR)/laser.TPo' @AMDEPBACKSLASH@ 569 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 570 @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o laser.obj `if test -f 'weapons/laser.cc'; then $(CYGPATH_W) 'weapons/laser.cc'; else $(CYGPATH_W) '$(srcdir)/weapons/laser.cc'; fi` 571 572 laser.lo: weapons/laser.cc 573 @am__fastdepCXX_TRUE@ if $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT laser.lo -MD -MP -MF "$(DEPDIR)/laser.Tpo" -c -o laser.lo `test -f 'weapons/laser.cc' || echo '$(srcdir)/'`weapons/laser.cc; \ 574 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/laser.Tpo" "$(DEPDIR)/laser.Plo"; else rm -f "$(DEPDIR)/laser.Tpo"; exit 1; fi 575 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='weapons/laser.cc' object='laser.lo' libtool=yes @AMDEPBACKSLASH@ 576 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/laser.Plo' tmpdepfile='$(DEPDIR)/laser.TPlo' @AMDEPBACKSLASH@ 577 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 578 @am__fastdepCXX_FALSE@ $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o laser.lo `test -f 'weapons/laser.cc' || echo '$(srcdir)/'`weapons/laser.cc 527 579 528 580 crosshair.o: weapons/crosshair.cc -
trunk/src/world_entities/weapons/laser.cc
r5451 r5456 16 16 #define DEBUG_SPECIAL_MODULE DEBUG_MODULE_WEAPON 17 17 18 #include " test_bullet.h"18 #include "laser.h" 19 19 20 20 #include "fast_factory.h" … … 31 31 using namespace std; 32 32 33 CREATE_FAST_FACTORY_STATIC( TestBullet, CL_TEST_BULLET);33 CREATE_FAST_FACTORY_STATIC(Laser, CL_LASER); 34 34 35 35 /** 36 36 * standard constructor 37 37 */ 38 TestBullet::TestBullet() : Projectile()38 Laser::Laser () : Projectile() 39 39 { 40 this->setClassID(CL_TEST_BULLET, " TestBullet");40 this->setClassID(CL_TEST_BULLET, "Laser"); 41 41 42 42 float modelSize = .3; 43 this->loadModelWithScale("models/projectiles/ orx-rocket.obj", .3);43 this->loadModelWithScale("models/projectiles/lasers.obj", .3); 44 44 45 45 this->energyMin = 1; … … 51 51 this->emitter->setParent(this); 52 52 this->emitter->setSpread(M_PI, M_PI); 53 this->emitter->setEmissionRate(30.0); 54 this->emitter->setEmissionVelocity(50.0); 53 55 } 54 56 … … 57 59 * standard deconstructor 58 60 */ 59 TestBullet::~TestBullet()61 Laser::~Laser () 60 62 { 61 63 // delete this->emitter; 62 64 63 65 /* this is normaly done by World.cc by deleting the ParticleEngine */ 64 if ( TestBullet::trailParticles != NULL && ClassList::getList(CL_TEST_BULLET)->getSize() <= 1)66 if (Laser::explosionParticles != NULL && ClassList::getList(CL_TEST_BULLET)->getSize() <= 1) 65 67 { 66 if (ClassList::exists(TestBullet::trailParticles, CL_PARTICLE_SYSTEM)) 67 delete TestBullet::trailParticles; 68 TestBullet::trailParticles = NULL; 69 } 70 if (TestBullet::explosionParticles != NULL && ClassList::getList(CL_TEST_BULLET)->getSize() <= 1) 71 { 72 if (ClassList::exists(TestBullet::explosionParticles, CL_PARTICLE_SYSTEM)) 73 delete TestBullet::explosionParticles; 74 TestBullet::explosionParticles = NULL; 68 if (ClassList::exists(Laser::explosionParticles, CL_PARTICLE_SYSTEM)) 69 delete Laser::explosionParticles; 70 Laser::explosionParticles = NULL; 75 71 } 76 72 77 73 } 78 74 79 ParticleSystem* TestBullet::trailParticles = NULL; 80 ParticleSystem* TestBullet::explosionParticles = NULL; 75 ParticleSystem* Laser::explosionParticles = NULL; 81 76 82 void TestBullet::activate()77 void Laser::activate() 83 78 { 84 79 State::getWorldEntityList()->add(this); 85 if (unlikely( TestBullet::trailParticles == NULL))80 if (unlikely(Laser::explosionParticles == NULL)) 86 81 { 87 TestBullet::trailParticles = new ParticleSystem(1000, PARTICLE_SPRITE);88 TestBullet::trailParticles->setName("TestBulletTrailParticles");89 TestBullet::trailParticles->setLifeSpan(.5, .3);90 TestBullet::trailParticles->setRadius(0.0, .5);91 TestBullet::trailParticles->setRadius(0.5, 2.0);92 TestBullet::trailParticles->setRadius(1.0, 5.0);93 TestBullet::trailParticles->setColor(0.0, 1,0,0,.7);94 TestBullet::trailParticles->setColor(0.5, .8,.8,0,.5);95 TestBullet::trailParticles->setColor(1.0, .7,.7,.7,.0);82 Laser::explosionParticles = new ParticleSystem(1000, PARTICLE_SPRITE); 83 Laser::explosionParticles->setName("LaserExplosionParticles"); 84 Laser::explosionParticles->setLifeSpan(.5, .3); 85 Laser::explosionParticles->setRadius(0.0, 10); 86 Laser::explosionParticles->setRadius(.5, 20.0); 87 Laser::explosionParticles->setRadius(1.0, 3.0); 88 Laser::explosionParticles->setColor(0.0, 0,1,0,.9); 89 Laser::explosionParticles->setColor(0.5, .8,.8,0,.5); 90 Laser::explosionParticles->setColor(1.0, 1,1,1,.0); 96 91 } 97 if (unlikely(TestBullet::explosionParticles == NULL))98 {99 TestBullet::explosionParticles = new ParticleSystem(1000, PARTICLE_SPRITE);100 TestBullet::explosionParticles->setName("TestBulletExplosionParticles");101 TestBullet::explosionParticles->setLifeSpan(.5, .3);102 TestBullet::explosionParticles->setRadius(0.0, 10);103 TestBullet::explosionParticles->setRadius(.5, 20.0);104 TestBullet::explosionParticles->setRadius(1.0, 3.0);105 TestBullet::explosionParticles->setColor(0.0, 0,1,0,.9);106 TestBullet::explosionParticles->setColor(0.5, .8,.8,0,.5);107 TestBullet::explosionParticles->setColor(1.0, 1,1,1,.0);108 }109 110 ParticleEngine::getInstance()->addConnection(this->emitter, TestBullet::trailParticles);111 112 this->emitter->setEmissionRate(20.0);113 this->emitter->setEmissionVelocity(3.0);114 92 } 115 93 116 94 117 void TestBullet::deactivate()95 void Laser::deactivate() 118 96 { 119 97 ParticleEngine::getInstance()->breakConnections(this->emitter); … … 122 100 // GarbageCollector::getInstance()->collect(this); 123 101 State::getWorldEntityList()->remove(this); 124 TestBullet::fastFactory->kill(this);102 Laser::fastFactory->kill(this); 125 103 } 126 104 127 105 128 void TestBullet::collidesWith(WorldEntity* entity, const Vector& location)106 void Laser::collidesWith(WorldEntity* entity, const Vector& location) 129 107 { 130 108 if (this->hitEntity != entity && entity->isA(CL_NPC)) … … 137 115 * @param time since last tick 138 116 */ 139 void TestBullet::tick (float time)117 void Laser::tick (float time) 140 118 { 141 119 //Vector v = *this->flightDirection * ( this->speed * time * 1000 + 0.1); … … 157 135 * the function gets called, when the projectile is destroyed 158 136 */ 159 void TestBullet::destroy ()137 void Laser::destroy () 160 138 { 161 PRINTF(5)("DESTROY TestBullet\n");139 PRINTF(5)("DESTROY Laser\n"); 162 140 this->lifeCycle = .95; //!< @todo calculate this usefully. 163 ParticleEngine::getInstance()->breakConnection(this->emitter, TestBullet::trailParticles); 164 ParticleEngine::getInstance()->addConnection(this->emitter, TestBullet::explosionParticles); 165 166 this->emitter->setEmissionRate(30.0); 167 this->emitter->setEmissionVelocity(50.0); 168 // this->deactivate(); 141 ParticleEngine::getInstance()->addConnection(this->emitter, Laser::explosionParticles); 169 142 170 143 } 171 144 172 145 173 void TestBullet::draw ()146 void Laser::draw () 174 147 { 175 148 glMatrixMode(GL_MODELVIEW); -
trunk/src/world_entities/weapons/laser.h
r5449 r5456 1 1 /*! 2 \projectile.h3 *a projectile, that is been shooted by a weapon2 * @file laser.h 3 * @brief a projectile, that is been shooted by a weapon 4 4 */ 5 5 6 #ifndef _ TEST_BULLET_H7 #define _ TEST_BULLET_H6 #ifndef _LASER_H 7 #define _LASER_H 8 8 9 9 #include "projectile.h" … … 15 15 class FastFactory; 16 16 17 class TestBullet: public Projectile17 class Laser : public Projectile 18 18 { 19 19 public: 20 TestBullet();21 virtual ~ TestBullet();20 Laser (); 21 virtual ~Laser (); 22 22 23 23 … … 35 35 private: 36 36 static FastFactory* fastFactory; 37 static ParticleSystem* trailParticles; 37 38 38 static ParticleSystem* explosionParticles; 39 39 … … 45 45 }; 46 46 47 #endif /* _ TEST_BULLET_H */47 #endif /* _LASER_H */ -
trunk/src/world_entities/weapons/rocket.cc
r5451 r5456 16 16 #define DEBUG_SPECIAL_MODULE DEBUG_MODULE_WEAPON 17 17 18 #include " test_bullet.h"18 #include "rocket.h" 19 19 20 20 #include "fast_factory.h" … … 31 31 using namespace std; 32 32 33 CREATE_FAST_FACTORY_STATIC( TestBullet, CL_TEST_BULLET);33 CREATE_FAST_FACTORY_STATIC(Rocket, CL_ROCKET); 34 34 35 35 /** 36 36 * standard constructor 37 37 */ 38 TestBullet::TestBullet () : Projectile()38 Rocket::Rocket () : Projectile() 39 39 { 40 this->setClassID(CL_TEST_BULLET, " TestBullet");40 this->setClassID(CL_TEST_BULLET, "Rocket"); 41 41 42 42 float modelSize = .3; … … 57 57 * standard deconstructor 58 58 */ 59 TestBullet::~TestBullet ()59 Rocket::~Rocket () 60 60 { 61 61 // delete this->emitter; 62 62 63 63 /* this is normaly done by World.cc by deleting the ParticleEngine */ 64 if ( TestBullet::trailParticles != NULL && ClassList::getList(CL_TEST_BULLET)->getSize() <= 1)64 if (Rocket::trailParticles != NULL && ClassList::getList(CL_TEST_BULLET)->getSize() <= 1) 65 65 { 66 if (ClassList::exists( TestBullet::trailParticles, CL_PARTICLE_SYSTEM))67 delete TestBullet::trailParticles;68 TestBullet::trailParticles = NULL;66 if (ClassList::exists(Rocket::trailParticles, CL_PARTICLE_SYSTEM)) 67 delete Rocket::trailParticles; 68 Rocket::trailParticles = NULL; 69 69 } 70 if ( TestBullet::explosionParticles != NULL && ClassList::getList(CL_TEST_BULLET)->getSize() <= 1)70 if (Rocket::explosionParticles != NULL && ClassList::getList(CL_TEST_BULLET)->getSize() <= 1) 71 71 { 72 if (ClassList::exists( TestBullet::explosionParticles, CL_PARTICLE_SYSTEM))73 delete TestBullet::explosionParticles;74 TestBullet::explosionParticles = NULL;72 if (ClassList::exists(Rocket::explosionParticles, CL_PARTICLE_SYSTEM)) 73 delete Rocket::explosionParticles; 74 Rocket::explosionParticles = NULL; 75 75 } 76 76 77 77 } 78 78 79 ParticleSystem* TestBullet::trailParticles = NULL;80 ParticleSystem* TestBullet::explosionParticles = NULL;79 ParticleSystem* Rocket::trailParticles = NULL; 80 ParticleSystem* Rocket::explosionParticles = NULL; 81 81 82 void TestBullet::activate()82 void Rocket::activate() 83 83 { 84 84 State::getWorldEntityList()->add(this); 85 if (unlikely( TestBullet::trailParticles == NULL))85 if (unlikely(Rocket::trailParticles == NULL)) 86 86 { 87 TestBullet::trailParticles = new ParticleSystem(1000, PARTICLE_SPRITE);88 TestBullet::trailParticles->setName("TestBulletTrailParticles");89 TestBullet::trailParticles->setLifeSpan(.5, .3);90 TestBullet::trailParticles->setRadius(0.0, .5);91 TestBullet::trailParticles->setRadius(0.5, 2.0);92 TestBullet::trailParticles->setRadius(1.0, 5.0);93 TestBullet::trailParticles->setColor(0.0, 1,0,0,.7);94 TestBullet::trailParticles->setColor(0.5, .8,.8,0,.5);95 TestBullet::trailParticles->setColor(1.0, .7,.7,.7,.0);87 Rocket::trailParticles = new ParticleSystem(1000, PARTICLE_SPRITE); 88 Rocket::trailParticles->setName("RocketTrailParticles"); 89 Rocket::trailParticles->setLifeSpan(.5, .3); 90 Rocket::trailParticles->setRadius(0.0, .5); 91 Rocket::trailParticles->setRadius(0.5, 2.0); 92 Rocket::trailParticles->setRadius(1.0, 5.0); 93 Rocket::trailParticles->setColor(0.0, 1,0,0,.7); 94 Rocket::trailParticles->setColor(0.5, .8,.8,0,.5); 95 Rocket::trailParticles->setColor(1.0, .7,.7,.7,.0); 96 96 } 97 if (unlikely( TestBullet::explosionParticles == NULL))97 if (unlikely(Rocket::explosionParticles == NULL)) 98 98 { 99 TestBullet::explosionParticles = new ParticleSystem(1000, PARTICLE_SPRITE);100 TestBullet::explosionParticles->setName("TestBulletExplosionParticles");101 TestBullet::explosionParticles->setLifeSpan(.5, .3);102 TestBullet::explosionParticles->setRadius(0.0, 10);103 TestBullet::explosionParticles->setRadius(.5, 20.0);104 TestBullet::explosionParticles->setRadius(1.0, 3.0);105 TestBullet::explosionParticles->setColor(0.0, 0,1,0,.9);106 TestBullet::explosionParticles->setColor(0.5, .8,.8,0,.5);107 TestBullet::explosionParticles->setColor(1.0, 1,1,1,.0);99 Rocket::explosionParticles = new ParticleSystem(1000, PARTICLE_SPRITE); 100 Rocket::explosionParticles->setName("RocketExplosionParticles"); 101 Rocket::explosionParticles->setLifeSpan(.5, .3); 102 Rocket::explosionParticles->setRadius(0.0, 10); 103 Rocket::explosionParticles->setRadius(.5, 20.0); 104 Rocket::explosionParticles->setRadius(1.0, 3.0); 105 Rocket::explosionParticles->setColor(0.0, 0,1,0,.9); 106 Rocket::explosionParticles->setColor(0.5, .8,.8,0,.5); 107 Rocket::explosionParticles->setColor(1.0, 1,1,1,.0); 108 108 } 109 109 110 ParticleEngine::getInstance()->addConnection(this->emitter, TestBullet::trailParticles);110 ParticleEngine::getInstance()->addConnection(this->emitter, Rocket::trailParticles); 111 111 112 112 this->emitter->setEmissionRate(20.0); … … 115 115 116 116 117 void TestBullet::deactivate()117 void Rocket::deactivate() 118 118 { 119 119 ParticleEngine::getInstance()->breakConnections(this->emitter); … … 122 122 // GarbageCollector::getInstance()->collect(this); 123 123 State::getWorldEntityList()->remove(this); 124 TestBullet::fastFactory->kill(this);124 Rocket::fastFactory->kill(this); 125 125 } 126 126 127 127 128 void TestBullet::collidesWith(WorldEntity* entity, const Vector& location)128 void Rocket::collidesWith(WorldEntity* entity, const Vector& location) 129 129 { 130 130 if (this->hitEntity != entity && entity->isA(CL_NPC)) … … 137 137 * @param time since last tick 138 138 */ 139 void TestBullet::tick (float time)139 void Rocket::tick (float time) 140 140 { 141 141 //Vector v = *this->flightDirection * ( this->speed * time * 1000 + 0.1); … … 157 157 * the function gets called, when the projectile is destroyed 158 158 */ 159 void TestBullet::destroy ()159 void Rocket::destroy () 160 160 { 161 PRINTF(5)("DESTROY TestBullet\n");161 PRINTF(5)("DESTROY Rocket\n"); 162 162 this->lifeCycle = .95; //!< @todo calculate this usefully. 163 ParticleEngine::getInstance()->breakConnection(this->emitter, TestBullet::trailParticles);164 ParticleEngine::getInstance()->addConnection(this->emitter, TestBullet::explosionParticles);163 ParticleEngine::getInstance()->breakConnection(this->emitter, Rocket::trailParticles); 164 ParticleEngine::getInstance()->addConnection(this->emitter, Rocket::explosionParticles); 165 165 166 166 this->emitter->setEmissionRate(30.0); … … 171 171 172 172 173 void TestBullet::draw ()173 void Rocket::draw () 174 174 { 175 175 glMatrixMode(GL_MODELVIEW); -
trunk/src/world_entities/weapons/rocket.h
r5449 r5456 1 1 /*! 2 \projectile.h3 * a projectile, that is been shooted by a weapon2 * @file rocket.h 3 * @brief a Rocket Projectile 4 4 */ 5 5 6 #ifndef _ TEST_BULLET_H7 #define _ TEST_BULLET_H6 #ifndef _ROCKET_H 7 #define _ROCKET_H 8 8 9 9 #include "projectile.h" … … 15 15 class FastFactory; 16 16 17 class TestBullet : public Projectile17 class Rocket : public Projectile 18 18 { 19 19 public: 20 TestBullet ();21 virtual ~ TestBullet ();20 Rocket (); 21 virtual ~Rocket (); 22 22 23 23 … … 45 45 }; 46 46 47 #endif /* _ TEST_BULLET_H */47 #endif /* _ROCKET_H */ -
trunk/src/world_entities/weapons/test_gun.cc
r5443 r5456 134 134 135 135 this->setCapability(WTYPE_ALLDIRS | WTYPE_DIRECTIONAL); 136 this->setProjectileType(CL_ TEST_BULLET);136 this->setProjectileType(CL_LASER); 137 137 this->prepareProjectiles(20); 138 138 } -
trunk/src/world_entities/weapons/turret.cc
r5443 r5456 92 92 93 93 this->setCapability(WTYPE_ALLDIRS | WTYPE_TURRET); 94 this->setProjectileType(CL_ TEST_BULLET);94 this->setProjectileType(CL_ROCKET); 95 95 96 96
Note: See TracChangeset
for help on using the changeset viewer.