X-Git-Url: http://de.git.xonotic.org/?p=xonotic%2Fxonotic-data.pk3dir.git;a=blobdiff_plain;f=qcsrc%2Fserver%2Fw_tuba.qc;h=6b3287b59ed1ee29b1e0ee8228e89e819f0b04b0;hp=9993dd4eeb4bc115318f3fcdaaaa8e0b776a5083;hb=d0db4b5db11800d291fbdba93a67e8487fa033e2;hpb=e1326a2cccc2d471cd11161ab7eda42dfe4d5d2f diff --git a/qcsrc/server/w_tuba.qc b/qcsrc/server/w_tuba.qc index 9993dd4ee..6b3287b59 100644 --- a/qcsrc/server/w_tuba.qc +++ b/qcsrc/server/w_tuba.qc @@ -148,6 +148,9 @@ float Tuba_GetNote(entity pl, float hittype) if(pl.movement_x > 0) movestate += 3; if(pl.movement_y < 0) movestate -= 1; if(pl.movement_y > 0) movestate += 1; +#ifdef GMQCC + note = 0; +#endif switch(movestate) { // layout: originally I wanted @@ -183,7 +186,7 @@ float Tuba_GetNote(entity pl, float hittype) // that way, holes in the range of notes are "plugged" if(teamplay) { - if(pl.team == FL_TEAM_2 || pl.team == FL_TEAM_4) + if(pl.team == NUM_TEAM_2 || pl.team == NUM_TEAM_4) note += 3; } else @@ -287,8 +290,6 @@ void W_Tuba_NoteOn(float hittype) hittype |= HITTYPE_SECONDARY; if(self.tuba_instrument & 2) hittype |= HITTYPE_BOUNCE; - if(self.tuba_instrument & 4) - hittype |= HITTYPE_HEADSHOT; if(self.tuba_note) { @@ -422,69 +423,33 @@ float w_tuba(float req) return TRUE; // TODO use fuel? else if (req == WR_CHECKAMMO2) return TRUE; // TODO use fuel? - return TRUE; -} -#endif -#ifdef CSQC -float w_tuba(float req) -{ - if(req == WR_IMPACTEFFECT) - { - // nothing to do here; particles of tuba are handled differently - } - else if(req == WR_PRECACHE) - { - // nothing to do - } else if (req == WR_SUICIDEMESSAGE) { - float instr; - instr = 0; - if(w_deathtype & HITTYPE_SECONDARY) - instr |= 1; if(w_deathtype & HITTYPE_BOUNCE) - instr |= 2; - if(w_deathtype & HITTYPE_HEADSHOT) - instr |= 4; - switch(instr) - { - default: - case 0: // Tuba - w_deathtypestring = _("%s hurt his own ears with the @!#%%'n Tuba"); - break; - case 1: // Accordeon - w_deathtypestring = _("%s hurt his own ears with the @!#%%'n Accordeon"); - break; - case 2: // Klein Bottle - w_deathtypestring = _("%s hurt his own ears with the @!#%%'n Klein Bottle"); - break; - } + return WEAPON_KLEINBOTTLE_SUICIDE; + else if(w_deathtype & HITTYPE_SECONDARY) + return WEAPON_ACCORDEON_SUICIDE; + else + return WEAPON_TUBA_SUICIDE; } else if (req == WR_KILLMESSAGE) { - float instr; - instr = 0; - if(w_deathtype & HITTYPE_SECONDARY) - instr |= 1; if(w_deathtype & HITTYPE_BOUNCE) - instr |= 2; - if(w_deathtype & HITTYPE_HEADSHOT) - instr |= 4; - switch(instr) - { - default: - case 0: // Tuba - w_deathtypestring = _("%s died of %s's great playing on the @!#%%'n Tuba"); - break; - case 1: // Accordeon - w_deathtypestring = _("%s died of %s's great playing on the @!#%%'n Accordeon"); - break; - case 2: // Klein Bottle - w_deathtypestring = _("%s died of %s's great playing on the @!#%%'n Klein Bottle"); - break; - } + return WEAPON_KLEINBOTTLE_MURDER; + else if(w_deathtype & HITTYPE_SECONDARY) + return WEAPON_ACCORDEON_MURDER; + else + return WEAPON_TUBA_MURDER; } return TRUE; } #endif +#ifdef CSQC +float w_tuba(float req) +{ + // nothing to do here; particles of tuba are handled differently + + return TRUE; +} +#endif #endif