Index: code/branches/clangenb/data/levels/emptyLevel.oxw
===================================================================
--- code/branches/clangenb/data/levels/emptyLevel.oxw	(revision 10491)
+++ code/branches/clangenb/data/levels/emptyLevel.oxw	(revision 10494)
@@ -15,5 +15,5 @@
   include("templates/spaceshipAssff2.oxt")
   include("templates/spaceshipPirate.oxt")
-  include("templates/spaceshipEscort.oxt")
+  include("templates/spaceshipHeartAttack.oxt")
 ?>
 
@@ -30,6 +30,25 @@
 
     <Light type=directional position="0,0,0" direction="0.253, 0.593, -0.765" diffuse="1.0, 0.9, 0.9, 1.0" specular="1.0, 0.9, 0.9, 1.0"/>
-    <SpawnPoint team=0 position="-200,0,0" lookat="0,0,0" spawnclass=SpaceShip pawndesign=spaceshipescort />
-    
+    <SpawnPoint team=0 position="-200,0,0" lookat="0,0,0" spawnclass=SpaceShip pawndesign=spaceshipHeartAttack />
+    <SpaceShip position="0,2000,200" lookat="0,0,0" name="movingtarget" radarname="Pirate">
+                            <events>
+                                <visibility>
+                                    <EventListener event="boxtrigger4" />
+                                </visibility>
+                            </events>
+                    <templates>
+                      <Template link=spaceshippirate />
+                    </templates>
+                    <controller>
+                      <WaypointController team=1>
+                         <waypoints>
+                          <Model mesh="cube.mesh" scale=8 position="  0,1700,-200" />
+                          <Model mesh="cube.mesh" scale=8 position="  0,1700,-700" />
+                          <Model mesh="cube.mesh" scale=8 position="500,1700,-700" />
+                          <Model mesh="cube.mesh" scale=8 position="500,1700,-200" />
+                       </waypoints>
+                    </WaypointController>
+                  </controller>
+                </SpaceShip>
   </Scene>
 </Level>
Index: code/branches/clangenb/data/levels/includes/weaponSettingsAssff.oxi
===================================================================
--- code/branches/clangenb/data/levels/includes/weaponSettingsAssff.oxi	(revision 10491)
+++ code/branches/clangenb/data/levels/includes/weaponSettingsAssff.oxi	(revision 10494)
@@ -25,4 +25,5 @@
           </attached>
           <HsW01 mode=0 munitionpershot=0 delay=0.125 damage=3.14159 material="Flares/point_lensflare" muzzleoffset=" 0.1, 1.6,-2" />
+          <EnergyDrink mode=0 munitionpershot=0 delay=0  material="Flares/point_lensflare" muzzleoffset="2,-0.2,-1" />
           <HsW01 mode=0 munitionpershot=0 delay=0     damage=3.14159 material="Flares/point_lensflare" muzzleoffset="-1.6, 1.3,-2" />
           <LightningGun mode=1 muzzleoffset="0,0,0" damage=3.14159 shielddamage=20 />
@@ -39,5 +40,7 @@
         </Weapon>
         <Weapon>
-          <SimpleRocketFire mode=2 muzzleoffset="0,0,0" damage=30 shielddamage=20 />
+          <!--SimpleRocketFire mode=2 muzzleoffset="0,0,0" damage=30 shielddamage=20 /-->
+	  <LaserFire mode=2 muzzleoffset="5,5,0" damage=30 shielddamage=20 />
+	  <FusionFire mode=2 muzzleoffset="0,0,0" damage=30 shielddamage=20 />
           <RocketFire mode=3 muzzleoffset="0,0,0" damage=30 healthdamage=50 shielddamage=20 />
         </Weapon>
Index: code/branches/clangenb/data/levels/includes/weaponSettingsHeartAttack.oxi
===================================================================
--- code/branches/clangenb/data/levels/includes/weaponSettingsHeartAttack.oxi	(revision 10494)
+++ code/branches/clangenb/data/levels/includes/weaponSettingsHeartAttack.oxi	(revision 10494)
@@ -0,0 +1,52 @@
+    <weaponslots>
+     	<WeaponSlot position=" 0, 0, 0" />
+      	<WeaponSlot position=" 0, 0, 0" />
+      	<WeaponSlot position=" 0, 0, 0" />
+	<WeaponSlot position=" 0, 0, 0" />
+    </weaponslots>
+    <weaponsets>
+      <WeaponSet firemode=0 />
+      <WeaponSet firemode=1 />
+      <WeaponSet firemode=2 />
+      <WeaponSet firemode=3 />
+    </weaponsets>
+    <weapons>
+      <WeaponPack>
+        <links>
+          <DefaultWeaponmodeLink firemode=0 weaponmode=0 />
+          <DefaultWeaponmodeLink firemode=1 weaponmode=1 />
+          <DefaultWeaponmodeLink firemode=2 weaponmode=2 />
+          <DefaultWeaponmodeLink firemode=3 weaponmode=3 />
+        </links>
+        <Weapon>
+          	<HsW01 mode=0 munitionpershot=0 delay=0.125 damage=3.14159 material="Flares/point_lensflare" muzzleoffset=" -11.4, 0, -5" />
+          	<HsW01 mode=0 munitionpershot=0 delay=0     damage=3.14159 material="Flares/point_lensflare" muzzleoffset=" -11.4, 0, -5" />
+		<HsW01 mode=0 munitionpershot=0 delay=0     damage=3.14159 material="Flares/point_lensflare" muzzleoffset=" 11.4, 0, -5" />
+          	<HsW01 mode=0 munitionpershot=0 delay=0.125 damage=3.14159 material="Flares/point_lensflare" muzzleoffset=" 11.4, 0, -5" />
+        </Weapon>
+        <Weapon>
+		<HsW01 mode=0 munitionpershot=0 delay=0.125 damage=3.14159 material="Flares/point_lensflare" muzzleoffset=" -15, 1.6, -2" />
+          	<HsW01 mode=0 munitionpershot=0 delay=0     damage=3.14159 material="Flares/point_lensflare" muzzleoffset=" -15, 1.6, -2" />
+		<HsW01 mode=0 munitionpershot=0 delay=0     damage=3.14159 material="Flares/point_lensflare" muzzleoffset=" 15, 1.6, -2" />
+          	<HsW01 mode=0 munitionpershot=0 delay=0.125 damage=3.14159 material="Flares/point_lensflare" muzzleoffset=" 15, 1.6, -2" />
+        </Weapon>
+        <Weapon>
+	  	<LaserFire mode=1 munitionpershot=0 muzzleoffset="2.2,6,16" damage=30 shielddamage=20 />
+	  	<LaserFire mode=1 munitionpershot=0 muzzleoffset="-2.2,6,16" damage=30 shielddamage=20 />
+          	<RocketFire mode=3 muzzleoffset="0,0,0" damage=30 healthdamage=50 shielddamage=20 />
+		
+        </Weapon>
+	<Weapon>
+		
+		
+	</Weapon>
+      </WeaponPack>
+      <WeaponPack>
+        <links>
+          <DefaultWeaponmodeLink firemode=1 weaponmode=0 />
+        </links>
+        <!--Weapon>
+          <EnergyDrink mode=0 munitionpershot=0 delay=0  material="Flares/point_lensflare"muzzleoffset="2,-0.2,-1" />
+        </Weapon-->
+      </WeaponPack>
+    </weapons>
Index: code/branches/clangenb/data/levels/templates/spaceshipHeartAttack.oxt
===================================================================
--- code/branches/clangenb/data/levels/templates/spaceshipHeartAttack.oxt	(revision 10494)
+++ code/branches/clangenb/data/levels/templates/spaceshipHeartAttack.oxt	(revision 10494)
@@ -0,0 +1,125 @@
+<Template name=spaceshipHeartAttack>
+  <SpaceShip
+   hudtemplate            = spaceshiphud
+   camerapositiontemplate = spaceshipassffcameras
+   spawnparticlesource    = "Orxonox/fairytwirl"
+   spawnparticleduration  = 3
+   explosionchunks        = 6
+
+   health            = 200
+   maxhealth         = 300
+   initialhealth     = 150
+
+   shieldhealth        = 50
+   initialshieldhealth = 50
+   maxshieldhealth     = 800
+   shieldabsorption    = 0.8
+   reloadrate          = 1
+   reloadwaittime      = 1
+
+   primaryThrust     = 40
+   auxilaryThrust    = 30
+   rotationThrust    = 35
+
+   lift = 1;
+   stallSpeed = 220;
+
+   boostPower            = 15
+   boostPowerRate        = 1
+   boostRate             = 5
+   boostCooldownDuration = 10
+
+   shakeFrequency = 15
+   shakeAmplitude = 9
+
+   collisionType     = "dynamic"
+   mass              = 100
+   linearDamping     = 0.7
+   angularDamping    = 0.9999999
+
+   explosionSound = "sounds/Explosion2.ogg"
+  >
+    <engines>
+      <MultiStateEngine position=" 7.6, 0, 19" template=spaceshipheartattackengine />
+      <MultiStateEngine position="-7.6, 0, 19" template=spaceshipheartattackengine />
+    </engines>
+    <attached>
+      <Model position="0,0,0" yaw=90 pitch=0 roll=0 scale=4 mesh="HeartAttack.mesh" />
+      <!--BlinkingBillboard position="17,-1.5,0" material="Examples/Flare" colour="1.0, 0.5, 0.3" amplitude=0.1 frequency=0.5 quadratic=1 />
+      <BlinkingBillboard position="-17,-1.5,0" material="Examples/Flare" colour="0.5, 1.0, 0.3" amplitude=0.1 frequency=0.5 phase=180 quadratic=1 /-->
+    </attached>
+    <collisionShapes>
+      	<BoxCollisionShape position="0,0.8,6"      halfExtents="12, 3, 10" />
+      	<BoxCollisionShape position="0,0.1,-11"  halfExtents="2.2, 1.8, 6" />
+	<BoxCollisionShape position="4.7,1,-8"      halfExtents="2, 3, 5" />
+	<BoxCollisionShape position="-4.7,1,-8"      halfExtents="2, 3, 5" />
+      	<BoxCollisionShape position="13.5,1,5"  halfExtents="1.4, 3, 7" />
+	<BoxCollisionShape position="-13.5,1,5"  halfExtents="1.4, 3, 7" />
+	<BoxCollisionShape position="16,2,4"  halfExtents="1.4, 1.5, 4" />
+	<BoxCollisionShape position="-16,2,4"  halfExtents="1.4, 1.5, 4" />
+	<BoxCollisionShape position="-2.8,5,4"  halfExtents="1.4, 1.5, 2" />
+	<BoxCollisionShape position="2.8,5,4"  halfExtents="1.4, 1.5, 2" />
+	<BoxCollisionShape position="5,5,4.3"  halfExtents="1.4, 1.5, 1.4" />
+	<BoxCollisionShape position="-5,5,4.3"  halfExtents="1.4, 1.5, 1.4" />
+    </collisionShapes>
+<?lua
+  include("../includes/weaponSettingsHeartAttack.oxi")
+?>
+  </SpaceShip>
+</Template>
+
+<Template name=spaceshipassffcameras defaults=0>
+  <SpaceShip>
+    <camerapositions>
+      <CameraPosition position="0,10, 40" drag=true mouselook=true />
+      <CameraPosition position="0,20, 80" drag=true mouselook=true />
+      <CameraPosition position="0,30,120" drag=true mouselook=true />
+    </camerapositions>
+  </SpaceShip>
+</Template>
+
+<Template name=spaceshipheartattackengine baseclass=MultiStateEngine>
+  <MultiStateEngine
+   boostfactor    = 2
+
+   speedfront     = 150
+   speedback      =  50
+   speedleftright =  50
+   speedupdown    =  50
+
+   defEngineSndNormal = "sounds/Engine_low.ogg"
+   defEngineSndBoost = "sounds/Engine_high.ogg"
+   
+   accelerationfront     = 420
+   accelerationbrake     = 420
+   accelerationback      =  125
+   accelerationleftright =  125
+   accelerationupdown    =  125
+  >
+    <EffectContainer condition="idle">
+      <WorldSound mainstate="activity" source="sounds/Engine_idle.ogg" looping=1 active=false/>
+    </EffectContainer>
+    <EffectContainer condition="not idle">
+      <FadingBillboard mainstate=activity active=false scale=0.1 position="4, 1.9, 19" colour="0.2, 0.65, 1.0, 1.0" material="Examples/Flare" turnontime=0.5 turnofftime=0.5 />
+      <FadingBillboard mainstate=activity active=false scale=0.1 position="-4, 1.9, 19" colour="0.2, 0.65, 1.0, 1.0" material="Examples/Flare" turnontime=0.5 turnofftime=0.5 />
+    </EffectContainer>
+    <EffectContainer condition="normal or brake">
+
+    </EffectContainer>
+    <EffectContainer condition="normal or boost">
+      <Backlight mainstate=activity active=false scale=0.4 name=bltest position=" 4, 1.9, 19" colour="0.6, 0.2, 0, 1.0" width=15 length=1500 lifetime=2 elements=50 trailmaterial="Trail/backlighttrail" turnontime=1 turnofftime=1 material="Flares/ThrusterFlare1" />
+      <Backlight mainstate=activity active=false scale=0.4 name=bltest position="-4, 1.9, 19" colour="0.6, 0.2, 0, 1.0" width=15 length=1500 lifetime=2 elements=50 trailmaterial="Trail/backlighttrail" turnontime=1 turnofftime=1 material="Flares/ThrusterFlare1" />
+    </EffectContainer>
+    <EffectContainer condition="boost">
+      <Backlight mainstate=activity active=false scale=0.4 name=bltest position=" 4, 1.9, 19" colour="1, 0, 0, 0.5" width=20 length=1000 lifetime=1 elements=30 trailmaterial="Trail/backlighttrail" turnontime=1 turnofftime=1 material="Examples/Flare" />
+      <Backlight mainstate=activity active=false scale=0.4 name=bltest position="-4, 1.9, 19" colour="1, 0, 0, 1" width=20 length=1000 lifetime=1 elements=30 trailmaterial="Trail/backlighttrail" turnontime=1 turnofftime=1 material="Examples/Flare" />
+    </EffectContainer>
+   <EffectContainer condition="brake">
+      <FadingBillboard mainstate=activity active=false scale=0.3 position=" 4, 1.9, 19" colour="0.5, 0.0, 0.0, 0.3" material="Examples/Flare" turnontime=0.5 turnofftime=0.5 />
+      <FadingBillboard mainstate=activity active=false scale=0.3 position="-4, 1.9, 19" colour="0.5, 0.0, 0.0, 0.3" material="Examples/Flare" turnontime=0.5 turnofftime=0.5 />
+      <FadingBillboard mainstate=activity active=false scale=0.15 position=" 4, 1.9, 19" colour="1.0, 0.0, 0.0, 1.0" material="Flares/backlightflare" turnontime=0.5 turnofftime=0.5 />
+      <FadingBillboard mainstate=activity active=false scale=0.15 position="-4, 1.9, 19" colour="1.0, 0.0, 0.0, 1.0" material="Flares/backlightflare" turnontime=0.5 turnofftime=0.5 />
+    </EffectContainer>
+
+  </MultiStateEngine>
+</Template>
Index: code/branches/clangenb/src/modules/weapons/projectiles/Rocket.cc
===================================================================
--- code/branches/clangenb/src/modules/weapons/projectiles/Rocket.cc	(revision 10491)
+++ code/branches/clangenb/src/modules/weapons/projectiles/Rocket.cc	(revision 10494)
@@ -74,5 +74,5 @@
             // Create rocket model
             Model* model = new Model(this->getContext());
-            model->setMeshSource("rocket.mesh");
+            model->setMeshSource("can.mesh");
             model->scale(0.7f);
             this->attach(model);
Index: code/branches/clangenb/src/modules/weapons/weaponmodes/EnergyDrink.cc
===================================================================
--- code/branches/clangenb/src/modules/weapons/weaponmodes/EnergyDrink.cc	(revision 10491)
+++ code/branches/clangenb/src/modules/weapons/weaponmodes/EnergyDrink.cc	(revision 10494)
@@ -108,4 +108,5 @@
         model->setScale(5);
 
+	this->computeMuzzleParameters(this->getWeapon()->getWeaponPack()->getWeaponSystem()->getPawn()->getAimPosition());
         projectile->setOrientation(this->getMuzzleOrientation());
         projectile->setPosition(this->getMuzzlePosition());
Index: code/branches/clangenb/src/modules/weapons/weaponmodes/FusionFire.cc
===================================================================
--- code/branches/clangenb/src/modules/weapons/weaponmodes/FusionFire.cc	(revision 10491)
+++ code/branches/clangenb/src/modules/weapons/weaponmodes/FusionFire.cc	(revision 10494)
@@ -67,5 +67,6 @@
     {
         BillboardProjectile* projectile = new BillboardProjectile(this->getContext());
-
+	
+	this->computeMuzzleParameters(this->getWeapon()->getWeaponPack()->getWeaponSystem()->getPawn()->getAimPosition());
         projectile->setOrientation(this->getMuzzleOrientation());
         projectile->setPosition(this->getMuzzlePosition());
Index: code/branches/clangenb/src/modules/weapons/weaponmodes/LaserFire.cc
===================================================================
--- code/branches/clangenb/src/modules/weapons/weaponmodes/LaserFire.cc	(revision 10491)
+++ code/branches/clangenb/src/modules/weapons/weaponmodes/LaserFire.cc	(revision 10494)
@@ -66,4 +66,5 @@
         ParticleProjectile* projectile = new ParticleProjectile(this->getContext());
 
+	this->computeMuzzleParameters(this->getWeapon()->getWeaponPack()->getWeaponSystem()->getPawn()->getAimPosition());
         projectile->setOrientation(this->getMuzzleOrientation());
         projectile->setPosition(this->getMuzzlePosition());
