Index: orxonox/trunk/src/Makefile.am
===================================================================
--- orxonox/trunk/src/Makefile.am	(revision 4756)
+++ orxonox/trunk/src/Makefile.am	(revision 4758)
@@ -54,11 +54,11 @@
                   world_entities/skybox.cc \
                   world_entities/terrain.cc \
-                  world_entities/weapon.cc \
-                  world_entities/projectile.cc \
                   world_entities/satellite.cc \
                   world_entities/character_attributes.cc \
-                  world_entities/test_gun.cc \
-                  world_entities/test_bullet.cc \
                   world_entities/test_entity.cc \
+                  world_entities/weapons/weapon.cc \
+                  world_entities/weapons/projectile.cc \
+                  world_entities/weapons/test_gun.cc \
+                  world_entities/weapons/test_bullet.cc \
                   lib/coord/p_node.cc \
                   lib/coord/null_parent.cc \
@@ -67,5 +67,5 @@
                   lib/graphics/text_engine.cc \
                   lib/lang/base_object.cc \
-		  lib/lang/class_list.cc \
+                  lib/lang/class_list.cc \
                   lib/util/ini_parser.cc \
                   lib/util/substring.cc \
@@ -105,11 +105,11 @@
                  world_entities/power_up.h \
                  world_entities/terrain.h \
-                 world_entities/weapon.h \
-                 world_entities/projectile.h \
                  world_entities/satellite.h \
                  world_entities/character_attributes.h \
-                 world_entities/test_gun.h \
-                 world_entities/test_bullet.h \
                  world_entities/test_entity.h \
+                 world_entities/weapons/weapon.h \
+                 world_entities/weapons/projectile.h \
+                 world_entities/weapons/test_gun.h \
+                 world_entities/weapons/test_bullet.h \
                  defs/stdincl.h \
                  defs/stdlibincl.h \
Index: orxonox/trunk/src/Makefile.in
===================================================================
--- orxonox/trunk/src/Makefile.in	(revision 4756)
+++ orxonox/trunk/src/Makefile.in	(revision 4758)
@@ -67,9 +67,9 @@
 	orxonox-environment.$(OBJEXT) orxonox-skysphere.$(OBJEXT) \
 	orxonox-skybox.$(OBJEXT) orxonox-terrain.$(OBJEXT) \
-	orxonox-weapon.$(OBJEXT) orxonox-projectile.$(OBJEXT) \
 	orxonox-satellite.$(OBJEXT) \
 	orxonox-character_attributes.$(OBJEXT) \
-	orxonox-test_gun.$(OBJEXT) orxonox-test_bullet.$(OBJEXT) \
-	orxonox-test_entity.$(OBJEXT) orxonox-p_node.$(OBJEXT) \
+	orxonox-test_entity.$(OBJEXT) orxonox-weapon.$(OBJEXT) \
+	orxonox-projectile.$(OBJEXT) orxonox-test_gun.$(OBJEXT) \
+	orxonox-test_bullet.$(OBJEXT) orxonox-p_node.$(OBJEXT) \
 	orxonox-null_parent.$(OBJEXT) \
 	orxonox-graphics_engine.$(OBJEXT) orxonox-light.$(OBJEXT) \
@@ -299,11 +299,11 @@
                   world_entities/skybox.cc \
                   world_entities/terrain.cc \
-                  world_entities/weapon.cc \
-                  world_entities/projectile.cc \
                   world_entities/satellite.cc \
                   world_entities/character_attributes.cc \
-                  world_entities/test_gun.cc \
-                  world_entities/test_bullet.cc \
                   world_entities/test_entity.cc \
+                  world_entities/weapons/weapon.cc \
+                  world_entities/weapons/projectile.cc \
+                  world_entities/weapons/test_gun.cc \
+                  world_entities/weapons/test_bullet.cc \
                   lib/coord/p_node.cc \
                   lib/coord/null_parent.cc \
@@ -312,5 +312,5 @@
                   lib/graphics/text_engine.cc \
                   lib/lang/base_object.cc \
-		  lib/lang/class_list.cc \
+                  lib/lang/class_list.cc \
                   lib/util/ini_parser.cc \
                   lib/util/substring.cc \
@@ -350,11 +350,11 @@
                  world_entities/power_up.h \
                  world_entities/terrain.h \
-                 world_entities/weapon.h \
-                 world_entities/projectile.h \
                  world_entities/satellite.h \
                  world_entities/character_attributes.h \
-                 world_entities/test_gun.h \
-                 world_entities/test_bullet.h \
                  world_entities/test_entity.h \
+                 world_entities/weapons/weapon.h \
+                 world_entities/weapons/projectile.h \
+                 world_entities/weapons/test_gun.h \
+                 world_entities/weapons/test_bullet.h \
                  defs/stdincl.h \
                  defs/stdlibincl.h \
@@ -906,36 +906,4 @@
 @am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-terrain.obj `if test -f 'world_entities/terrain.cc'; then $(CYGPATH_W) 'world_entities/terrain.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/terrain.cc'; fi`
 
-orxonox-weapon.o: world_entities/weapon.cc
-@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-weapon.o -MD -MP -MF "$(DEPDIR)/orxonox-weapon.Tpo" -c -o orxonox-weapon.o `test -f 'world_entities/weapon.cc' || echo '$(srcdir)/'`world_entities/weapon.cc; \
-@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-weapon.Tpo" "$(DEPDIR)/orxonox-weapon.Po"; else rm -f "$(DEPDIR)/orxonox-weapon.Tpo"; exit 1; fi
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/weapon.cc' object='orxonox-weapon.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-weapon.Po' tmpdepfile='$(DEPDIR)/orxonox-weapon.TPo' @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-weapon.o `test -f 'world_entities/weapon.cc' || echo '$(srcdir)/'`world_entities/weapon.cc
-
-orxonox-weapon.obj: world_entities/weapon.cc
-@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-weapon.obj -MD -MP -MF "$(DEPDIR)/orxonox-weapon.Tpo" -c -o orxonox-weapon.obj `if test -f 'world_entities/weapon.cc'; then $(CYGPATH_W) 'world_entities/weapon.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/weapon.cc'; fi`; \
-@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-weapon.Tpo" "$(DEPDIR)/orxonox-weapon.Po"; else rm -f "$(DEPDIR)/orxonox-weapon.Tpo"; exit 1; fi
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/weapon.cc' object='orxonox-weapon.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-weapon.Po' tmpdepfile='$(DEPDIR)/orxonox-weapon.TPo' @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-weapon.obj `if test -f 'world_entities/weapon.cc'; then $(CYGPATH_W) 'world_entities/weapon.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/weapon.cc'; fi`
-
-orxonox-projectile.o: world_entities/projectile.cc
-@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-projectile.o -MD -MP -MF "$(DEPDIR)/orxonox-projectile.Tpo" -c -o orxonox-projectile.o `test -f 'world_entities/projectile.cc' || echo '$(srcdir)/'`world_entities/projectile.cc; \
-@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-projectile.Tpo" "$(DEPDIR)/orxonox-projectile.Po"; else rm -f "$(DEPDIR)/orxonox-projectile.Tpo"; exit 1; fi
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/projectile.cc' object='orxonox-projectile.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-projectile.Po' tmpdepfile='$(DEPDIR)/orxonox-projectile.TPo' @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-projectile.o `test -f 'world_entities/projectile.cc' || echo '$(srcdir)/'`world_entities/projectile.cc
-
-orxonox-projectile.obj: world_entities/projectile.cc
-@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-projectile.obj -MD -MP -MF "$(DEPDIR)/orxonox-projectile.Tpo" -c -o orxonox-projectile.obj `if test -f 'world_entities/projectile.cc'; then $(CYGPATH_W) 'world_entities/projectile.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/projectile.cc'; fi`; \
-@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-projectile.Tpo" "$(DEPDIR)/orxonox-projectile.Po"; else rm -f "$(DEPDIR)/orxonox-projectile.Tpo"; exit 1; fi
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/projectile.cc' object='orxonox-projectile.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-projectile.Po' tmpdepfile='$(DEPDIR)/orxonox-projectile.TPo' @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-projectile.obj `if test -f 'world_entities/projectile.cc'; then $(CYGPATH_W) 'world_entities/projectile.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/projectile.cc'; fi`
-
 orxonox-satellite.o: world_entities/satellite.cc
 @am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-satellite.o -MD -MP -MF "$(DEPDIR)/orxonox-satellite.Tpo" -c -o orxonox-satellite.o `test -f 'world_entities/satellite.cc' || echo '$(srcdir)/'`world_entities/satellite.cc; \
@@ -970,36 +938,4 @@
 @am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-character_attributes.obj `if test -f 'world_entities/character_attributes.cc'; then $(CYGPATH_W) 'world_entities/character_attributes.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/character_attributes.cc'; fi`
 
-orxonox-test_gun.o: world_entities/test_gun.cc
-@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-test_gun.o -MD -MP -MF "$(DEPDIR)/orxonox-test_gun.Tpo" -c -o orxonox-test_gun.o `test -f 'world_entities/test_gun.cc' || echo '$(srcdir)/'`world_entities/test_gun.cc; \
-@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-test_gun.Tpo" "$(DEPDIR)/orxonox-test_gun.Po"; else rm -f "$(DEPDIR)/orxonox-test_gun.Tpo"; exit 1; fi
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/test_gun.cc' object='orxonox-test_gun.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-test_gun.Po' tmpdepfile='$(DEPDIR)/orxonox-test_gun.TPo' @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-test_gun.o `test -f 'world_entities/test_gun.cc' || echo '$(srcdir)/'`world_entities/test_gun.cc
-
-orxonox-test_gun.obj: world_entities/test_gun.cc
-@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-test_gun.obj -MD -MP -MF "$(DEPDIR)/orxonox-test_gun.Tpo" -c -o orxonox-test_gun.obj `if test -f 'world_entities/test_gun.cc'; then $(CYGPATH_W) 'world_entities/test_gun.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/test_gun.cc'; fi`; \
-@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-test_gun.Tpo" "$(DEPDIR)/orxonox-test_gun.Po"; else rm -f "$(DEPDIR)/orxonox-test_gun.Tpo"; exit 1; fi
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/test_gun.cc' object='orxonox-test_gun.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-test_gun.Po' tmpdepfile='$(DEPDIR)/orxonox-test_gun.TPo' @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-test_gun.obj `if test -f 'world_entities/test_gun.cc'; then $(CYGPATH_W) 'world_entities/test_gun.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/test_gun.cc'; fi`
-
-orxonox-test_bullet.o: world_entities/test_bullet.cc
-@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-test_bullet.o -MD -MP -MF "$(DEPDIR)/orxonox-test_bullet.Tpo" -c -o orxonox-test_bullet.o `test -f 'world_entities/test_bullet.cc' || echo '$(srcdir)/'`world_entities/test_bullet.cc; \
-@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-test_bullet.Tpo" "$(DEPDIR)/orxonox-test_bullet.Po"; else rm -f "$(DEPDIR)/orxonox-test_bullet.Tpo"; exit 1; fi
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/test_bullet.cc' object='orxonox-test_bullet.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-test_bullet.Po' tmpdepfile='$(DEPDIR)/orxonox-test_bullet.TPo' @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-test_bullet.o `test -f 'world_entities/test_bullet.cc' || echo '$(srcdir)/'`world_entities/test_bullet.cc
-
-orxonox-test_bullet.obj: world_entities/test_bullet.cc
-@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-test_bullet.obj -MD -MP -MF "$(DEPDIR)/orxonox-test_bullet.Tpo" -c -o orxonox-test_bullet.obj `if test -f 'world_entities/test_bullet.cc'; then $(CYGPATH_W) 'world_entities/test_bullet.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/test_bullet.cc'; fi`; \
-@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-test_bullet.Tpo" "$(DEPDIR)/orxonox-test_bullet.Po"; else rm -f "$(DEPDIR)/orxonox-test_bullet.Tpo"; exit 1; fi
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/test_bullet.cc' object='orxonox-test_bullet.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-test_bullet.Po' tmpdepfile='$(DEPDIR)/orxonox-test_bullet.TPo' @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-test_bullet.obj `if test -f 'world_entities/test_bullet.cc'; then $(CYGPATH_W) 'world_entities/test_bullet.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/test_bullet.cc'; fi`
-
 orxonox-test_entity.o: world_entities/test_entity.cc
 @am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-test_entity.o -MD -MP -MF "$(DEPDIR)/orxonox-test_entity.Tpo" -c -o orxonox-test_entity.o `test -f 'world_entities/test_entity.cc' || echo '$(srcdir)/'`world_entities/test_entity.cc; \
@@ -1017,4 +953,68 @@
 @AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-test_entity.obj `if test -f 'world_entities/test_entity.cc'; then $(CYGPATH_W) 'world_entities/test_entity.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/test_entity.cc'; fi`
+
+orxonox-weapon.o: world_entities/weapons/weapon.cc
+@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-weapon.o -MD -MP -MF "$(DEPDIR)/orxonox-weapon.Tpo" -c -o orxonox-weapon.o `test -f 'world_entities/weapons/weapon.cc' || echo '$(srcdir)/'`world_entities/weapons/weapon.cc; \
+@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-weapon.Tpo" "$(DEPDIR)/orxonox-weapon.Po"; else rm -f "$(DEPDIR)/orxonox-weapon.Tpo"; exit 1; fi
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/weapons/weapon.cc' object='orxonox-weapon.o' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-weapon.Po' tmpdepfile='$(DEPDIR)/orxonox-weapon.TPo' @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-weapon.o `test -f 'world_entities/weapons/weapon.cc' || echo '$(srcdir)/'`world_entities/weapons/weapon.cc
+
+orxonox-weapon.obj: world_entities/weapons/weapon.cc
+@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-weapon.obj -MD -MP -MF "$(DEPDIR)/orxonox-weapon.Tpo" -c -o orxonox-weapon.obj `if test -f 'world_entities/weapons/weapon.cc'; then $(CYGPATH_W) 'world_entities/weapons/weapon.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/weapons/weapon.cc'; fi`; \
+@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-weapon.Tpo" "$(DEPDIR)/orxonox-weapon.Po"; else rm -f "$(DEPDIR)/orxonox-weapon.Tpo"; exit 1; fi
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/weapons/weapon.cc' object='orxonox-weapon.obj' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-weapon.Po' tmpdepfile='$(DEPDIR)/orxonox-weapon.TPo' @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-weapon.obj `if test -f 'world_entities/weapons/weapon.cc'; then $(CYGPATH_W) 'world_entities/weapons/weapon.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/weapons/weapon.cc'; fi`
+
+orxonox-projectile.o: world_entities/weapons/projectile.cc
+@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-projectile.o -MD -MP -MF "$(DEPDIR)/orxonox-projectile.Tpo" -c -o orxonox-projectile.o `test -f 'world_entities/weapons/projectile.cc' || echo '$(srcdir)/'`world_entities/weapons/projectile.cc; \
+@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-projectile.Tpo" "$(DEPDIR)/orxonox-projectile.Po"; else rm -f "$(DEPDIR)/orxonox-projectile.Tpo"; exit 1; fi
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/weapons/projectile.cc' object='orxonox-projectile.o' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-projectile.Po' tmpdepfile='$(DEPDIR)/orxonox-projectile.TPo' @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-projectile.o `test -f 'world_entities/weapons/projectile.cc' || echo '$(srcdir)/'`world_entities/weapons/projectile.cc
+
+orxonox-projectile.obj: world_entities/weapons/projectile.cc
+@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-projectile.obj -MD -MP -MF "$(DEPDIR)/orxonox-projectile.Tpo" -c -o orxonox-projectile.obj `if test -f 'world_entities/weapons/projectile.cc'; then $(CYGPATH_W) 'world_entities/weapons/projectile.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/weapons/projectile.cc'; fi`; \
+@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-projectile.Tpo" "$(DEPDIR)/orxonox-projectile.Po"; else rm -f "$(DEPDIR)/orxonox-projectile.Tpo"; exit 1; fi
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/weapons/projectile.cc' object='orxonox-projectile.obj' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-projectile.Po' tmpdepfile='$(DEPDIR)/orxonox-projectile.TPo' @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-projectile.obj `if test -f 'world_entities/weapons/projectile.cc'; then $(CYGPATH_W) 'world_entities/weapons/projectile.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/weapons/projectile.cc'; fi`
+
+orxonox-test_gun.o: world_entities/weapons/test_gun.cc
+@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-test_gun.o -MD -MP -MF "$(DEPDIR)/orxonox-test_gun.Tpo" -c -o orxonox-test_gun.o `test -f 'world_entities/weapons/test_gun.cc' || echo '$(srcdir)/'`world_entities/weapons/test_gun.cc; \
+@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-test_gun.Tpo" "$(DEPDIR)/orxonox-test_gun.Po"; else rm -f "$(DEPDIR)/orxonox-test_gun.Tpo"; exit 1; fi
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/weapons/test_gun.cc' object='orxonox-test_gun.o' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-test_gun.Po' tmpdepfile='$(DEPDIR)/orxonox-test_gun.TPo' @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-test_gun.o `test -f 'world_entities/weapons/test_gun.cc' || echo '$(srcdir)/'`world_entities/weapons/test_gun.cc
+
+orxonox-test_gun.obj: world_entities/weapons/test_gun.cc
+@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-test_gun.obj -MD -MP -MF "$(DEPDIR)/orxonox-test_gun.Tpo" -c -o orxonox-test_gun.obj `if test -f 'world_entities/weapons/test_gun.cc'; then $(CYGPATH_W) 'world_entities/weapons/test_gun.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/weapons/test_gun.cc'; fi`; \
+@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-test_gun.Tpo" "$(DEPDIR)/orxonox-test_gun.Po"; else rm -f "$(DEPDIR)/orxonox-test_gun.Tpo"; exit 1; fi
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/weapons/test_gun.cc' object='orxonox-test_gun.obj' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-test_gun.Po' tmpdepfile='$(DEPDIR)/orxonox-test_gun.TPo' @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-test_gun.obj `if test -f 'world_entities/weapons/test_gun.cc'; then $(CYGPATH_W) 'world_entities/weapons/test_gun.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/weapons/test_gun.cc'; fi`
+
+orxonox-test_bullet.o: world_entities/weapons/test_bullet.cc
+@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-test_bullet.o -MD -MP -MF "$(DEPDIR)/orxonox-test_bullet.Tpo" -c -o orxonox-test_bullet.o `test -f 'world_entities/weapons/test_bullet.cc' || echo '$(srcdir)/'`world_entities/weapons/test_bullet.cc; \
+@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-test_bullet.Tpo" "$(DEPDIR)/orxonox-test_bullet.Po"; else rm -f "$(DEPDIR)/orxonox-test_bullet.Tpo"; exit 1; fi
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/weapons/test_bullet.cc' object='orxonox-test_bullet.o' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-test_bullet.Po' tmpdepfile='$(DEPDIR)/orxonox-test_bullet.TPo' @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-test_bullet.o `test -f 'world_entities/weapons/test_bullet.cc' || echo '$(srcdir)/'`world_entities/weapons/test_bullet.cc
+
+orxonox-test_bullet.obj: world_entities/weapons/test_bullet.cc
+@am__fastdepCXX_TRUE@	if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT orxonox-test_bullet.obj -MD -MP -MF "$(DEPDIR)/orxonox-test_bullet.Tpo" -c -o orxonox-test_bullet.obj `if test -f 'world_entities/weapons/test_bullet.cc'; then $(CYGPATH_W) 'world_entities/weapons/test_bullet.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/weapons/test_bullet.cc'; fi`; \
+@am__fastdepCXX_TRUE@	then mv -f "$(DEPDIR)/orxonox-test_bullet.Tpo" "$(DEPDIR)/orxonox-test_bullet.Po"; else rm -f "$(DEPDIR)/orxonox-test_bullet.Tpo"; exit 1; fi
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	source='world_entities/weapons/test_bullet.cc' object='orxonox-test_bullet.obj' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	depfile='$(DEPDIR)/orxonox-test_bullet.Po' tmpdepfile='$(DEPDIR)/orxonox-test_bullet.TPo' @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCXX_FALSE@	$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(orxonox_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o orxonox-test_bullet.obj `if test -f 'world_entities/weapons/test_bullet.cc'; then $(CYGPATH_W) 'world_entities/weapons/test_bullet.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/weapons/test_bullet.cc'; fi`
 
 orxonox-p_node.o: lib/coord/p_node.cc
@@ -1348,5 +1348,5 @@
 
 distdir: $(DISTFILES)
-	$(mkdir_p) $(distdir)/defs $(distdir)/glmenu $(distdir)/lib/coord $(distdir)/lib/graphics $(distdir)/lib/lang $(distdir)/lib/math $(distdir)/lib/util $(distdir)/proto $(distdir)/story_entities $(distdir)/subprojects $(distdir)/util $(distdir)/util/animation $(distdir)/util/loading $(distdir)/util/track $(distdir)/world_entities
+	$(mkdir_p) $(distdir)/defs $(distdir)/glmenu $(distdir)/lib/coord $(distdir)/lib/graphics $(distdir)/lib/lang $(distdir)/lib/math $(distdir)/lib/util $(distdir)/proto $(distdir)/story_entities $(distdir)/subprojects $(distdir)/util $(distdir)/util/animation $(distdir)/util/loading $(distdir)/util/track $(distdir)/world_entities $(distdir)/world_entities/weapons
 	@srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \
Index: orxonox/trunk/src/defs/include_paths.am
===================================================================
--- orxonox/trunk/src/defs/include_paths.am	(revision 4756)
+++ orxonox/trunk/src/defs/include_paths.am	(revision 4758)
@@ -1,4 +1,5 @@
 AM_CXXFLAGS=-I$(MAINSRCDIR)
 AM_CXXFLAGS+=-I$(MAINSRCDIR)/world_entities
+AM_CXXFLAGS+=-I$(MAINSRCDIR)/world_entities/weapons
 AM_CXXFLAGS+=-I$(MAINSRCDIR)/story_entities
 AM_CXXFLAGS+=-I$(MAINSRCDIR)/lib
Index: orxonox/trunk/src/lib/lang/class_list.cc
===================================================================
--- orxonox/trunk/src/lib/lang/class_list.cc	(revision 4756)
+++ orxonox/trunk/src/lib/lang/class_list.cc	(revision 4758)
@@ -152,5 +152,5 @@
   PRINT(0)("=  CLASS_LIST (level %d)  =\n", debugLevel);
   PRINT(0)("==========================\n");
-  PRINT(0)(" knows %d Classes\n\n", ClassList::classCount);
+  PRINT(0)("| knows %d Classes\n\|\n", ClassList::classCount);
   ClassList* tmp = ClassList::first;
   char niceString[100];
@@ -168,14 +168,14 @@
       niceString[30-strlen(tmp->className) - lenCount] = '\0';
 
-      PRINT(0)(" CLASS %s:%s %d\n", tmp->className, niceString, tmp->objectList->getSize());
+      PRINT(0)("| CLASS %s:%s %d\n", tmp->className, niceString, tmp->objectList->getSize());
 
       if (debugLevel >=2 && tmp->objectList->getSize() > 0)
       {
-        PRINT(0)("  Listing Instances:\n");
+        PRINT(0)("|  Listing Instances:\n");
         tIterator<BaseObject>* iterator = tmp->objectList->getIterator();
         BaseObject* enumBO = iterator->nextElement();
         while (enumBO)
         {
-          PRINT(0)("   (class %s): NAME(%s)->%p\n", enumBO->getClassName(), enumBO->getName(), enumBO);
+          PRINT(0)("|   (class %s): NAME(%s)->%p\n", enumBO->getClassName(), enumBO->getName(), enumBO);
           enumBO = iterator->nextElement();
         }
@@ -185,4 +185,4 @@
     tmp = tmp->next;
   }
-  PRINT(0)("==============CL=\n");
+  PRINT(0)("=======================CL=\n");
 }
Index: orxonox/trunk/src/world_entities/projectile.cc
===================================================================
--- orxonox/trunk/src/world_entities/projectile.cc	(revision 4756)
+++ 	(revision )
@@ -1,158 +1,0 @@
-
-
-/*
-   orxonox - the future of 3D-vertical-scrollers
-
-   Copyright (C) 2004 orx
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2, or (at your option)
-   any later version.
-
-   ### File Specific
-   main-programmer: Patrick Boenzli
-   co-programmer:
-*/
-
-
-#include "projectile.h"
-
-#include "world_entity.h"
-#include "weapon.h"
-#include "null_parent.h"
-#include "model.h"
-#include "vector.h"
-
-using namespace std;
-
-
-/**
-   \brief standard constructor
-*/
-Projectile::Projectile (Weapon* weapon) : WorldEntity()
-{
-  this->setClassID(CL_PROJECTILE, "Projectile");
-
-  this->weapon = weapon;
-  this->flightDirection = NULL;
-  this->currentLifeTime = 0.0f;
-  this->ttl = 0.75f; /* sec */
-  this->speed = 2.0f;
-}
-
-
-/**
-   \brief standard deconstructor
-*/
-Projectile::~Projectile ()
-{
-  /*
-     do not delete the test projectModel, since it is pnode
-     and will be cleaned out by world
-  */
-  //delete this->projectileModel;
-}
-
-
-/**
-   \brief this sets the flight direction of the projectile
-   \param directin in which to flight
-
-   this function will calculate a vector out of this to be used in the
-   tick function
-*/
-void Projectile::setFlightDirection(Quaternion flightDirection)
-{
-  if( this->flightDirection == NULL)
-    this->flightDirection = new Vector();
-  Vector v(1, 0, 0);
-  *this->flightDirection = flightDirection.apply(v);
-  this->flightDirection->normalize();
-}
-
-
-/**
-   \brief this sets the time to life of the projectile
-   \param ttl in second
-
-   after this life time, the projectile will garbage collect itself
-*/
-void Projectile::setTTL(float ttl)
-{
-  this->ttl = ttl;
-}
-
-
-/**
-   \brief sets the speed of the projectile
-*/
-void Projectile::setSpeed(float speed)
-{
-  this->speed = speed * 3; /* fix speed settings */
-  PRINTF(4)("Projectile::setting speed to: %f\n", this->speed);
-}
-
-
-/**
-   \brief sets the velocity vector to a spec speed
-   \param velocity: vector of the velocity
-*/
-void Projectile::setVelocity(const Vector &velocity)
-{
-  this->offsetVel = this->velocity = velocity;
-  this->offsetVel.normalize();
-  this->velocity += (this->offsetVel * 50.0);
-}
-
-
-/**
-   \brief signal tick, time dependent things will be handled here
-   \param time since last tick
-*/
-void Projectile::tick (float time)
-{
-  Vector v = this->velocity * (time);
-  this->shiftCoor(v);
-
-  this->currentLifeTime += time;
-  if( this->ttl < this->currentLifeTime)
-    {
-      PRINTF(5)("FINALIZE==========================\n");
-      PRINTF(5)("current life time is: %f/%f\n", this->currentLifeTime, this->ttl);
-      PRINTF(5)("FINALIZE===========================\n");
-      this->finalize();
-      this->currentLifeTime = 0.0f;
-    }
-}
-
-/**
-   \brief the projectile gets hit by another entity
-   \param the other entity
-   \param place where it is hit
-*/
-void Projectile::hit (WorldEntity* entity, Vector* place)
-{}
-
-
-/**
-   \brief the function gets called, when the projectile is destroyed
-*/
-void Projectile::destroy ()
-{}
-
-
-void Projectile::draw ()
-{
-  glMatrixMode(GL_MODELVIEW);
-  glPushMatrix();
-
-  float matrix[4][4];
-  glTranslatef (this->getAbsCoor ().x, this->getAbsCoor ().y, this->getAbsCoor ().z);
-  this->getAbsDir().matrix (matrix);
-  glMultMatrixf((float*)matrix);
-  this->model->draw();
-
-  glPopMatrix();
-}
-
Index: orxonox/trunk/src/world_entities/projectile.h
===================================================================
--- orxonox/trunk/src/world_entities/projectile.h	(revision 4756)
+++ 	(revision )
@@ -1,60 +1,0 @@
-/*!
-    \projectile.h
-    \brief a projectile, that is been shooted by a weapon
-
-    You can use this class to make some shoots, but this isn't the real idea. If you want to just test, if the
-    shooting funcions work, use the Projectile class. But if you want to implement your own shoots its
-    different:<br>
-    Make a new class and derive it from Projectile. To have a weapon work well, reimplement the functions
-    - void tick()
-    - void draw()
-    - void hit() (only if you have working collision detection)
-    When you have implemented these functions you have just to add the projectiles to your weapon. You ll want
-    to make this by looking into the function
-    - Weapon::fire()
-    there you just change the line:
-    Projectile* pj = new Projectile();    TO     Projectile* pj = new MyOwnProjectileClass();
-    and schwups it works... :)
-*/
-
-#ifndef _PROJECTILE_H
-#define _PROJECTILE_H
-
-#include "world_entity.h"
-#include "vector.h"
-
-class Vector;
-class Weapon;
-
-class Projectile : public WorldEntity
-{
-  friend class World;
-
- public:
-  Projectile (Weapon* weapon);
-  virtual ~Projectile ();
-
-  void setFlightDirection(Quaternion flightDirection);
-  void setSpeed(float speed);
-  void setVelocity(const Vector &velocity);
-  void setTTL(float ttl);
-
-  virtual void hit (WorldEntity* weapon, Vector* loc);
-  virtual void destroy ();
-
-  virtual void tick (float time);
-  virtual void draw ();
-
- protected:
-  //physical attriutes like: force, speed, acceleration etc.
-  float          speed;                     //!< this is the speed of the projectile
-  float          currentLifeTime;           //!< this is the time, the projectile exists in this world (incremented by tick)
-  float          ttl;                       //!< time to life, after this time, the projectile will garbage collect itself
-  Vector*        flightDirection;           //!< direction in which the shoot flights
-  Weapon*        weapon;                    //!< weapon the shoot belongs to
-
-  Vector         velocity;                  //!< velocity of the projectile
-  Vector         offsetVel;                 //!< offset velocity TEMP
-};
-
-#endif /* _PROJECTILE_H */
Index: orxonox/trunk/src/world_entities/test_bullet.cc
===================================================================
--- orxonox/trunk/src/world_entities/test_bullet.cc	(revision 4756)
+++ 	(revision )
@@ -1,107 +1,0 @@
-
-
-/*
-   orxonox - the future of 3D-vertical-scrollers
-
-   Copyright (C) 2004 orx
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2, or (at your option)
-   any later version.
-
-   ### File Specific
-   main-programmer: Patrick Boenzli
-   co-programmer:
-*/
-
-
-#include "test_bullet.h"
-
-#include "world_entity.h"
-#include "weapon.h"
-#include "null_parent.h"
-#include "model.h"
-#include "vector.h"
-
-using namespace std;
-
-
-/**
-   \brief standard constructor
-*/
-TestBullet::TestBullet (Weapon* weapon) : Projectile(weapon)
-{
-  this->setClassID(CL_TEST_BULLET, "TestBullet");
-
-  float modelSize = .5;
-  this->model = (Model*)ResourceManager::getInstance()->load("models/orx-rocket.obj", OBJ, RP_LEVEL, (void*) &modelSize);
-}
-
-
-/**
-   \brief standard deconstructor
-*/
-TestBullet::~TestBullet ()
-{
-  /*
-     do not delete the test projectModel, since it is pnode
-     and will be cleaned out by world
-  */
-  //delete this->projectileModel;
-}
-
-
-
-/**
-   \brief signal tick, time dependent things will be handled here
-   \param time since last tick
-*/
-void TestBullet::tick (float time)
-{
-  //Vector v = *this->flightDirection * ( this->speed * time * 1000 + 0.1);
-  Vector v = this->velocity * (time);
-  this->shiftCoor(v);
-
-  this->currentLifeTime += time;
-  if( this->ttl < this->currentLifeTime)
-    {
-      PRINTF(5)("FINALIZE==========================\n");
-      PRINTF(5)("current life time is: %f/%f\n", this->currentLifeTime, this->ttl);
-      PRINTF(5)("FINALIZE===========================\n");
-      this->finalize();
-      this->currentLifeTime = 0.0f;
-    }
-}
-
-/**
-   \brief the projectile gets hit by another entity
-   \param the other entity
-   \param place where it is hit
-*/
-void TestBullet::hit (WorldEntity* entity, Vector* place)
-{}
-
-
-/**
-   \brief the function gets called, when the projectile is destroyed
-*/
-void TestBullet::destroy ()
-{}
-
-
-void TestBullet::draw ()
-{
-  glMatrixMode(GL_MODELVIEW);
-  glPushMatrix();
-
-  float matrix[4][4];
-  glTranslatef (this->getAbsCoor ().x, this->getAbsCoor ().y, this->getAbsCoor ().z);
-  this->getAbsDir().matrix (matrix);
-  glMultMatrixf((float*)matrix);
-  glScalef(2.0, 2.0, 2.0);
-  this->model->draw();
-
-  glPopMatrix();
-}
-
Index: orxonox/trunk/src/world_entities/test_bullet.h
===================================================================
--- orxonox/trunk/src/world_entities/test_bullet.h	(revision 4756)
+++ 	(revision )
@@ -1,30 +1,0 @@
-/*! 
-    \projectile.h
-    \brief a projectile, that is been shooted by a weapon
-*/
-
-#ifndef _TEST_BULLET_H
-#define _TEST_BULLET_H
-
-#include "projectile.h"
-
-class Vector;
-class Weapon;
-
-class TestBullet : public Projectile 
-{
-  friend class World;
-
- public:
-  TestBullet (Weapon* weapon);
-  virtual ~TestBullet ();
-
-  virtual void hit (WorldEntity* weapon, Vector* loc);
-  virtual void destroy ();
-
-  virtual void tick (float time);
-  virtual void draw ();
-  
-};
-
-#endif /* _TEST_BULLET_H */
Index: orxonox/trunk/src/world_entities/test_gun.cc
===================================================================
--- orxonox/trunk/src/world_entities/test_gun.cc	(revision 4756)
+++ 	(revision )
@@ -1,234 +1,0 @@
-
-
-/*
-   orxonox - the future of 3D-vertical-scrollers
-
-   Copyright (C) 2004 orx
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2, or (at your option)
-   any later version.
-
-   ### File Specific
-   main-programmer: Patrick Boenzli
-   co-programmer:
-
-
-   \todo: direction in which the projectile flights
-   \todo: a target to set/hit
-*/
-
-
-#include "test_gun.h"
-
-#include "stdincl.h"
-#include "world_entity.h"
-#include "model.h"
-#include "test_bullet.h"
-
-#include "vector.h"
-#include "list.h"
-#include "animation3d.h"
-#include "sound_engine.h"
-
-#include "object_manager.h"
-
-using namespace std;
-
-
-/**
-   \brief standard constructor
-
-   creates a new weapon
-*/
-TestGun::TestGun (PNode* parent, const Vector& coordinate,
-                  const Quaternion& direction, int leftRight)
-  :  Weapon (parent, coordinate, direction)
-{
-  this->setClassID(CL_TEST_GUN, "TestGun");
-
-  this->model = (Model*)ResourceManager::getInstance()->load("models/test_gun.obj", OBJ, RP_CAMPAIGN);
-  this->idleTime = 0.2f;
-  this->leftRight = leftRight;
-
-  this->objectComponent1 = new PNode();
-  this->animation1 = new Animation3D(this->objectComponent1);
-  this->animation2 = new Animation3D(this);
-  this->animation3 = new Animation3D(this);
-  //parent->addChild(this->objectComponent1, PNODE_ALL);
-  this->addChild(this->objectComponent1, PNODE_ALL);
-
-  this->animation1->setInfinity(ANIM_INF_CONSTANT);
-  this->animation2->setInfinity(ANIM_INF_CONSTANT);
-  this->animation3->setInfinity(ANIM_INF_CONSTANT);
-  if( this->leftRight == W_LEFT)
-    {
-      this->projectileOffset = Vector(1.0, 0.0, -0.35);
-
-      this->animation1->addKeyFrame(Vector(0, 0, 0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
-      this->animation1->addKeyFrame(Vector(-0.4, 0, 0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
-      this->animation1->addKeyFrame(Vector(0, 0, 0), Quaternion(), 0.0, ANIM_LINEAR, ANIM_CONSTANT);
-
-      this->animation2->addKeyFrame(Vector(-2.6, 0.1, 2.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
-      this->animation2->addKeyFrame(Vector(-2.6, 0.1, 3.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
-
-      this->animation3->addKeyFrame(Vector(-2.6, 0.1, 3.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
-      this->animation3->addKeyFrame(Vector(-2.6, 0.1, 2.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
-    }
-  else if( this->leftRight == W_RIGHT)
-    {
-      this->projectileOffset = Vector(1.0, 0.0, 0.5);
-
-      this->objectComponent1->setRelCoor(Vector(0,0,0.35));
-      this->animation1->addKeyFrame(Vector(0, 0, .5), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
-      this->animation1->addKeyFrame(Vector(-0.4, 0, .5), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
-      this->animation1->addKeyFrame(Vector(0, 0, .5), Quaternion(), 0.0, ANIM_LINEAR, ANIM_CONSTANT);
-
-      this->animation2->addKeyFrame(Vector(-2.6, 0.1, -2.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
-      this->animation2->addKeyFrame(Vector(-2.6, 0.1, -3.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
-
-      this->animation3->addKeyFrame(Vector(-2.6, 0.1, -3.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
-      this->animation3->addKeyFrame(Vector(-2.6, 0.1, -2.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
-    }
-
-  this->fireSound = (SoundBuffer*)ResourceManager::getInstance()->load("sound/shot1.wav", WAV);
-  this->weaponSource = new SoundSource(this->fireSound, this);
-  this->weaponSource->setRolloffFactor(.1);
-  Projectile* p = new TestBullet(this);
-//  ObjectManager::getInstance()->cache(CL_TEST_BULLET, 100, p);
-  //ObjectManager::getInstance()->debug();
-}
-
-
-/**
-   \brief standard deconstructor
-*/
-TestGun::~TestGun ()
-{
-  // model will be deleted from WorldEntity-destructor
-}
-
-
-/**
-   \brief this activates the weapon
-
-   This is needed, since there can be more than one weapon on a ship. the
-   activation can be connected with an animation. for example the weapon is
-   been armed out.
-*/
-void TestGun::activate()
-{
-  this->animation2->replay();
-}
-
-
-/**
-   \brief this deactivates the weapon
-
-   This is needed, since there can be more than one weapon on a ship. the
-   activation can be connected with an animation. for example the weapon is
-   been armed out.
-*/
-void TestGun::deactivate()
-{
-  this->animation3->replay();
-}
-
-
-/**
-   \brief fires the weapon
-
-   this is called from the player.cc, when fire-button is been pushed
-   \todo: the ObjectManager deliveres Projectiles not TestBullets! this should be diffrent
-*/
-void TestGun::fire()
-{
-  if( !this->hasWeaponIdleTimeElapsed())
-    {
-      this->weaponIdle();
-      return;
-    }
-
-    Projectile* pj =  new TestBullet(this);//dynamic_cast<Projectile*>(ObjectManager::getInstance()->getFromDeadList(CL_TEST_BULLET & CL_MASK_LOWLEVEL_CLASS));
-  weaponSource->play();
-
-  pj->setAbsCoor(this->getAbsCoor() + this->projectileOffset);
-  pj->setAbsDir(this->getAbsDir());
-  pj->setVelocity(this->getVelocity());
-  this->worldEntities->add(pj);
-  this->localTime = 0;
-
-  this->animation1->replay();
-}
-
-
-/**
-   \brief is called, when the weapon gets hit (=collide with something)
-   \param from which entity it is been hit
-   \param where it is been hit
-
-   this may not be used, since it would make the game relay complicated when one
-   can destroy the weapons of enemies or vice versa.
-*/
-void TestGun::hit (WorldEntity* entity, Vector* position)
-{}
-
-
-/**
-   \brief is called, when the weapon is destroyed
-
-   this is in conjunction with the hit function, so when a weapon is able to get
-   hit, it can also be destoryed.
-*/
-void TestGun::destroy ()
-{}
-
-
-/**
-   \brief tick signal for time dependent/driven stuff
-*/
-void TestGun::tick (float time)
-{
-  this->localTime += time;
-}
-
-
-/**
-   \brief is called, when there is no fire button pressed
-*/
-void TestGun::weaponIdle()
-{}
-
-
-/**
-   \brief this will draw the weapon
-*/
-void TestGun::draw ()
-{
-  /* draw gun body */
-  glMatrixMode(GL_MODELVIEW);
-  glPushMatrix();
-  float matrix[4][4];
-  glTranslatef (this->getAbsCoor ().x,
-                this->getAbsCoor ().y,
-                this->getAbsCoor ().z);
-  this->getAbsDir ().matrix (matrix);
-  glMultMatrixf((float*)matrix);
-  if( this->leftRight == W_RIGHT)
-    glScalef(1.0, 1.0, -1.0);
-  this->model->draw(1);
-  glPopMatrix();
-
-  /* draw objectComponent1: gun coil - animated stuff */
-  glMatrixMode(GL_MODELVIEW);
-  glPushMatrix();
-  glTranslatef (this->objectComponent1->getAbsCoor ().x,
-                this->objectComponent1->getAbsCoor ().y,
-                this->objectComponent1->getAbsCoor ().z);
-  this->objectComponent1->getAbsDir ().matrix (matrix);
-  glMultMatrixf((float*)matrix);
-  this->model->draw(0);
-  glPopMatrix();
-}
-
Index: orxonox/trunk/src/world_entities/test_gun.h
===================================================================
--- orxonox/trunk/src/world_entities/test_gun.h	(revision 4756)
+++ 	(revision )
@@ -1,58 +1,0 @@
-/*! 
-    \file weapon.h
-    \brief a weapon that a player can use
-
-    A Player has a list of weapons, that can be choosen to shoot projectiles
-    (projectiles.{cc,h}) at ennemies. These weapons can be shooted sequentially
-    or (if able) combined. Therefore you can choose the weapon mode = choose
-    a weapon.
-
-    A weapon is characterized by:
-     o firing-rate: the initial firing rate of a weapon (1/s = Herz)
-     o slowdown-factor: this is a factor d: exp(-d*x), d is element of all positive R. it determines how fast the firing-rate will slow down. if no slowdown: d=0, the bigger d is, the faster the weapon will slow down!
-     o energy-consumption: this determines the energy that has to be used to produce this projectile = costs per projectile
-    
-    Furthermore there are some other attributes, that will help to represent a firing
-    weapon in this world:
-     o sound file/ressource: this is a pointer to the sound-file/ressource. however it may be represented
-     o shooting animation
-     
-*/
-
-
-#ifndef _TEST_GUN_H
-#define _TEST_GUN_H
-
-#include "weapon.h"
-
-class Projectile;
-class Vector;
-class Quaternion;
-class Animation3D;
-
-
-class TestGun : public Weapon
-{
-  friend class World;
-
- public:
-  TestGun (PNode* parent, const Vector& coordinate, const Quaternion& direction, int leftRight);
-  virtual ~TestGun ();
-
-  virtual void activate();
-  virtual void deactivate();
-
-  virtual void fire();
-  virtual void hit (WorldEntity* weapon, Vector* loc);
-  virtual void destroy();
-  
-  virtual void tick(float time);
-  virtual void weaponIdle();
-  virtual void draw();
-
-
-
-
-};
-
-#endif /* _TEST_GUN_H */
Index: orxonox/trunk/src/world_entities/weapon.cc
===================================================================
--- orxonox/trunk/src/world_entities/weapon.cc	(revision 4756)
+++ 	(revision )
@@ -1,389 +1,0 @@
-
-
-/*
-   orxonox - the future of 3D-vertical-scrollers
-
-   Copyright (C) 2004 orx
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2, or (at your option)
-   any later version.
-
-   ### File Specific
-   main-programmer: Patrick Boenzli
-   co-programmer:
-*/
-
-#define DEBUG_SPECIAL_MODULE DEBUG_MODULE_WEAPON
-
-#include "weapon.h"
-#include "stdincl.h"
-#include "world_entity.h"
-#include "vector.h"
-#include "model.h"
-#include "projectile.h"
-#include "list.h"
-#include "world.h"
-
-using namespace std;
-
-
-
-/**
-   \brief this initializes the weaponManager for a given nnumber of weapon slots
-   \param number of weapon slots of the model/ship <= 8 (limitied)
-*/
-WeaponManager::WeaponManager(int nrOfSlots)
-{
-  this->setClassID(CL_WEAPON_MANAGER, "WeaponManager");
-
-  for(int i = 0; i < W_MAX_CONFIGS; ++i)
-    {
-      this->configs[i].bUsed = false;
-      for(int j = 0; j < W_MAX_SLOTS; ++j)
-        this->configs[i].slots[j] = NULL;
-    }
-  this->nrOfSlots = nrOfSlots;
-  this->currConfID = W_CONFIG0;
-}
-
-
-WeaponManager::~WeaponManager()
-{
-  /*
-     i dont have to delete the weapons itself, because they are
-     worldentities and therefore in the entities list of the world.
-     world will clean them up for me
-  */
-  for(int i = 0; i < W_MAX_CONFIGS; ++i)
-    {
-      this->configs[i].bUsed = false;
-      for(int j = 0; j < W_MAX_SLOTS; ++j)
-        this->configs[i].slots[j] = NULL;
-    }
-}
-
-
-/**
-   \brief adds a weapon to the selected weaponconfiguration into the selected slot
-   \param the weapon to add
-   \param an identifier for the slot: number between 0..7 if not specified: slotID=next free slot
-   \param an identifier for the weapon configuration, number between 0..3
-
-   if you add explicitly a weapon at config:n, slot:m, the weapon placed at this location will be
-   replaced by the weapon specified. if you use the W_FREE_SLOT, the manager will look for a free
-   slot in this weaponconfiguration. if there is non, the weapon won't be added and there will be
-   a error message.
-*/
-void WeaponManager::addWeapon(Weapon* weapon, int configID, int slotID)
-{
-  if( slotID == W_FREE_SLOT)
-    {
-      int freeSlot = this->getNextFreeSlot( configID);
-      if( freeSlot < 0 || freeSlot >= this->nrOfSlots)
-        {
-          PRINTF(0)("There is no free slot in this WeaponConfig to dock this weapon at! Aborting\n");
-          return;
-        }
-      PRINTF(3)("Added new Weapon to Config:%i/Slot:%i\n", configID, freeSlot);
-      this->configs[configID].bUsed = true;
-      this->configs[configID].slots[freeSlot] = weapon;
-      return;
-    }
-  this->configs[configID].bUsed = true;
-  this->configs[configID].slots[slotID] = weapon;
-  PRINTF(3)("Added a new Weapon to the WeaponManager: config %i/ slot %i\n", configID, slotID);
-}
-
-
-void WeaponManager::removeWeapon(Weapon* weapon, int configID)
-{
-  /* empty */
-}
-
-
-/**
-   \brief changes to the next weapon configuration
-
-   if there are multiple weapon configurations defined by the manager, use this to switch between them
-   this function will deactivate the weapons first, change the config and reactivate them later
-*/
-void WeaponManager::nextWeaponConf()
-{
-  PRINTF(4)("Changing weapon configuration: from %i to next\n", this->currConfID);
-
-  int i, lastConfID;
-  lastConfID = this->currConfID;
-  for(i = this->currConfID + 1; i < W_MAX_CONFIGS && !this->configs[i].bUsed; ++i);
-  if( i == W_MAX_CONFIGS) this->currConfID = W_CONFIG0;
-  else this->currConfID = i;
-
-
-  Weapon *w1, *w2;
-  for(int j = 0; j < W_MAX_SLOTS; ++j)
-    {
-      w1 = this->configs[lastConfID].slots[j];
-      w2 = this->configs[this->currConfID].slots[j];
-
-      if( w1 == w2)
-        {
-          printf("no need for change\n");
-        }
-      else
-        {
-        if( w1 != NULL )
-          {
-            w1->deactivate();
-            printf("deactivating %i,%i\n", j,lastConfID);
-          }
-        if( w2 != NULL)
-          {
-            w2->activate();
-            printf("activating %i,%i\n", j, this->currConfID);
-          }
-        }
-    }
-}
-
-
-
-/**
-   \brief triggers fire of all weapons in the current weaponconfig
-*/
-void WeaponManager::fire()
-{
-  Weapon* firingWeapon;
-  for(int i = 0; i < W_MAX_SLOTS; ++i)
-    {
-      firingWeapon = this->configs[this->currConfID].slots[i];
-      if( firingWeapon != NULL) firingWeapon->fire();
-    }
-}
-
-
-/**
-   \brief triggers tick of all weapons in the current weaponconfig
-   \param second passed since last tick
-*/
-void WeaponManager::tick(float sec)
-{
-  Weapon* w;
-  for(int i = 0; i < W_MAX_SLOTS; ++i)
-    {
-      w = this->configs[this->currConfID].slots[i];
-      if( w != NULL) w->tick(sec);
-    }
-}
-
-
-/**
-   \brief triggers draw of all weapons in the current weaponconfig
-*/
-void WeaponManager::draw()
-{
-  Weapon* w;
-  for(int i = 0; i < W_MAX_SLOTS; ++i)
-    {
-      w = this->configs[this->currConfID].slots[i];
-      if( w != NULL) w->draw();
-    }
-}
-
-
-/**
-   \brief private gets the next free slot in a certain weaponconfig
-   \param the selected weaponconfig
-*/
-int WeaponManager::getNextFreeSlot(int configID)
-{
-  for( int i = 0; i < W_MAX_SLOTS; ++i)
-    {
-      if( this->configs[configID].slots[i] == NULL)
-        return i;
-    }
-  return -1;
-}
-
-
-
-
-
-
-/**
-   \brief standard constructor
-
-   creates a new weapon
-*/
-Weapon::Weapon (PNode* parent, const Vector& coordinate, const Quaternion& direction)
-  : WorldEntity()
-{
-  parent->addChild(this, PNODE_ALL);
-  this->setRelCoor(coordinate);
-  this->setRelDir(direction);
-  WorldInterface* wi = WorldInterface::getInstance();
-  this->worldEntities = wi->getEntityList();
-
-  this->objectComponent1 = NULL;
-  this->objectComponent2 = NULL;
-  this->objectComponent3 = NULL;
-
-  this->animation1 = NULL;
-  this->animation2 = NULL;
-  this->animation3 = NULL;
-}
-
-
-/**
-   \brief standard deconstructor
-*/
-Weapon::~Weapon ()
-{
-  // model will be deleted from WorldEntity-destructor
-  //this->worldEntities = NULL;
-
-  /* dont delete objectComponentsX here, they will be killed when the pnodes are cleaned out */
-
-  /* all animations are deleted via the animation player*/
-}
-
-
-/**
-    \brief enables the weapon
-
-    a weapon can be enabled/disabled because of various reasons. if a weapon is
-    been enabled, it can interact in a world. elswhere it wont react to any
-    action.
-*/
-void Weapon::enable()
-{
-  this->enabled = true;
-}
-
-
-/**
-    \brief disables the weapon
-
-    a weapon can be enabled/disabled because of various reasons. if a weapon is
-    been enabled, it can interact in a world. elswhere it wont react to any
-    action.
-*/
-void Weapon::disable()
-{
-  this->enabled = false;
-}
-
-
-/**
-    \brief checks if the weapon is enabled
-    \returns true if enabled
-
-    a weapon can be ebabled/disabled because of various reasons. if a weapon is
-    been enabled, it can interact in a world. elswhere it wont react to any
-    action.
-*/
-bool Weapon::isEnabled()
-{
-  return this->enabled;
-}
-
-
-/**
-   \brief sets a new projectile to the weapon
-   \param new projectile for this weapon
-
-   weapon an projectile are independent, so you can combine them as you want
-*/
-void Weapon::setProjectile(Projectile* projectile)
-{
-  this->projectile = projectile;
-}
-
-
-/**
-   \brief sets a new projectile to the weapon
-   \returns the current projectile of this weapon
-
-   weapon an projectile are independent, so you can combine them as you want
-*/
-Projectile* Weapon::getProjectile()
-{
-  return this->projectile;
-}
-
-
-/**
-   \brief this activates the weapon
-
-   This is needed, since there can be more than one weapon on a ship. the
-   activation can be connected with an animation. for example the weapon is
-   been armed out.
-*/
-void Weapon::activate()
-{}
-
-
-/**
-   \brief this deactivates the weapon
-
-   This is needed, since there can be more than one weapon on a ship. the
-   activation can be connected with an animation. for example the weapon is
-   been armed out.
-*/
-void Weapon::deactivate()
-{}
-
-/**
-   \brief asks if the current weapon is active
-   \returns true if it the weapon is active
-*/
-bool Weapon::isActive()
-{}
-
-
-
-
-
-
-/**
-   \brief is called, when the weapon gets hit (=collide with something)
-   \param from which entity it is been hit
-   \param where it is been hit
-
-   this may not be used, since it would make the game relay complicated when one
-   can destroy the weapons of enemies or vice versa.
-*/
-void Weapon::hit (WorldEntity* entity, Vector* position)
-{}
-
-
-/**
-   \brief is called, when the weapon is destroyed
-
-   this is in conjunction with the hit function, so when a weapon is able to get
-   hit, it can also be destoryed.
-*/
-void Weapon::destroy ()
-{}
-
-
-/**
-   \brief tick signal for time dependent/driven stuff
-*/
-void Weapon::tick (float time)
-{}
-
-
-/**
-   \brief is called, when there is no fire button pressed
-*/
-void Weapon::weaponIdle()
-{}
-
-
-/**
-   \brief this will draw the weapon
-*/
-void Weapon::draw ()
-{}
-
Index: orxonox/trunk/src/world_entities/weapon.h
===================================================================
--- orxonox/trunk/src/world_entities/weapon.h	(revision 4756)
+++ 	(revision )
@@ -1,188 +1,0 @@
-/*!
-    \file weapon.h
-    \brief a weapon that a player can use
-
-    A Player has a list of weapons, that can be choosen to shoot projectiles
-    (projectiles.{cc,h}) at ennemies. These weapons can be shooted sequentially
-    or (if able) combined. Therefore you can choose the weapon mode = choose
-    a weapon.
-
-    A weapon is characterized by:
-     o firing-rate: the initial firing rate of a weapon (1/s = Herz)
-     o slowdown-factor: this is a factor d: exp(-d*x), d is element of all positive R. it determines how fast the firing-rate will slow down. if no slowdown: d=0, the bigger d is, the faster the weapon will slow down!
-     o energy-consumption: this determines the energy that has to be used to produce this projectile = costs per projectile
-
-    Furthermore there are some other attributes, that will help to represent a firing
-    weapon in this world:
-     o sound file/ressource: this is a pointer to the sound-file/ressource. however it may be represented
-     o shooting animation
-
-
-     a player defines one or more weapon configurations. a player has got one to eight
-     weapon slots: places where weapons can be attached to. a weapon configuration
-     is a matching between weapons and slots.
-     Since its clear how many weapons a player will have, there is no list of weapons:
-     its hard coded and limited to 8 slots and 4 configs. More would be a waste of
-     memory and time you need to customize and change to a weapon config...
-*/
-
-
-#ifndef _WEAPON_H
-#define _WEAPON_H
-
-#include "base_object.h"
-#include "world_entity.h"
-
-#define W_MAX_SLOTS 8
-#define W_MAX_CONFIGS 4
-
-class Projectile;
-class Weapon;
-class Animation3D;
-
-typedef enum {
-  SHOOT,
-  EMPTY,
-  RELOAD,
-  SPECIAL1,
-  SPECIAL2,
-  SPECIAL3
-} weaponSoundType;
-
-
-//! this is an identifier for the slot. there are up to 8 weapon slots -> this means there can't be more than 8 weapons at the same time
-#define W_SLOT0 0
-#define W_SLOT1 1
-#define W_SLOT2 2
-#define W_SLOT3 3
-#define W_SLOT4 4
-#define W_SLOT5 5
-#define W_SLOT6 6
-#define W_SLOT7 7
-#define W_FREE_SLOT 99
-
-
-//! this is an identifier for the weapon config
-#define W_CONFIG0 0
-#define W_CONFIG1 1
-#define W_CONFIG2 2
-#define W_CONFIG3 3
-
-//! a weapon can be left or right sided
-#define W_LEFT 0
-#define W_RIGHT 1
-
-//! this is a weapon Configuration: it has up to 8 slots
-typedef struct weaponConfig {
-  bool bUsed;                       //<! is set to true, if this configuration is
-  Weapon* slots[8];
-};
-
-
-class WeaponManager : public BaseObject {
- public:
-  WeaponManager(int nrOfSlots = 2);
-  ~WeaponManager();
-
-  void addWeapon(Weapon* weapon, int configID = W_CONFIG0, int slotID = W_FREE_SLOT);
-  void removeWeapon(Weapon* weapon, int configID = W_CONFIG0);
-  void nextWeaponConf();
-
-  void fire();
-  void tick(float sec);
-  void draw();
-
- private:
-  int nrOfSlots;                        //<! number of weapon slots a ship has
-  int currConfID;                       //<! the currently selected config
-  weaponConfig configs[4];              //<! a list of four configurations
-
-  int getNextFreeSlot(int configID);
-};
-
-class Weapon : public WorldEntity
-{
-  friend class World;
-
- public:
-  Weapon (PNode* parent, const Vector& coordinate, const Quaternion& direction);
-  virtual ~Weapon ();
-
-  void enable();
-  void disable();
-  bool isEnabled();
-
-  void setProjectile(Projectile* projectile);
-  Projectile* getProjectile();
-
-  virtual void activate();
-  virtual void deactivate();
-  bool isActive();
-
-
-  /**
-     \brief sets a weapon idle time
-     \param idle time in ms
-
-     a weapon idle time is the time spend after a shoot until the weapon can
-     shoot again
-  */
-  inline void setWeaponIdleTime(float time) { this->idleTime = time; }
-  /**
-     \brief gets the weapon idle time
-     \returns idle time in ms
-
-     a weapon idle time is the time spend after a shoot until the weapon can
-     shoot again
-  */
-  inline float getWeaponIdleTime() const { return this->idleTime;}
-  /**
-     \brief checks if the idle time is elapsed
-     \return true if time is elapsed
-
-     a weapon idle time is the time spend after a shoot until the weapon can
-   shoot again
-  */
-  inline bool hasWeaponIdleTimeElapsed() const { return (this->localTime>this->idleTime)?true:false; }
-
-  /**
-     \brief fires the weapon
-
-     this is called from the player.cc, when fire-button is been pushed
-  */
-  virtual void fire() = 0;
-  virtual void hit (WorldEntity* weapon, Vector* loc);
-  virtual void destroy();
-
-  virtual void tick(float time);
-  virtual void weaponIdle();
-  virtual void draw();
-
- protected:
-  tList<WorldEntity>* worldEntities;
-  float localTime;                 //<! this is the local time. important for shooting attributes like frequency
-  float idleTime;                  //<! the time a weapon needs before it can shoot again. eg. shooting frequency or actication/deactivateion delay
-  float slowDownFactor;            //<! if the shooting frequency is a linear function of time...
-
-  PNode* objectComponent1;         //<! the gun is made of multiple parts, these PNodes represent their location and orientation
-  PNode* objectComponent2;
-  PNode* objectComponent3;
-
-  Animation3D* animation1;
-  Animation3D* animation2;
-  Animation3D* animation3;
-
-  Vector projectileOffset;
-  int leftRight;   // this will become an enum
-
-  SoundBuffer* fireSound;
-  SoundSource* weaponSource;
-
-
- private:
-  bool enabled;                    //<! states if the weapon is enabled or not
-  Projectile* projectile;          //<! the projectile used for this weapon
-  //WeaponSound sound;
-};
-
-#endif /* _WEAPON_H */
Index: orxonox/trunk/src/world_entities/weapons/projectile.cc
===================================================================
--- orxonox/trunk/src/world_entities/weapons/projectile.cc	(revision 4758)
+++ orxonox/trunk/src/world_entities/weapons/projectile.cc	(revision 4758)
@@ -0,0 +1,158 @@
+
+
+/*
+   orxonox - the future of 3D-vertical-scrollers
+
+   Copyright (C) 2004 orx
+
+   This program is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 2, or (at your option)
+   any later version.
+
+   ### File Specific
+   main-programmer: Patrick Boenzli
+   co-programmer:
+*/
+
+
+#include "projectile.h"
+
+#include "world_entity.h"
+#include "weapon.h"
+#include "null_parent.h"
+#include "model.h"
+#include "vector.h"
+
+using namespace std;
+
+
+/**
+   \brief standard constructor
+*/
+Projectile::Projectile (Weapon* weapon) : WorldEntity()
+{
+  this->setClassID(CL_PROJECTILE, "Projectile");
+
+  this->weapon = weapon;
+  this->flightDirection = NULL;
+  this->currentLifeTime = 0.0f;
+  this->ttl = 0.75f; /* sec */
+  this->speed = 2.0f;
+}
+
+
+/**
+   \brief standard deconstructor
+*/
+Projectile::~Projectile ()
+{
+  /*
+     do not delete the test projectModel, since it is pnode
+     and will be cleaned out by world
+  */
+  //delete this->projectileModel;
+}
+
+
+/**
+   \brief this sets the flight direction of the projectile
+   \param directin in which to flight
+
+   this function will calculate a vector out of this to be used in the
+   tick function
+*/
+void Projectile::setFlightDirection(Quaternion flightDirection)
+{
+  if( this->flightDirection == NULL)
+    this->flightDirection = new Vector();
+  Vector v(1, 0, 0);
+  *this->flightDirection = flightDirection.apply(v);
+  this->flightDirection->normalize();
+}
+
+
+/**
+   \brief this sets the time to life of the projectile
+   \param ttl in second
+
+   after this life time, the projectile will garbage collect itself
+*/
+void Projectile::setTTL(float ttl)
+{
+  this->ttl = ttl;
+}
+
+
+/**
+   \brief sets the speed of the projectile
+*/
+void Projectile::setSpeed(float speed)
+{
+  this->speed = speed * 3; /* fix speed settings */
+  PRINTF(4)("Projectile::setting speed to: %f\n", this->speed);
+}
+
+
+/**
+   \brief sets the velocity vector to a spec speed
+   \param velocity: vector of the velocity
+*/
+void Projectile::setVelocity(const Vector &velocity)
+{
+  this->offsetVel = this->velocity = velocity;
+  this->offsetVel.normalize();
+  this->velocity += (this->offsetVel * 50.0);
+}
+
+
+/**
+   \brief signal tick, time dependent things will be handled here
+   \param time since last tick
+*/
+void Projectile::tick (float time)
+{
+  Vector v = this->velocity * (time);
+  this->shiftCoor(v);
+
+  this->currentLifeTime += time;
+  if( this->ttl < this->currentLifeTime)
+    {
+      PRINTF(5)("FINALIZE==========================\n");
+      PRINTF(5)("current life time is: %f/%f\n", this->currentLifeTime, this->ttl);
+      PRINTF(5)("FINALIZE===========================\n");
+      this->finalize();
+      this->currentLifeTime = 0.0f;
+    }
+}
+
+/**
+   \brief the projectile gets hit by another entity
+   \param the other entity
+   \param place where it is hit
+*/
+void Projectile::hit (WorldEntity* entity, Vector* place)
+{}
+
+
+/**
+   \brief the function gets called, when the projectile is destroyed
+*/
+void Projectile::destroy ()
+{}
+
+
+void Projectile::draw ()
+{
+  glMatrixMode(GL_MODELVIEW);
+  glPushMatrix();
+
+  float matrix[4][4];
+  glTranslatef (this->getAbsCoor ().x, this->getAbsCoor ().y, this->getAbsCoor ().z);
+  this->getAbsDir().matrix (matrix);
+  glMultMatrixf((float*)matrix);
+  this->model->draw();
+
+  glPopMatrix();
+}
+
Index: orxonox/trunk/src/world_entities/weapons/projectile.h
===================================================================
--- orxonox/trunk/src/world_entities/weapons/projectile.h	(revision 4758)
+++ orxonox/trunk/src/world_entities/weapons/projectile.h	(revision 4758)
@@ -0,0 +1,60 @@
+/*!
+    \projectile.h
+    \brief a projectile, that is been shooted by a weapon
+
+    You can use this class to make some shoots, but this isn't the real idea. If you want to just test, if the
+    shooting funcions work, use the Projectile class. But if you want to implement your own shoots its
+    different:<br>
+    Make a new class and derive it from Projectile. To have a weapon work well, reimplement the functions
+    - void tick()
+    - void draw()
+    - void hit() (only if you have working collision detection)
+    When you have implemented these functions you have just to add the projectiles to your weapon. You ll want
+    to make this by looking into the function
+    - Weapon::fire()
+    there you just change the line:
+    Projectile* pj = new Projectile();    TO     Projectile* pj = new MyOwnProjectileClass();
+    and schwups it works... :)
+*/
+
+#ifndef _PROJECTILE_H
+#define _PROJECTILE_H
+
+#include "world_entity.h"
+#include "vector.h"
+
+class Vector;
+class Weapon;
+
+class Projectile : public WorldEntity
+{
+  friend class World;
+
+ public:
+  Projectile (Weapon* weapon);
+  virtual ~Projectile ();
+
+  void setFlightDirection(Quaternion flightDirection);
+  void setSpeed(float speed);
+  void setVelocity(const Vector &velocity);
+  void setTTL(float ttl);
+
+  virtual void hit (WorldEntity* weapon, Vector* loc);
+  virtual void destroy ();
+
+  virtual void tick (float time);
+  virtual void draw ();
+
+ protected:
+  //physical attriutes like: force, speed, acceleration etc.
+  float          speed;                     //!< this is the speed of the projectile
+  float          currentLifeTime;           //!< this is the time, the projectile exists in this world (incremented by tick)
+  float          ttl;                       //!< time to life, after this time, the projectile will garbage collect itself
+  Vector*        flightDirection;           //!< direction in which the shoot flights
+  Weapon*        weapon;                    //!< weapon the shoot belongs to
+
+  Vector         velocity;                  //!< velocity of the projectile
+  Vector         offsetVel;                 //!< offset velocity TEMP
+};
+
+#endif /* _PROJECTILE_H */
Index: orxonox/trunk/src/world_entities/weapons/test_bullet.cc
===================================================================
--- orxonox/trunk/src/world_entities/weapons/test_bullet.cc	(revision 4758)
+++ orxonox/trunk/src/world_entities/weapons/test_bullet.cc	(revision 4758)
@@ -0,0 +1,107 @@
+
+
+/*
+   orxonox - the future of 3D-vertical-scrollers
+
+   Copyright (C) 2004 orx
+
+   This program is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 2, or (at your option)
+   any later version.
+
+   ### File Specific
+   main-programmer: Patrick Boenzli
+   co-programmer:
+*/
+
+
+#include "test_bullet.h"
+
+#include "world_entity.h"
+#include "weapon.h"
+#include "null_parent.h"
+#include "model.h"
+#include "vector.h"
+
+using namespace std;
+
+
+/**
+   \brief standard constructor
+*/
+TestBullet::TestBullet (Weapon* weapon) : Projectile(weapon)
+{
+  this->setClassID(CL_TEST_BULLET, "TestBullet");
+
+  float modelSize = .5;
+  this->model = (Model*)ResourceManager::getInstance()->load("models/orx-rocket.obj", OBJ, RP_LEVEL, (void*) &modelSize);
+}
+
+
+/**
+   \brief standard deconstructor
+*/
+TestBullet::~TestBullet ()
+{
+  /*
+     do not delete the test projectModel, since it is pnode
+     and will be cleaned out by world
+  */
+  //delete this->projectileModel;
+}
+
+
+
+/**
+   \brief signal tick, time dependent things will be handled here
+   \param time since last tick
+*/
+void TestBullet::tick (float time)
+{
+  //Vector v = *this->flightDirection * ( this->speed * time * 1000 + 0.1);
+  Vector v = this->velocity * (time);
+  this->shiftCoor(v);
+
+  this->currentLifeTime += time;
+  if( this->ttl < this->currentLifeTime)
+    {
+      PRINTF(5)("FINALIZE==========================\n");
+      PRINTF(5)("current life time is: %f/%f\n", this->currentLifeTime, this->ttl);
+      PRINTF(5)("FINALIZE===========================\n");
+      this->finalize();
+      this->currentLifeTime = 0.0f;
+    }
+}
+
+/**
+   \brief the projectile gets hit by another entity
+   \param the other entity
+   \param place where it is hit
+*/
+void TestBullet::hit (WorldEntity* entity, Vector* place)
+{}
+
+
+/**
+   \brief the function gets called, when the projectile is destroyed
+*/
+void TestBullet::destroy ()
+{}
+
+
+void TestBullet::draw ()
+{
+  glMatrixMode(GL_MODELVIEW);
+  glPushMatrix();
+
+  float matrix[4][4];
+  glTranslatef (this->getAbsCoor ().x, this->getAbsCoor ().y, this->getAbsCoor ().z);
+  this->getAbsDir().matrix (matrix);
+  glMultMatrixf((float*)matrix);
+  glScalef(2.0, 2.0, 2.0);
+  this->model->draw();
+
+  glPopMatrix();
+}
+
Index: orxonox/trunk/src/world_entities/weapons/test_bullet.h
===================================================================
--- orxonox/trunk/src/world_entities/weapons/test_bullet.h	(revision 4758)
+++ orxonox/trunk/src/world_entities/weapons/test_bullet.h	(revision 4758)
@@ -0,0 +1,30 @@
+/*! 
+    \projectile.h
+    \brief a projectile, that is been shooted by a weapon
+*/
+
+#ifndef _TEST_BULLET_H
+#define _TEST_BULLET_H
+
+#include "projectile.h"
+
+class Vector;
+class Weapon;
+
+class TestBullet : public Projectile 
+{
+  friend class World;
+
+ public:
+  TestBullet (Weapon* weapon);
+  virtual ~TestBullet ();
+
+  virtual void hit (WorldEntity* weapon, Vector* loc);
+  virtual void destroy ();
+
+  virtual void tick (float time);
+  virtual void draw ();
+  
+};
+
+#endif /* _TEST_BULLET_H */
Index: orxonox/trunk/src/world_entities/weapons/test_gun.cc
===================================================================
--- orxonox/trunk/src/world_entities/weapons/test_gun.cc	(revision 4758)
+++ orxonox/trunk/src/world_entities/weapons/test_gun.cc	(revision 4758)
@@ -0,0 +1,234 @@
+
+
+/*
+   orxonox - the future of 3D-vertical-scrollers
+
+   Copyright (C) 2004 orx
+
+   This program is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 2, or (at your option)
+   any later version.
+
+   ### File Specific
+   main-programmer: Patrick Boenzli
+   co-programmer:
+
+
+   \todo: direction in which the projectile flights
+   \todo: a target to set/hit
+*/
+
+
+#include "test_gun.h"
+
+#include "stdincl.h"
+#include "world_entity.h"
+#include "model.h"
+#include "test_bullet.h"
+
+#include "vector.h"
+#include "list.h"
+#include "animation3d.h"
+#include "sound_engine.h"
+
+#include "object_manager.h"
+
+using namespace std;
+
+
+/**
+   \brief standard constructor
+
+   creates a new weapon
+*/
+TestGun::TestGun (PNode* parent, const Vector& coordinate,
+                  const Quaternion& direction, int leftRight)
+  :  Weapon (parent, coordinate, direction)
+{
+  this->setClassID(CL_TEST_GUN, "TestGun");
+
+  this->model = (Model*)ResourceManager::getInstance()->load("models/test_gun.obj", OBJ, RP_CAMPAIGN);
+  this->idleTime = 0.2f;
+  this->leftRight = leftRight;
+
+  this->objectComponent1 = new PNode();
+  this->animation1 = new Animation3D(this->objectComponent1);
+  this->animation2 = new Animation3D(this);
+  this->animation3 = new Animation3D(this);
+  //parent->addChild(this->objectComponent1, PNODE_ALL);
+  this->addChild(this->objectComponent1, PNODE_ALL);
+
+  this->animation1->setInfinity(ANIM_INF_CONSTANT);
+  this->animation2->setInfinity(ANIM_INF_CONSTANT);
+  this->animation3->setInfinity(ANIM_INF_CONSTANT);
+  if( this->leftRight == W_LEFT)
+    {
+      this->projectileOffset = Vector(1.0, 0.0, -0.35);
+
+      this->animation1->addKeyFrame(Vector(0, 0, 0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
+      this->animation1->addKeyFrame(Vector(-0.4, 0, 0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
+      this->animation1->addKeyFrame(Vector(0, 0, 0), Quaternion(), 0.0, ANIM_LINEAR, ANIM_CONSTANT);
+
+      this->animation2->addKeyFrame(Vector(-2.6, 0.1, 2.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
+      this->animation2->addKeyFrame(Vector(-2.6, 0.1, 3.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
+
+      this->animation3->addKeyFrame(Vector(-2.6, 0.1, 3.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
+      this->animation3->addKeyFrame(Vector(-2.6, 0.1, 2.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
+    }
+  else if( this->leftRight == W_RIGHT)
+    {
+      this->projectileOffset = Vector(1.0, 0.0, 0.5);
+
+      this->objectComponent1->setRelCoor(Vector(0,0,0.35));
+      this->animation1->addKeyFrame(Vector(0, 0, .5), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
+      this->animation1->addKeyFrame(Vector(-0.4, 0, .5), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
+      this->animation1->addKeyFrame(Vector(0, 0, .5), Quaternion(), 0.0, ANIM_LINEAR, ANIM_CONSTANT);
+
+      this->animation2->addKeyFrame(Vector(-2.6, 0.1, -2.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
+      this->animation2->addKeyFrame(Vector(-2.6, 0.1, -3.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
+
+      this->animation3->addKeyFrame(Vector(-2.6, 0.1, -3.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
+      this->animation3->addKeyFrame(Vector(-2.6, 0.1, -2.0), Quaternion(), 0.1, ANIM_LINEAR, ANIM_CONSTANT);
+    }
+
+  this->fireSound = (SoundBuffer*)ResourceManager::getInstance()->load("sound/shot1.wav", WAV);
+  this->weaponSource = new SoundSource(this->fireSound, this);
+  this->weaponSource->setRolloffFactor(.1);
+  Projectile* p = new TestBullet(this);
+//  ObjectManager::getInstance()->cache(CL_TEST_BULLET, 100, p);
+  //ObjectManager::getInstance()->debug();
+}
+
+
+/**
+   \brief standard deconstructor
+*/
+TestGun::~TestGun ()
+{
+  // model will be deleted from WorldEntity-destructor
+}
+
+
+/**
+   \brief this activates the weapon
+
+   This is needed, since there can be more than one weapon on a ship. the
+   activation can be connected with an animation. for example the weapon is
+   been armed out.
+*/
+void TestGun::activate()
+{
+  this->animation2->replay();
+}
+
+
+/**
+   \brief this deactivates the weapon
+
+   This is needed, since there can be more than one weapon on a ship. the
+   activation can be connected with an animation. for example the weapon is
+   been armed out.
+*/
+void TestGun::deactivate()
+{
+  this->animation3->replay();
+}
+
+
+/**
+   \brief fires the weapon
+
+   this is called from the player.cc, when fire-button is been pushed
+   \todo: the ObjectManager deliveres Projectiles not TestBullets! this should be diffrent
+*/
+void TestGun::fire()
+{
+  if( !this->hasWeaponIdleTimeElapsed())
+    {
+      this->weaponIdle();
+      return;
+    }
+
+    Projectile* pj =  new TestBullet(this);//dynamic_cast<Projectile*>(ObjectManager::getInstance()->getFromDeadList(CL_TEST_BULLET & CL_MASK_LOWLEVEL_CLASS));
+  weaponSource->play();
+
+  pj->setAbsCoor(this->getAbsCoor() + this->projectileOffset);
+  pj->setAbsDir(this->getAbsDir());
+  pj->setVelocity(this->getVelocity());
+  this->worldEntities->add(pj);
+  this->localTime = 0;
+
+  this->animation1->replay();
+}
+
+
+/**
+   \brief is called, when the weapon gets hit (=collide with something)
+   \param from which entity it is been hit
+   \param where it is been hit
+
+   this may not be used, since it would make the game relay complicated when one
+   can destroy the weapons of enemies or vice versa.
+*/
+void TestGun::hit (WorldEntity* entity, Vector* position)
+{}
+
+
+/**
+   \brief is called, when the weapon is destroyed
+
+   this is in conjunction with the hit function, so when a weapon is able to get
+   hit, it can also be destoryed.
+*/
+void TestGun::destroy ()
+{}
+
+
+/**
+   \brief tick signal for time dependent/driven stuff
+*/
+void TestGun::tick (float time)
+{
+  this->localTime += time;
+}
+
+
+/**
+   \brief is called, when there is no fire button pressed
+*/
+void TestGun::weaponIdle()
+{}
+
+
+/**
+   \brief this will draw the weapon
+*/
+void TestGun::draw ()
+{
+  /* draw gun body */
+  glMatrixMode(GL_MODELVIEW);
+  glPushMatrix();
+  float matrix[4][4];
+  glTranslatef (this->getAbsCoor ().x,
+                this->getAbsCoor ().y,
+                this->getAbsCoor ().z);
+  this->getAbsDir ().matrix (matrix);
+  glMultMatrixf((float*)matrix);
+  if( this->leftRight == W_RIGHT)
+    glScalef(1.0, 1.0, -1.0);
+  this->model->draw(1);
+  glPopMatrix();
+
+  /* draw objectComponent1: gun coil - animated stuff */
+  glMatrixMode(GL_MODELVIEW);
+  glPushMatrix();
+  glTranslatef (this->objectComponent1->getAbsCoor ().x,
+                this->objectComponent1->getAbsCoor ().y,
+                this->objectComponent1->getAbsCoor ().z);
+  this->objectComponent1->getAbsDir ().matrix (matrix);
+  glMultMatrixf((float*)matrix);
+  this->model->draw(0);
+  glPopMatrix();
+}
+
Index: orxonox/trunk/src/world_entities/weapons/test_gun.h
===================================================================
--- orxonox/trunk/src/world_entities/weapons/test_gun.h	(revision 4758)
+++ orxonox/trunk/src/world_entities/weapons/test_gun.h	(revision 4758)
@@ -0,0 +1,58 @@
+/*! 
+    \file weapon.h
+    \brief a weapon that a player can use
+
+    A Player has a list of weapons, that can be choosen to shoot projectiles
+    (projectiles.{cc,h}) at ennemies. These weapons can be shooted sequentially
+    or (if able) combined. Therefore you can choose the weapon mode = choose
+    a weapon.
+
+    A weapon is characterized by:
+     o firing-rate: the initial firing rate of a weapon (1/s = Herz)
+     o slowdown-factor: this is a factor d: exp(-d*x), d is element of all positive R. it determines how fast the firing-rate will slow down. if no slowdown: d=0, the bigger d is, the faster the weapon will slow down!
+     o energy-consumption: this determines the energy that has to be used to produce this projectile = costs per projectile
+    
+    Furthermore there are some other attributes, that will help to represent a firing
+    weapon in this world:
+     o sound file/ressource: this is a pointer to the sound-file/ressource. however it may be represented
+     o shooting animation
+     
+*/
+
+
+#ifndef _TEST_GUN_H
+#define _TEST_GUN_H
+
+#include "weapon.h"
+
+class Projectile;
+class Vector;
+class Quaternion;
+class Animation3D;
+
+
+class TestGun : public Weapon
+{
+  friend class World;
+
+ public:
+  TestGun (PNode* parent, const Vector& coordinate, const Quaternion& direction, int leftRight);
+  virtual ~TestGun ();
+
+  virtual void activate();
+  virtual void deactivate();
+
+  virtual void fire();
+  virtual void hit (WorldEntity* weapon, Vector* loc);
+  virtual void destroy();
+  
+  virtual void tick(float time);
+  virtual void weaponIdle();
+  virtual void draw();
+
+
+
+
+};
+
+#endif /* _TEST_GUN_H */
Index: orxonox/trunk/src/world_entities/weapons/weapon.cc
===================================================================
--- orxonox/trunk/src/world_entities/weapons/weapon.cc	(revision 4758)
+++ orxonox/trunk/src/world_entities/weapons/weapon.cc	(revision 4758)
@@ -0,0 +1,389 @@
+
+
+/*
+   orxonox - the future of 3D-vertical-scrollers
+
+   Copyright (C) 2004 orx
+
+   This program is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 2, or (at your option)
+   any later version.
+
+   ### File Specific
+   main-programmer: Patrick Boenzli
+   co-programmer:
+*/
+
+#define DEBUG_SPECIAL_MODULE DEBUG_MODULE_WEAPON
+
+#include "weapon.h"
+#include "stdincl.h"
+#include "world_entity.h"
+#include "vector.h"
+#include "model.h"
+#include "projectile.h"
+#include "list.h"
+#include "world.h"
+
+using namespace std;
+
+
+
+/**
+   \brief this initializes the weaponManager for a given nnumber of weapon slots
+   \param number of weapon slots of the model/ship <= 8 (limitied)
+*/
+WeaponManager::WeaponManager(int nrOfSlots)
+{
+  this->setClassID(CL_WEAPON_MANAGER, "WeaponManager");
+
+  for(int i = 0; i < W_MAX_CONFIGS; ++i)
+    {
+      this->configs[i].bUsed = false;
+      for(int j = 0; j < W_MAX_SLOTS; ++j)
+        this->configs[i].slots[j] = NULL;
+    }
+  this->nrOfSlots = nrOfSlots;
+  this->currConfID = W_CONFIG0;
+}
+
+
+WeaponManager::~WeaponManager()
+{
+  /*
+     i dont have to delete the weapons itself, because they are
+     worldentities and therefore in the entities list of the world.
+     world will clean them up for me
+  */
+  for(int i = 0; i < W_MAX_CONFIGS; ++i)
+    {
+      this->configs[i].bUsed = false;
+      for(int j = 0; j < W_MAX_SLOTS; ++j)
+        this->configs[i].slots[j] = NULL;
+    }
+}
+
+
+/**
+   \brief adds a weapon to the selected weaponconfiguration into the selected slot
+   \param the weapon to add
+   \param an identifier for the slot: number between 0..7 if not specified: slotID=next free slot
+   \param an identifier for the weapon configuration, number between 0..3
+
+   if you add explicitly a weapon at config:n, slot:m, the weapon placed at this location will be
+   replaced by the weapon specified. if you use the W_FREE_SLOT, the manager will look for a free
+   slot in this weaponconfiguration. if there is non, the weapon won't be added and there will be
+   a error message.
+*/
+void WeaponManager::addWeapon(Weapon* weapon, int configID, int slotID)
+{
+  if( slotID == W_FREE_SLOT)
+    {
+      int freeSlot = this->getNextFreeSlot( configID);
+      if( freeSlot < 0 || freeSlot >= this->nrOfSlots)
+        {
+          PRINTF(0)("There is no free slot in this WeaponConfig to dock this weapon at! Aborting\n");
+          return;
+        }
+      PRINTF(3)("Added new Weapon to Config:%i/Slot:%i\n", configID, freeSlot);
+      this->configs[configID].bUsed = true;
+      this->configs[configID].slots[freeSlot] = weapon;
+      return;
+    }
+  this->configs[configID].bUsed = true;
+  this->configs[configID].slots[slotID] = weapon;
+  PRINTF(3)("Added a new Weapon to the WeaponManager: config %i/ slot %i\n", configID, slotID);
+}
+
+
+void WeaponManager::removeWeapon(Weapon* weapon, int configID)
+{
+  /* empty */
+}
+
+
+/**
+   \brief changes to the next weapon configuration
+
+   if there are multiple weapon configurations defined by the manager, use this to switch between them
+   this function will deactivate the weapons first, change the config and reactivate them later
+*/
+void WeaponManager::nextWeaponConf()
+{
+  PRINTF(4)("Changing weapon configuration: from %i to next\n", this->currConfID);
+
+  int i, lastConfID;
+  lastConfID = this->currConfID;
+  for(i = this->currConfID + 1; i < W_MAX_CONFIGS && !this->configs[i].bUsed; ++i);
+  if( i == W_MAX_CONFIGS) this->currConfID = W_CONFIG0;
+  else this->currConfID = i;
+
+
+  Weapon *w1, *w2;
+  for(int j = 0; j < W_MAX_SLOTS; ++j)
+    {
+      w1 = this->configs[lastConfID].slots[j];
+      w2 = this->configs[this->currConfID].slots[j];
+
+      if( w1 == w2)
+        {
+          printf("no need for change\n");
+        }
+      else
+        {
+        if( w1 != NULL )
+          {
+            w1->deactivate();
+            printf("deactivating %i,%i\n", j,lastConfID);
+          }
+        if( w2 != NULL)
+          {
+            w2->activate();
+            printf("activating %i,%i\n", j, this->currConfID);
+          }
+        }
+    }
+}
+
+
+
+/**
+   \brief triggers fire of all weapons in the current weaponconfig
+*/
+void WeaponManager::fire()
+{
+  Weapon* firingWeapon;
+  for(int i = 0; i < W_MAX_SLOTS; ++i)
+    {
+      firingWeapon = this->configs[this->currConfID].slots[i];
+      if( firingWeapon != NULL) firingWeapon->fire();
+    }
+}
+
+
+/**
+   \brief triggers tick of all weapons in the current weaponconfig
+   \param second passed since last tick
+*/
+void WeaponManager::tick(float sec)
+{
+  Weapon* w;
+  for(int i = 0; i < W_MAX_SLOTS; ++i)
+    {
+      w = this->configs[this->currConfID].slots[i];
+      if( w != NULL) w->tick(sec);
+    }
+}
+
+
+/**
+   \brief triggers draw of all weapons in the current weaponconfig
+*/
+void WeaponManager::draw()
+{
+  Weapon* w;
+  for(int i = 0; i < W_MAX_SLOTS; ++i)
+    {
+      w = this->configs[this->currConfID].slots[i];
+      if( w != NULL) w->draw();
+    }
+}
+
+
+/**
+   \brief private gets the next free slot in a certain weaponconfig
+   \param the selected weaponconfig
+*/
+int WeaponManager::getNextFreeSlot(int configID)
+{
+  for( int i = 0; i < W_MAX_SLOTS; ++i)
+    {
+      if( this->configs[configID].slots[i] == NULL)
+        return i;
+    }
+  return -1;
+}
+
+
+
+
+
+
+/**
+   \brief standard constructor
+
+   creates a new weapon
+*/
+Weapon::Weapon (PNode* parent, const Vector& coordinate, const Quaternion& direction)
+  : WorldEntity()
+{
+  parent->addChild(this, PNODE_ALL);
+  this->setRelCoor(coordinate);
+  this->setRelDir(direction);
+  WorldInterface* wi = WorldInterface::getInstance();
+  this->worldEntities = wi->getEntityList();
+
+  this->objectComponent1 = NULL;
+  this->objectComponent2 = NULL;
+  this->objectComponent3 = NULL;
+
+  this->animation1 = NULL;
+  this->animation2 = NULL;
+  this->animation3 = NULL;
+}
+
+
+/**
+   \brief standard deconstructor
+*/
+Weapon::~Weapon ()
+{
+  // model will be deleted from WorldEntity-destructor
+  //this->worldEntities = NULL;
+
+  /* dont delete objectComponentsX here, they will be killed when the pnodes are cleaned out */
+
+  /* all animations are deleted via the animation player*/
+}
+
+
+/**
+    \brief enables the weapon
+
+    a weapon can be enabled/disabled because of various reasons. if a weapon is
+    been enabled, it can interact in a world. elswhere it wont react to any
+    action.
+*/
+void Weapon::enable()
+{
+  this->enabled = true;
+}
+
+
+/**
+    \brief disables the weapon
+
+    a weapon can be enabled/disabled because of various reasons. if a weapon is
+    been enabled, it can interact in a world. elswhere it wont react to any
+    action.
+*/
+void Weapon::disable()
+{
+  this->enabled = false;
+}
+
+
+/**
+    \brief checks if the weapon is enabled
+    \returns true if enabled
+
+    a weapon can be ebabled/disabled because of various reasons. if a weapon is
+    been enabled, it can interact in a world. elswhere it wont react to any
+    action.
+*/
+bool Weapon::isEnabled()
+{
+  return this->enabled;
+}
+
+
+/**
+   \brief sets a new projectile to the weapon
+   \param new projectile for this weapon
+
+   weapon an projectile are independent, so you can combine them as you want
+*/
+void Weapon::setProjectile(Projectile* projectile)
+{
+  this->projectile = projectile;
+}
+
+
+/**
+   \brief sets a new projectile to the weapon
+   \returns the current projectile of this weapon
+
+   weapon an projectile are independent, so you can combine them as you want
+*/
+Projectile* Weapon::getProjectile()
+{
+  return this->projectile;
+}
+
+
+/**
+   \brief this activates the weapon
+
+   This is needed, since there can be more than one weapon on a ship. the
+   activation can be connected with an animation. for example the weapon is
+   been armed out.
+*/
+void Weapon::activate()
+{}
+
+
+/**
+   \brief this deactivates the weapon
+
+   This is needed, since there can be more than one weapon on a ship. the
+   activation can be connected with an animation. for example the weapon is
+   been armed out.
+*/
+void Weapon::deactivate()
+{}
+
+/**
+   \brief asks if the current weapon is active
+   \returns true if it the weapon is active
+*/
+bool Weapon::isActive()
+{}
+
+
+
+
+
+
+/**
+   \brief is called, when the weapon gets hit (=collide with something)
+   \param from which entity it is been hit
+   \param where it is been hit
+
+   this may not be used, since it would make the game relay complicated when one
+   can destroy the weapons of enemies or vice versa.
+*/
+void Weapon::hit (WorldEntity* entity, Vector* position)
+{}
+
+
+/**
+   \brief is called, when the weapon is destroyed
+
+   this is in conjunction with the hit function, so when a weapon is able to get
+   hit, it can also be destoryed.
+*/
+void Weapon::destroy ()
+{}
+
+
+/**
+   \brief tick signal for time dependent/driven stuff
+*/
+void Weapon::tick (float time)
+{}
+
+
+/**
+   \brief is called, when there is no fire button pressed
+*/
+void Weapon::weaponIdle()
+{}
+
+
+/**
+   \brief this will draw the weapon
+*/
+void Weapon::draw ()
+{}
+
Index: orxonox/trunk/src/world_entities/weapons/weapon.h
===================================================================
--- orxonox/trunk/src/world_entities/weapons/weapon.h	(revision 4758)
+++ orxonox/trunk/src/world_entities/weapons/weapon.h	(revision 4758)
@@ -0,0 +1,188 @@
+/*!
+    \file weapon.h
+    \brief a weapon that a player can use
+
+    A Player has a list of weapons, that can be choosen to shoot projectiles
+    (projectiles.{cc,h}) at ennemies. These weapons can be shooted sequentially
+    or (if able) combined. Therefore you can choose the weapon mode = choose
+    a weapon.
+
+    A weapon is characterized by:
+     o firing-rate: the initial firing rate of a weapon (1/s = Herz)
+     o slowdown-factor: this is a factor d: exp(-d*x), d is element of all positive R. it determines how fast the firing-rate will slow down. if no slowdown: d=0, the bigger d is, the faster the weapon will slow down!
+     o energy-consumption: this determines the energy that has to be used to produce this projectile = costs per projectile
+
+    Furthermore there are some other attributes, that will help to represent a firing
+    weapon in this world:
+     o sound file/ressource: this is a pointer to the sound-file/ressource. however it may be represented
+     o shooting animation
+
+
+     a player defines one or more weapon configurations. a player has got one to eight
+     weapon slots: places where weapons can be attached to. a weapon configuration
+     is a matching between weapons and slots.
+     Since its clear how many weapons a player will have, there is no list of weapons:
+     its hard coded and limited to 8 slots and 4 configs. More would be a waste of
+     memory and time you need to customize and change to a weapon config...
+*/
+
+
+#ifndef _WEAPON_H
+#define _WEAPON_H
+
+#include "base_object.h"
+#include "world_entity.h"
+
+#define W_MAX_SLOTS 8
+#define W_MAX_CONFIGS 4
+
+class Projectile;
+class Weapon;
+class Animation3D;
+
+typedef enum {
+  SHOOT,
+  EMPTY,
+  RELOAD,
+  SPECIAL1,
+  SPECIAL2,
+  SPECIAL3
+} weaponSoundType;
+
+
+//! this is an identifier for the slot. there are up to 8 weapon slots -> this means there can't be more than 8 weapons at the same time
+#define W_SLOT0 0
+#define W_SLOT1 1
+#define W_SLOT2 2
+#define W_SLOT3 3
+#define W_SLOT4 4
+#define W_SLOT5 5
+#define W_SLOT6 6
+#define W_SLOT7 7
+#define W_FREE_SLOT 99
+
+
+//! this is an identifier for the weapon config
+#define W_CONFIG0 0
+#define W_CONFIG1 1
+#define W_CONFIG2 2
+#define W_CONFIG3 3
+
+//! a weapon can be left or right sided
+#define W_LEFT 0
+#define W_RIGHT 1
+
+//! this is a weapon Configuration: it has up to 8 slots
+typedef struct weaponConfig {
+  bool bUsed;                       //<! is set to true, if this configuration is
+  Weapon* slots[8];
+};
+
+
+class WeaponManager : public BaseObject {
+ public:
+  WeaponManager(int nrOfSlots = 2);
+  ~WeaponManager();
+
+  void addWeapon(Weapon* weapon, int configID = W_CONFIG0, int slotID = W_FREE_SLOT);
+  void removeWeapon(Weapon* weapon, int configID = W_CONFIG0);
+  void nextWeaponConf();
+
+  void fire();
+  void tick(float sec);
+  void draw();
+
+ private:
+  int nrOfSlots;                        //<! number of weapon slots a ship has
+  int currConfID;                       //<! the currently selected config
+  weaponConfig configs[4];              //<! a list of four configurations
+
+  int getNextFreeSlot(int configID);
+};
+
+class Weapon : public WorldEntity
+{
+  friend class World;
+
+ public:
+  Weapon (PNode* parent, const Vector& coordinate, const Quaternion& direction);
+  virtual ~Weapon ();
+
+  void enable();
+  void disable();
+  bool isEnabled();
+
+  void setProjectile(Projectile* projectile);
+  Projectile* getProjectile();
+
+  virtual void activate();
+  virtual void deactivate();
+  bool isActive();
+
+
+  /**
+     \brief sets a weapon idle time
+     \param idle time in ms
+
+     a weapon idle time is the time spend after a shoot until the weapon can
+     shoot again
+  */
+  inline void setWeaponIdleTime(float time) { this->idleTime = time; }
+  /**
+     \brief gets the weapon idle time
+     \returns idle time in ms
+
+     a weapon idle time is the time spend after a shoot until the weapon can
+     shoot again
+  */
+  inline float getWeaponIdleTime() const { return this->idleTime;}
+  /**
+     \brief checks if the idle time is elapsed
+     \return true if time is elapsed
+
+     a weapon idle time is the time spend after a shoot until the weapon can
+   shoot again
+  */
+  inline bool hasWeaponIdleTimeElapsed() const { return (this->localTime>this->idleTime)?true:false; }
+
+  /**
+     \brief fires the weapon
+
+     this is called from the player.cc, when fire-button is been pushed
+  */
+  virtual void fire() = 0;
+  virtual void hit (WorldEntity* weapon, Vector* loc);
+  virtual void destroy();
+
+  virtual void tick(float time);
+  virtual void weaponIdle();
+  virtual void draw();
+
+ protected:
+  tList<WorldEntity>* worldEntities;
+  float localTime;                 //<! this is the local time. important for shooting attributes like frequency
+  float idleTime;                  //<! the time a weapon needs before it can shoot again. eg. shooting frequency or actication/deactivateion delay
+  float slowDownFactor;            //<! if the shooting frequency is a linear function of time...
+
+  PNode* objectComponent1;         //<! the gun is made of multiple parts, these PNodes represent their location and orientation
+  PNode* objectComponent2;
+  PNode* objectComponent3;
+
+  Animation3D* animation1;
+  Animation3D* animation2;
+  Animation3D* animation3;
+
+  Vector projectileOffset;
+  int leftRight;   // this will become an enum
+
+  SoundBuffer* fireSound;
+  SoundSource* weaponSource;
+
+
+ private:
+  bool enabled;                    //<! states if the weapon is enabled or not
+  Projectile* projectile;          //<! the projectile used for this weapon
+  //WeaponSound sound;
+};
+
+#endif /* _WEAPON_H */
