src/Player.cc
changeset 211 d5d52fb191e4
parent 209 68cc4248a508
child 212 4389c1e6b9b8
--- a/src/Player.cc	Fri Dec 05 06:28:25 2008 +0000
+++ b/src/Player.cc	Fri Dec 05 11:11:38 2008 +0000
@@ -38,13 +38,14 @@
     // here should be somehow considered which projectile it is
     if(!canShoot())
         return;
-    reloadTimer += 0;
+    reloadTimer += 50;
     Vector unitVectorAim = facingRight ? Vector(std::cos(aim), -std::sin(aim)) : 
             Vector(-std::cos(aim), -std::sin(aim));
     float shotspeed = 100*PHYSICS_TICK_MS/2;
     Vector shotRelativeVelocity = unitVectorAim * shotspeed;
     Vector shotVelocity = this->velocity + shotRelativeVelocity;
-    new Projectile(this->state, this->position, shotVelocity, true, 20);
+    Vector shotPosition = this->position + unitVectorAim*10;
+    new Projectile(this->state, shotPosition, shotVelocity, true, 20);
 }
 
 void LocalPlayer::handleMove (PlayerInput_Move input) {