X-Git-Url: https://de.git.xonotic.org/?p=xonotic%2Fxonotic-data.pk3dir.git;a=blobdiff_plain;f=qcsrc%2Fcommon%2Fturrets%2Funit%2Fplasma.qc;h=59c0f850a76f5663cc81de0ffa53416d8da0400f;hp=38a7eeacb6f85c001359247d49b2baffce28b095;hb=2cbe50a41fcd237cdc76136a22842c18e739cbcc;hpb=c6437cd43edc4489ad69746a30b5532f18c1af74 diff --git a/qcsrc/common/turrets/unit/plasma.qc b/qcsrc/common/turrets/unit/plasma.qc index 38a7eeacb..59c0f850a 100644 --- a/qcsrc/common/turrets/unit/plasma.qc +++ b/qcsrc/common/turrets/unit/plasma.qc @@ -1,4 +1,4 @@ -#ifdef REGISTER_TURRET +#ifndef IMPLEMENTATION REGISTER_TURRET( /* TUR_##id */ PLASMA, /* function */ t_plasma, @@ -11,7 +11,7 @@ REGISTER_TURRET( ); #else #ifdef SVQC -void spawnfunc_turret_plasma() { SELFPARAM(); if(!turret_initialize(TUR_PLASMA)) remove(self); } +spawnfunc(turret_plasma) { if(!turret_initialize(TUR_PLASMA.m_id)) remove(self); } float t_plasma(float req) {SELFPARAM(); @@ -30,13 +30,8 @@ float t_plasma(float req) Send_Effect(EFFECT_VORTEX_MUZZLEFLASH, self.tur_shotorg, self.tur_shotdir_updated * 1000, 1); // teamcolor / hit beam effect - vector v; - string s; - v = WarpZone_UnTransformOrigin(WarpZone_trace_transform, trace_endpos); - s = strcat("TE_TEI_G3", ((self.team) ? Static_Team_ColorName_Upper(self.team) : "")); - - WarpZone_TrailParticles(world, _particleeffectnum(s), self.tur_shotorg, v); - + vector v = WarpZone_UnTransformOrigin(WarpZone_trace_transform, trace_endpos); + WarpZone_TrailParticles(world, particleeffectnum(EFFECT_VAPORIZER(self.team)), self.tur_shotorg, v); if (self.tur_head.frame == 0) self.tur_head.frame = 1; }