From bffe8d11bd1dfec49280fb64a17f0ae529ac3f5d Mon Sep 17 00:00:00 2001 From: xolatile Date: Sun, 17 Aug 2025 18:28:28 +0200 Subject: Compiles, removed a lot of code, do not run it... --- src/fpsgame/weapon.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src/fpsgame/weapon.cpp') diff --git a/src/fpsgame/weapon.cpp b/src/fpsgame/weapon.cpp index 30d2da8..4c85a36 100644 --- a/src/fpsgame/weapon.cpp +++ b/src/fpsgame/weapon.cpp @@ -408,14 +408,13 @@ namespace game { else p.o = v; } } - extern int chainsawhudgun; VARP(muzzleflash, 0, 1, 1); VARP(muzzlelight, 0, 1, 1); void shoteffects(int gun, const vec &from, const vec &to, fpsent *d, bool local, int id, int prevaction) { // create visual effect from a shot { int sound = guns[gun].sound, pspeed = 25; switch(gun) { case GUN_FIST: - if(d->type==ENT_PLAYER && chainsawhudgun) sound = S_CHAINSAW_ATTACK; + if(d->type==ENT_PLAYER) sound = S_CHAINSAW_ATTACK; break; case GUN_SG: { if(!local) createrays(gun, from, to); @@ -613,7 +612,7 @@ namespace game { } pitch = -bnc.roll; if(bnc.bouncetype==BNC_GRENADE) - rendermodel(&bnc.light, "projectiles/grenade", ANIM_MAPMODEL|ANIM_LOOP, pos, yaw, pitch, MDL_CULL_VFC|MDL_CULL_OCCLUDED|MDL_LIGHT|MDL_LIGHT_FAST|MDL_DYNSHADOW); + rendermodel(&bnc.light, "projectiles/grenade", ANIM_MAPMODEL|ANIM_LOOP, pos, yaw, pitch, MDL_CULL_VFC|MDL_CULL_OCCLUDED|MDL_LIGHT|MDL_LIGHT_FAST); else { const char *mdl = NULL; int cull = MDL_CULL_VFC|MDL_CULL_DIST|MDL_CULL_OCCLUDED; @@ -643,7 +642,7 @@ namespace game { int gun = -1; switch(d->attacksound) { case S_CHAINSAW_ATTACK: - if(chainsawhudgun) gun = GUN_FIST; + gun = GUN_FIST; break; default: return; @@ -660,7 +659,7 @@ namespace game { int sound = -1, radius = 0; if(d->clientnum >= 0 && d->state == CS_ALIVE) switch(d->gunselect) { case GUN_FIST: - if(chainsawhudgun && d->attacksound < 0) { + if(d->attacksound < 0) { sound = S_CHAINSAW_IDLE; radius = 50; } @@ -711,9 +710,10 @@ namespace game { /// Rough accuracy code, client-side only. int pwshotsfired [NUMGUNS] = { 0 }; -int pwshotshit [NUMGUNS] = { 0 }; +int pwshotshit [NUMGUNS] = { 0 }; int pwdamagedealt [NUMGUNS] = { 0 }; -int pwaccuracy [NUMGUNS] = { 0 }; +int pwaccuracy [NUMGUNS] = { 0 }; + int pwavgaccuracy = 0; void pwshot(int gun) { -- cgit v1.2.3