From: Jakob MG Date: Tue, 11 Oct 2011 12:28:38 +0000 (+0200) Subject: Give turrets _shirt & glowmod insted of fugly colormod. Fix akward .team check (ons... X-Git-Tag: xonotic-v0.6.0~40^2~57 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=8d0e30c2437f613e13b76acc159ac8a9ada719ce;p=xonotic%2Fxonotic-data.pk3dir.git Give turrets _shirt & glowmod insted of fugly colormod. Fix akward .team check (ons related) --- diff --git a/models/turrets/base.tga b/models/turrets/base.tga index a48d18d59..a4f47c05b 100644 Binary files a/models/turrets/base.tga and b/models/turrets/base.tga differ diff --git a/models/turrets/base_shirt.tga b/models/turrets/base_shirt.tga new file mode 100644 index 000000000..2f4810e6c Binary files /dev/null and b/models/turrets/base_shirt.tga differ diff --git a/models/turrets/ewheel-base.tga b/models/turrets/ewheel-base.tga index e55675090..93a3d3523 100644 Binary files a/models/turrets/ewheel-base.tga and b/models/turrets/ewheel-base.tga differ diff --git a/models/turrets/ewheel-base_glow.tga b/models/turrets/ewheel-base_glow.tga new file mode 100644 index 000000000..6ca701694 Binary files /dev/null and b/models/turrets/ewheel-base_glow.tga differ diff --git a/models/turrets/ewheel-base_shirt.tga b/models/turrets/ewheel-base_shirt.tga new file mode 100644 index 000000000..67c05feae Binary files /dev/null and b/models/turrets/ewheel-base_shirt.tga differ diff --git a/models/turrets/mggun.tga b/models/turrets/mggun.tga index fb31d6735..be039a4ea 100644 Binary files a/models/turrets/mggun.tga and b/models/turrets/mggun.tga differ diff --git a/models/turrets/mggun_shirt.tga b/models/turrets/mggun_shirt.tga new file mode 100644 index 000000000..67102a2bc Binary files /dev/null and b/models/turrets/mggun_shirt.tga differ diff --git a/models/turrets/mlrs.tga b/models/turrets/mlrs.tga index ddddb07fc..c1da397fb 100644 Binary files a/models/turrets/mlrs.tga and b/models/turrets/mlrs.tga differ diff --git a/models/turrets/mlrs_glow.tga b/models/turrets/mlrs_glow.tga index c84fa1350..c29c16f9d 100644 Binary files a/models/turrets/mlrs_glow.tga and b/models/turrets/mlrs_glow.tga differ diff --git a/models/turrets/phaserbody.tga b/models/turrets/phaserbody.tga index f63f5e959..3cb227403 100644 Binary files a/models/turrets/phaserbody.tga and b/models/turrets/phaserbody.tga differ diff --git a/models/turrets/phaserbody_glow.tga b/models/turrets/phaserbody_glow.tga index d877e73a2..6f704f0a6 100644 Binary files a/models/turrets/phaserbody_glow.tga and b/models/turrets/phaserbody_glow.tga differ diff --git a/models/turrets/phasermag.tga b/models/turrets/phasermag.tga index 2d5b1f988..cb48d5eb7 100644 Binary files a/models/turrets/phasermag.tga and b/models/turrets/phasermag.tga differ diff --git a/models/turrets/phasermag_glow.tga b/models/turrets/phasermag_glow.tga index b30b540eb..fcf104fb7 100644 Binary files a/models/turrets/phasermag_glow.tga and b/models/turrets/phasermag_glow.tga differ diff --git a/models/turrets/plasmagun.tga b/models/turrets/plasmagun.tga index 31a4ab8b1..cb9726712 100644 Binary files a/models/turrets/plasmagun.tga and b/models/turrets/plasmagun.tga differ diff --git a/models/turrets/plasmagun_glow.tga b/models/turrets/plasmagun_glow.tga index 881b116d5..20e09fbfe 100644 Binary files a/models/turrets/plasmagun_glow.tga and b/models/turrets/plasmagun_glow.tga differ diff --git a/models/turrets/plasmagun_shirt.tga b/models/turrets/plasmagun_shirt.tga new file mode 100644 index 000000000..c56f8ebbe Binary files /dev/null and b/models/turrets/plasmagun_shirt.tga differ diff --git a/models/turrets/reactor.tga b/models/turrets/reactor.tga index c7df0397c..9d9569293 100644 Binary files a/models/turrets/reactor.tga and b/models/turrets/reactor.tga differ diff --git a/models/turrets/reactor_glow.tga b/models/turrets/reactor_glow.tga index 720fa2e57..573e0c03b 100644 Binary files a/models/turrets/reactor_glow.tga and b/models/turrets/reactor_glow.tga differ diff --git a/models/turrets/rocket.tga b/models/turrets/rocket.tga index e2217d181..cadfcba9c 100644 Binary files a/models/turrets/rocket.tga and b/models/turrets/rocket.tga differ diff --git a/models/turrets/rocket_glow.tga b/models/turrets/rocket_glow.tga index b1a84a4ed..33019c2c5 100644 Binary files a/models/turrets/rocket_glow.tga and b/models/turrets/rocket_glow.tga differ diff --git a/models/turrets/tesla.tga b/models/turrets/tesla.tga index cb952b0f1..b9a5e2ec9 100644 Binary files a/models/turrets/tesla.tga and b/models/turrets/tesla.tga differ diff --git a/models/turrets/tesla_glow.tga b/models/turrets/tesla_glow.tga index 82f4e9bfa..d33dec20c 100644 Binary files a/models/turrets/tesla_glow.tga and b/models/turrets/tesla_glow.tga differ diff --git a/models/turrets/walker_base.tga b/models/turrets/walker_base.tga index 238100311..41ce98375 100644 Binary files a/models/turrets/walker_base.tga and b/models/turrets/walker_base.tga differ diff --git a/models/turrets/walker_base_glow.tga b/models/turrets/walker_base_glow.tga index bfe8dfeb0..bc4ebd01e 100644 Binary files a/models/turrets/walker_base_glow.tga and b/models/turrets/walker_base_glow.tga differ diff --git a/qcsrc/client/tturrets.qc b/qcsrc/client/tturrets.qc index 1332d60ca..95efb4cc6 100644 --- a/qcsrc/client/tturrets.qc +++ b/qcsrc/client/tturrets.qc @@ -165,31 +165,36 @@ void turret_remove() remove(self.tur_head); self.tur_head = world; } - +.vector glowmod; void turret_changeteam() -{ - self.colormod = '0 0 0'; - - switch(self.team) +{ + switch(self.team - 1) { case COLOR_TEAM1: // Red - self.colormod = '2 0.5 0.5'; + self.glowmod = '2 0 0'; break; case COLOR_TEAM2: // Blue - self.colormod = '0.5 0.5 2'; + self.glowmod = '0 0 2'; break; case COLOR_TEAM3: // Yellow - self.colormod = '1.4 1.4 0.6'; + self.glowmod = '1 1 0'; break; case COLOR_TEAM4: // Pink - self.colormod = '1.4 0.6 1.4'; + self.glowmod = '1 0 1'; break; } - self.tur_head.colormod = self.colormod; + if(self.team) + self.colormap = 1024 + (self.team - 1) * 17; + else + self.colormap = 1024 + (1 + rint(random() * 3) - 1) * 17; + + self.tur_head.colormap = self.colormap; + self.tur_head.glowmod = self.glowmod; + } void turret_head_draw() @@ -218,7 +223,7 @@ void turret_draw() } if(self.health < 85) - if(dt < 0.1) + if(dt < 0.05) pointparticles(particleeffectnum("smoke_small"), (self.origin + (randomvec() * 80)), '0 0 0', 1); if(self.health < 32) @@ -247,7 +252,7 @@ void turret_walker_draw() self.angles_y = self.move_angles_y; if (self.health < 127) - if(random() < 0.25) + if(random() < 0.15) te_spark(self.origin + '0 0 40', randomvec() * 256 + '0 0 256', 16); } @@ -275,7 +280,7 @@ void turret_ewheel_draw() self.angles_y = self.move_angles_y; if (self.health < 127) - if(random() < 0.25) + if(random() < 0.05) te_spark(self.origin + '0 0 40', randomvec() * 256 + '0 0 256', 16); } @@ -448,6 +453,12 @@ void ent_turret() turret_precache(self.turret_type); turret_construct(); + self.colormap = 1024; // + (1 + rint(random() * 3) - 1) * 17; + self.glowmod = '0 1 1'; + self.tur_head.colormap = self.colormap; + self.tur_head.glowmod = self.glowmod; + + //turret_changeteam(); } if(sf & TNSF_ANG) @@ -491,12 +502,12 @@ void ent_turret() { float _team; _team = ReadByte(); - _team -= 1; // /&)=(%&#)&%)/#&)=½!!!½!!". thanks. + //_team -= 1; // /&)=(%&#)&%)/#&)=½!!!½!!". thanks. self.health = ReadByte(); if(_team != self.team) { self.team = _team; - turret_changeteam(); + turret_changeteam(); } if(self.health == 0) diff --git a/qcsrc/server/tturrets/system/system_main.qc b/qcsrc/server/tturrets/system/system_main.qc index ea0f6b226..b4ee78139 100644 --- a/qcsrc/server/tturrets/system/system_main.qc +++ b/qcsrc/server/tturrets/system/system_main.qc @@ -759,7 +759,7 @@ void turret_think() // ONS uses somewhat backwards linking. if (teamplay) { - if not (g_onslaught) + if (g_onslaught) if (self.target) { e = find(world, targetname,self.target);