From 4d2dc53972295118df491523e53732a019da17aa Mon Sep 17 00:00:00 2001 From: GenericHeroGuy Date: Mon, 19 May 2025 19:36:49 +0200 Subject: [PATCH] Fix warnings --- src/doomdef.h | 2 +- src/info.c | 4 ++-- src/info.h | 4 ++-- src/m_menu.c | 2 +- src/m_menu.h | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/doomdef.h b/src/doomdef.h index d4658569b..da551b5b2 100644 --- a/src/doomdef.h +++ b/src/doomdef.h @@ -211,7 +211,7 @@ extern char logfilename[1024]; #define COLORRAMPSIZE 16 #define MAXCOLORNAME 32 -#define NUMCOLORFREESLOTS UINT16_MAX +#define NUMCOLORFREESLOTS 32768 // surely nobody's gonna change the palette a second time :Clueless: #define FADECOLOR 0 // 120 diff --git a/src/info.c b/src/info.c index b1b532cb7..824253974 100644 --- a/src/info.c +++ b/src/info.c @@ -81,10 +81,10 @@ playersprite_t spr2defaults[NUMPLAYERSPRITES] = { // Doesn't work with g++, needs actionf_p1 (don't modify this comment) state_t states[NUMSTATES] = {0}; -size_t numstates; +UINT16 numstates; mobjinfo_t mobjinfo[NUMMOBJTYPES] = {0}; -size_t nummobjtypes; +UINT16 nummobjtypes; skincolor_t skincolors[MAXSKINCOLORS] = {0}; diff --git a/src/info.h b/src/info.h index a1740d7af..547fced8c 100644 --- a/src/info.h +++ b/src/info.h @@ -91,7 +91,7 @@ struct state_t }; extern state_t states[NUMSTATES]; -extern size_t numstates; +extern UINT16 numstates; extern char sprnames[NUMSPRITES + 1][5]; extern char spr2names[NUMPLAYERSPRITES][5]; extern playersprite_t spr2defaults[NUMPLAYERSPRITES]; @@ -138,7 +138,7 @@ struct mobjinfo_t }; extern mobjinfo_t mobjinfo[NUMMOBJTYPES]; -extern size_t nummobjtypes; +extern UINT16 nummobjtypes; typedef enum { diff --git a/src/m_menu.c b/src/m_menu.c index 8c7281e8a..3bfa6e73c 100644 --- a/src/m_menu.c +++ b/src/m_menu.c @@ -167,7 +167,7 @@ static UINT32 serverlistpage; INT16 startmap; // Mario, NiGHTS, or just a plain old normal game? menu_t menudefs[MAXMENUTYPES]; // array of all menudefs -size_t nummenutypes; +UINT16 nummenutypes; menutype_t menustack[NUMMENULEVELS]; // stack of active menus, [0] == current menu static menu_t *currentMenu; // current menudef static INT16 itemOn = 1; // menu item skull is on, Hack by Tails 09-18-2002 diff --git a/src/m_menu.h b/src/m_menu.h index c23ac4e0b..55b065258 100644 --- a/src/m_menu.h +++ b/src/m_menu.h @@ -258,7 +258,7 @@ struct menu_t }; extern menu_t menudefs[MAXMENUTYPES]; -extern size_t nummenutypes; +extern UINT16 nummenutypes; void M_EnterMenu(menutype_t menu, boolean callexit); void M_ExitMenu(void);