From 968708a6496e4bad9a5a20d15f209b9a26489fa8 Mon Sep 17 00:00:00 2001 From: Mitchell Richters Date: Wed, 4 Aug 2021 19:54:28 +1000 Subject: [PATCH] - Blood: Remove the extern for `weaponQAV[]` and move `kQAVEnd` enum into new enum from 9e84dd1ef6051f4e54d99dcfc6e3468560175e16 --- source/games/blood/src/misc.h | 2 -- source/games/blood/src/qav.h | 2 ++ source/games/blood/src/weapon.cpp | 4 +--- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/source/games/blood/src/misc.h b/source/games/blood/src/misc.h index fcd7b8da1..96914d50f 100644 --- a/source/games/blood/src/misc.h +++ b/source/games/blood/src/misc.h @@ -41,9 +41,7 @@ void DrawMirrors(int x, int y, int z, fixed_t a, fixed_t horiz, int smooth, int int qanimateoffs(int a1, int a2); void HookReplaceFunctions(); -struct QAV; struct PLAYER; -extern QAV* weaponQAV[]; void WeaponInit(void); void WeaponDraw(PLAYER *pPlayer, int a2, double a3, double a4, int a5); diff --git a/source/games/blood/src/qav.h b/source/games/blood/src/qav.h index d09f09c24..0cd90af1f 100644 --- a/source/games/blood/src/qav.h +++ b/source/games/blood/src/qav.h @@ -177,6 +177,8 @@ enum kQAV2NAPFIRE = 122, kQAV2NAPFIR2 = 123, kQAV2NAPDOWN = 124, + + kQAVEnd = 125, }; // by NoOne: add sound flags diff --git a/source/games/blood/src/weapon.cpp b/source/games/blood/src/weapon.cpp index 13f59e0de..225019f23 100644 --- a/source/games/blood/src/weapon.cpp +++ b/source/games/blood/src/weapon.cpp @@ -33,8 +33,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. BEGIN_BLD_NS -enum { kQAVEnd = 125 }; - void FirePitchfork(int, PLAYER *pPlayer); void FireSpray(int, PLAYER *pPlayer); void ThrowCan(int, PLAYER *pPlayer); @@ -142,7 +140,7 @@ enum nClientAltFireNapalm, }; -QAV *weaponQAV[kQAVEnd]; +static QAV *weaponQAV[kQAVEnd]; static bool sub_4B1A4(PLAYER *pPlayer) {