]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Wops, add client part of last commit too
authorJakob MG <jakob_mg@hotmail.com>
Tue, 11 Oct 2011 09:19:15 +0000 (11:19 +0200)
committerJakob MG <jakob_mg@hotmail.com>
Tue, 11 Oct 2011 09:19:15 +0000 (11:19 +0200)
qcsrc/client/damage.qc
qcsrc/client/hud.qc

index 1617e4923d8940503b7e0c9d8b3d4e49707ffc81..51029396a299e46ce1270781b905ed7c9db99f25 100644 (file)
@@ -145,6 +145,7 @@ void Ent_DamageInfo(float isNew)
        
        if(DEATH_ISTURRET(w_deathtype))
        {           
+           string _snd;
            traceline(w_org - normalize(force) * 16, w_org + normalize(force) * 16, MOVE_NOMONSTERS, world);
            if(trace_plane_normal != '0 0 0')       
             w_backoff = trace_plane_normal;
@@ -157,20 +158,13 @@ void Ent_DamageInfo(float isNew)
            {   
              case DEATH_TURRET_EWHEEL:
                 sound(self, CH_SHOTS, "weapons/laserimpact.wav", VOL_BASE, ATTN_MIN);
-                pointparticles(particleeffectnum("electro_impact"), self.origin, w_backoff * 1000, 1);
+                pointparticles(particleeffectnum("laser_impact"), self.origin, w_backoff * 1000, 1);
                 break;
              
              case DEATH_TURRET_FLAC:
-                vector org2;
-                org2 = w_org + w_backoff * 6;
-                pointparticles(particleeffectnum("hagar_explode"), org2, '0 0 0', 1);
-                if (w_random<0.15)
-                    sound(self, CH_SHOTS, "weapons/hagexp1.wav", VOL_BASE, ATTN_NORM);
-                else if (w_random<0.7)
-                    sound(self, CH_SHOTS, "weapons/hagexp2.wav", VOL_BASE, ATTN_NORM);
-                else
-                    sound(self, CH_SHOTS, "weapons/hagexp3.wav", VOL_BASE, ATTN_NORM);
-                
+                pointparticles(particleeffectnum("hagar_explode"), w_org, '0 0 0', 1);
+                _snd = strcat("weapons/hagexp", ftos(1 + rint(random() * 2)), ".waw");
+                sound(self, CH_SHOTS, _snd, VOL_BASE, ATTN_NORM);                
                 break;
                 
              case DEATH_TURRET_MLRS:
@@ -183,7 +177,6 @@ void Ent_DamageInfo(float isNew)
              
              case DEATH_TURRET_MACHINEGUN:
              case DEATH_TURRET_WALKER_GUN:
-                string _snd;
                 _snd = strcat("weapons/ric", ftos(1 + rint(random() * 2)), ".waw");
                 sound(self, CH_SHOTS, _snd, VOL_BASE, ATTN_NORM);
                 pointparticles(particleeffectnum("machinegun_impact"), self.origin, w_backoff * 1000, 1);
index 7b843d973fea568d67993f8ebebec1a4a55aeb64..be900d4a5326d20bf5b6062b0827a1d260cbdace 100644 (file)
@@ -1789,10 +1789,56 @@ void HUD_KillNotify(string s1, string s2, string s3, float type, float msg) // s
                                else
                                        print (sprintf(_("^1%s^1 is now conserved for centuries to come\n"), s1));
                        }
-               } else if(type == DEATH_TURRET) {
+               } else if(DEATH_ISTURRET(type)) {
                        HUD_KillNotify_Push(s1, "", 0, DEATH_GENERIC);
                        if(alsoprint)
-                               print (sprintf(_("^1%s^1 was mowed down by a turret \n"), s1));
+                       {
+                           if(gentle)
+                    print (sprintf(_("^1%s^1 ran into a turret\n"), s1));
+                else
+                {                                
+                    switch(type)
+                    {
+                        case DEATH_TURRET_EWHEEL:
+                            print (sprintf(_("^1%s^1 was laserd down by a eWheel turret \n"), s1));
+                            break;
+                        case DEATH_TURRET_FLAC:
+                            print (sprintf(_("^1%s^1 got caught in the flac \n"), s1));
+                            break;
+                        case DEATH_TURRET_MACHINEGUN:
+                            print (sprintf(_("^1%s^1 was riddeld full of riddled by a machinegun turret \n"), s1));
+                            break;
+                        case DEATH_TURRET_WALKER_GUN:
+                            print (sprintf(_("^1%s^1 got served a led enrichment by a walker turret \n"), s1));
+                            break;
+                        case DEATH_TURRET_WALKER_MEELE:
+                            print (sprintf(_("^1%s^1 was impaled by a walker turret \n"), s1));
+                            break;
+                        case DEATH_TURRET_WALKER_ROCKET:
+                            print (sprintf(_("^1%s^1 was rocketed to hell by a walker turret \n"), s1));
+                            break;
+                        case DEATH_TURRET_HELLION:
+                            print (sprintf(_("^1%s^1 was blasted away hellion turret \n"), s1));
+                            break;
+                        case DEATH_TURRET_HK:
+                            print (sprintf(_("^1%s^1 could not hide from the hunter turret \n"), s1));
+                            break;
+                        case DEATH_TURRET_MLRS:
+                            print (sprintf(_("^1%s^1 got turned into smoldering gibs by a mlrs turret \n"), s1));
+                            break;
+                        case DEATH_TURRET_PLASMA:
+                            print (sprintf(_("^1%s^1 got served some superheated plasma from a plasma turret \n"), s1));
+                            break;
+                        case DEATH_TURRET_PHASER:
+                            print (sprintf(_("^1%s^1 was phased out \n"), s1));
+                            break;
+                        case DEATH_TURRET_TESLA:                               
+                            print (sprintf(_("^1%s^1 was electrocuted by a tesla turret \n"), s1));
+                            break;
+                    }
+                }
+                       }
+                               
                } else if (type == DEATH_CUSTOM) {
                        HUD_KillNotify_Push(s1, "", 0, DEATH_CUSTOM);
                        if(alsoprint)
@@ -2460,7 +2506,7 @@ void HUD_Radar(void)
        draw_teamradar_player(view_origin, view_angles, '1 1 1');
 
        drawresetcliparea();
-}
+};
 
 // Score (#7)
 //