]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
do announcer messages for bullets only for the rifle
authorRudolf Polzer <divverent@alientrap.org>
Wed, 24 Nov 2010 20:15:36 +0000 (21:15 +0100)
committerRudolf Polzer <divverent@alientrap.org>
Wed, 24 Nov 2010 20:15:36 +0000 (21:15 +0100)
qcsrc/server/w_common.qc

index 600f260f434c212c4b99e0bd830cf5653b68703b..2dd97c831df1f86c613cdb90bc14f7cf682f710c 100644 (file)
@@ -180,16 +180,15 @@ void W_BallisticBullet_Hit (void)
                Damage(other, self, self.owner, self.dmg * f, self.projectiledeathtype, self.origin, self.dmg_force * normalize(self.velocity) * f);
                damage_headshotbonus = 0;
 
-               if(self.dmg_edge != 0)
+               if(headshot)
+                       f *= q;
+               if(DEATH_WEAPONOF(self.projectiledeathtype) == WEP_CAMPINGRIFLE)
                {
                        if(headshot)
-                       {       
-                               f *= q;
                                AnnounceTo(self.owner, "headshot");
-                       }
+                       if(yoda)
+                               AnnounceTo(self.owner, "awesome");
                }
-               if(yoda)
-                       AnnounceTo(self.owner, "awesome");
 
                // calculate hits for ballistic weapons
                if(g)