Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 5456 in orxonox.OLD for trunk/src/world_entities


Ignore:
Timestamp:
Oct 30, 2005, 12:54:23 AM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: added Lasers and Rockets Class as TestBullet is not the best Name

Location:
trunk/src/world_entities
Files:
4 edited
4 copied

Legend:

Unmodified
Added
Removed
  • trunk/src/world_entities/Makefile.am

    r5450 r5456  
    1919                  weapons/weapon_manager.cc \
    2020                  weapons/weapon.cc \
    21                   weapons/projectile.cc \
    2221                  weapons/test_gun.cc \
    2322                  weapons/turret.cc \
     23                  weapons/projectile.cc \
    2424                  weapons/test_bullet.cc \
     25                  weapons/rocket.cc \
     26                  weapons/laser.cc \
    2527                  weapons/crosshair.cc \
    2628                  power_ups/power_up.cc \
  • trunk/src/world_entities/Makefile.in

    r5450 r5456  
    5656        player.lo npc.lo npc2.lo environment.lo skysphere.lo skybox.lo \
    5757        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.lo
     58        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
    6161libORXworld_entities_la_OBJECTS =  \
    6262        $(am_libORXworld_entities_la_OBJECTS)
     
    6767@AMDEP_TRUE@    ./$(DEPDIR)/character_attributes.Plo \
    6868@AMDEP_TRUE@    ./$(DEPDIR)/crosshair.Plo \
    69 @AMDEP_TRUE@    ./$(DEPDIR)/environment.Plo ./$(DEPDIR)/npc.Plo \
    70 @AMDEP_TRUE@    ./$(DEPDIR)/npc2.Plo ./$(DEPDIR)/player.Plo \
    71 @AMDEP_TRUE@    ./$(DEPDIR)/power_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 \
    7373@AMDEP_TRUE@    ./$(DEPDIR)/satellite.Plo ./$(DEPDIR)/skybox.Plo \
    7474@AMDEP_TRUE@    ./$(DEPDIR)/skysphere.Plo ./$(DEPDIR)/terrain.Plo \
     
    235235                  weapons/weapon_manager.cc \
    236236                  weapons/weapon.cc \
    237                   weapons/projectile.cc \
    238237                  weapons/test_gun.cc \
    239238                  weapons/turret.cc \
     239                  weapons/projectile.cc \
    240240                  weapons/test_bullet.cc \
     241                  weapons/rocket.cc \
     242                  weapons/laser.cc \
    241243                  weapons/crosshair.cc \
    242244                  power_ups/power_up.cc \
     
    340342@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/crosshair.Plo@am__quote@
    341343@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/environment.Plo@am__quote@
     344@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/laser.Plo@am__quote@
    342345@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/npc.Plo@am__quote@
    343346@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/npc2.Plo@am__quote@
     
    345348@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/power_up.Plo@am__quote@
    346349@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/projectile.Plo@am__quote@
     350@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rocket.Plo@am__quote@
    347351@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/satellite.Plo@am__quote@
    348352@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/skybox.Plo@am__quote@
     
    430434@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
    431435
     436test_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
     444test_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
     452test_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
     460turret.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
     468turret.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
     476turret.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
    432484projectile.o: weapons/projectile.cc
    433485@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; \
     
    454506@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
    455507
    456 test_gun.o: weapons/test_gun.cc
    457 @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; fi
    459 @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.cc
    463 
    464 test_gun.obj: weapons/test_gun.cc
    465 @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; fi
    467 @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.cc
    473 @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; fi
    475 @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.cc
    479 
    480 turret.o: weapons/turret.cc
    481 @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; fi
    483 @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.cc
    487 
    488 turret.obj: weapons/turret.cc
    489 @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; fi
    491 @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.cc
    497 @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; fi
    499 @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.cc
    503 
    504508test_bullet.o: weapons/test_bullet.cc
    505509@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; \
     
    525529@AMDEP_TRUE@@am__fastdepCXX_FALSE@      $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
    526530@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
     532rocket.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
     540rocket.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
     548rocket.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
     556laser.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
     564laser.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
     572laser.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
    527579
    528580crosshair.o: weapons/crosshair.cc
  • trunk/src/world_entities/weapons/laser.cc

    r5451 r5456  
    1616#define DEBUG_SPECIAL_MODULE DEBUG_MODULE_WEAPON
    1717
    18 #include "test_bullet.h"
     18#include "laser.h"
    1919
    2020#include "fast_factory.h"
     
    3131using namespace std;
    3232
    33 CREATE_FAST_FACTORY_STATIC(TestBullet, CL_TEST_BULLET);
     33CREATE_FAST_FACTORY_STATIC(Laser, CL_LASER);
    3434
    3535/**
    3636 *  standard constructor
    3737*/
    38 TestBullet::TestBullet () : Projectile()
     38Laser::Laser () : Projectile()
    3939{
    40   this->setClassID(CL_TEST_BULLET, "TestBullet");
     40  this->setClassID(CL_TEST_BULLET, "Laser");
    4141
    4242  float modelSize = .3;
    43   this->loadModelWithScale("models/projectiles/orx-rocket.obj", .3);
     43  this->loadModelWithScale("models/projectiles/lasers.obj", .3);
    4444
    4545  this->energyMin = 1;
     
    5151  this->emitter->setParent(this);
    5252  this->emitter->setSpread(M_PI, M_PI);
     53  this->emitter->setEmissionRate(30.0);
     54  this->emitter->setEmissionVelocity(50.0);
    5355}
    5456
     
    5759 *  standard deconstructor
    5860*/
    59 TestBullet::~TestBullet ()
     61Laser::~Laser ()
    6062{
    6163  // delete this->emitter;
    6264
    6365  /* 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)
    6567  {
    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;
    7571  }
    7672
    7773}
    7874
    79 ParticleSystem* TestBullet::trailParticles = NULL;
    80 ParticleSystem* TestBullet::explosionParticles = NULL;
     75ParticleSystem* Laser::explosionParticles = NULL;
    8176
    82 void TestBullet::activate()
     77void Laser::activate()
    8378{
    8479  State::getWorldEntityList()->add(this);
    85   if (unlikely(TestBullet::trailParticles == NULL))
     80  if (unlikely(Laser::explosionParticles == NULL))
    8681  {
    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);
    9691  }
    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);
    11492}
    11593
    11694
    117 void TestBullet::deactivate()
     95void Laser::deactivate()
    11896{
    11997  ParticleEngine::getInstance()->breakConnections(this->emitter);
     
    122100//  GarbageCollector::getInstance()->collect(this);
    123101  State::getWorldEntityList()->remove(this);
    124   TestBullet::fastFactory->kill(this);
     102  Laser::fastFactory->kill(this);
    125103}
    126104
    127105
    128 void TestBullet::collidesWith(WorldEntity* entity, const Vector& location)
     106void Laser::collidesWith(WorldEntity* entity, const Vector& location)
    129107{
    130108  if (this->hitEntity != entity && entity->isA(CL_NPC))
     
    137115 * @param time since last tick
    138116*/
    139 void TestBullet::tick (float time)
     117void Laser::tick (float time)
    140118{
    141119  //Vector v = *this->flightDirection * ( this->speed * time * 1000 + 0.1);
     
    157135 *  the function gets called, when the projectile is destroyed
    158136*/
    159 void TestBullet::destroy ()
     137void Laser::destroy ()
    160138{
    161   PRINTF(5)("DESTROY TestBullet\n");
     139  PRINTF(5)("DESTROY Laser\n");
    162140  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);
    169142
    170143}
    171144
    172145
    173 void TestBullet::draw ()
     146void Laser::draw ()
    174147{
    175148  glMatrixMode(GL_MODELVIEW);
  • trunk/src/world_entities/weapons/laser.h

    r5449 r5456  
    11/*!
    2     \projectile.h
    3   * a projectile, that is been shooted by a weapon
     2 * @file laser.h
     3 * @brief a projectile, that is been shooted by a weapon
    44*/
    55
    6 #ifndef _TEST_BULLET_H
    7 #define _TEST_BULLET_H
     6#ifndef _LASER_H
     7#define _LASER_H
    88
    99#include "projectile.h"
     
    1515class FastFactory;
    1616
    17 class TestBullet : public Projectile
     17class Laser : public Projectile
    1818{
    1919  public:
    20     TestBullet ();
    21     virtual ~TestBullet ();
     20    Laser ();
     21    virtual ~Laser ();
    2222
    2323
     
    3535  private:
    3636    static FastFactory*               fastFactory;
    37     static ParticleSystem*            trailParticles;
     37
    3838    static ParticleSystem*            explosionParticles;
    3939
     
    4545};
    4646
    47 #endif /* _TEST_BULLET_H */
     47#endif /* _LASER_H */
  • trunk/src/world_entities/weapons/rocket.cc

    r5451 r5456  
    1616#define DEBUG_SPECIAL_MODULE DEBUG_MODULE_WEAPON
    1717
    18 #include "test_bullet.h"
     18#include "rocket.h"
    1919
    2020#include "fast_factory.h"
     
    3131using namespace std;
    3232
    33 CREATE_FAST_FACTORY_STATIC(TestBullet, CL_TEST_BULLET);
     33CREATE_FAST_FACTORY_STATIC(Rocket, CL_ROCKET);
    3434
    3535/**
    3636 *  standard constructor
    3737*/
    38 TestBullet::TestBullet () : Projectile()
     38Rocket::Rocket () : Projectile()
    3939{
    40   this->setClassID(CL_TEST_BULLET, "TestBullet");
     40  this->setClassID(CL_TEST_BULLET, "Rocket");
    4141
    4242  float modelSize = .3;
     
    5757 *  standard deconstructor
    5858*/
    59 TestBullet::~TestBullet ()
     59Rocket::~Rocket ()
    6060{
    6161  // delete this->emitter;
    6262
    6363  /* 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)
    6565  {
    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;
    6969  }
    70   if (TestBullet::explosionParticles != NULL && ClassList::getList(CL_TEST_BULLET)->getSize() <= 1)
     70  if (Rocket::explosionParticles != NULL && ClassList::getList(CL_TEST_BULLET)->getSize() <= 1)
    7171  {
    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;
    7575  }
    7676
    7777}
    7878
    79 ParticleSystem* TestBullet::trailParticles = NULL;
    80 ParticleSystem* TestBullet::explosionParticles = NULL;
     79ParticleSystem* Rocket::trailParticles = NULL;
     80ParticleSystem* Rocket::explosionParticles = NULL;
    8181
    82 void TestBullet::activate()
     82void Rocket::activate()
    8383{
    8484  State::getWorldEntityList()->add(this);
    85   if (unlikely(TestBullet::trailParticles == NULL))
     85  if (unlikely(Rocket::trailParticles == NULL))
    8686  {
    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);
    9696  }
    97   if (unlikely(TestBullet::explosionParticles == NULL))
     97  if (unlikely(Rocket::explosionParticles == NULL))
    9898  {
    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);
    108108  }
    109109
    110   ParticleEngine::getInstance()->addConnection(this->emitter, TestBullet::trailParticles);
     110  ParticleEngine::getInstance()->addConnection(this->emitter, Rocket::trailParticles);
    111111
    112112  this->emitter->setEmissionRate(20.0);
     
    115115
    116116
    117 void TestBullet::deactivate()
     117void Rocket::deactivate()
    118118{
    119119  ParticleEngine::getInstance()->breakConnections(this->emitter);
     
    122122//  GarbageCollector::getInstance()->collect(this);
    123123  State::getWorldEntityList()->remove(this);
    124   TestBullet::fastFactory->kill(this);
     124  Rocket::fastFactory->kill(this);
    125125}
    126126
    127127
    128 void TestBullet::collidesWith(WorldEntity* entity, const Vector& location)
     128void Rocket::collidesWith(WorldEntity* entity, const Vector& location)
    129129{
    130130  if (this->hitEntity != entity && entity->isA(CL_NPC))
     
    137137 * @param time since last tick
    138138*/
    139 void TestBullet::tick (float time)
     139void Rocket::tick (float time)
    140140{
    141141  //Vector v = *this->flightDirection * ( this->speed * time * 1000 + 0.1);
     
    157157 *  the function gets called, when the projectile is destroyed
    158158*/
    159 void TestBullet::destroy ()
     159void Rocket::destroy ()
    160160{
    161   PRINTF(5)("DESTROY TestBullet\n");
     161  PRINTF(5)("DESTROY Rocket\n");
    162162  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);
    165165
    166166  this->emitter->setEmissionRate(30.0);
     
    171171
    172172
    173 void TestBullet::draw ()
     173void Rocket::draw ()
    174174{
    175175  glMatrixMode(GL_MODELVIEW);
  • trunk/src/world_entities/weapons/rocket.h

    r5449 r5456  
    11/*!
    2     \projectile.h
    3   *  a projectile, that is been shooted by a weapon
     2 * @file rocket.h
     3 * @brief a Rocket Projectile
    44*/
    55
    6 #ifndef _TEST_BULLET_H
    7 #define _TEST_BULLET_H
     6#ifndef _ROCKET_H
     7#define _ROCKET_H
    88
    99#include "projectile.h"
     
    1515class FastFactory;
    1616
    17 class TestBullet : public Projectile
     17class Rocket : public Projectile
    1818{
    1919  public:
    20     TestBullet ();
    21     virtual ~TestBullet ();
     20    Rocket ();
     21    virtual ~Rocket ();
    2222
    2323
     
    4545};
    4646
    47 #endif /* _TEST_BULLET_H */
     47#endif /* _ROCKET_H */
  • trunk/src/world_entities/weapons/test_gun.cc

    r5443 r5456  
    134134
    135135  this->setCapability(WTYPE_ALLDIRS | WTYPE_DIRECTIONAL);
    136   this->setProjectileType(CL_TEST_BULLET);
     136  this->setProjectileType(CL_LASER);
    137137  this->prepareProjectiles(20);
    138138}
  • trunk/src/world_entities/weapons/turret.cc

    r5443 r5456  
    9292
    9393  this->setCapability(WTYPE_ALLDIRS | WTYPE_TURRET);
    94   this->setProjectileType(CL_TEST_BULLET);
     94  this->setProjectileType(CL_ROCKET);
    9595
    9696
Note: See TracChangeset for help on using the changeset viewer.