Comment out cases of "comparison is always true"

This commit is contained in:
NepDisk 2026-03-27 23:54:58 -04:00
parent 3014d6b46b
commit 31d8e671cb
5 changed files with 8 additions and 11 deletions

View file

@ -3636,7 +3636,6 @@ static void Command_Map_f(void)
size_t option_gametype;
size_t option_encore;
size_t option_skill;
const char *gametypename;
boolean newresetplayers;
boolean newforcespecialstage;
@ -3650,8 +3649,6 @@ static void Command_Map_f(void)
INT32 newgametype = gametype;
boolean newencoremode = (cv_kartencore.value == 1);
INT32 d;
if (client && !IsPlayerAdmin(consoleplayer))
{
CONS_Printf(M_GetText("Only the server or a remote admin can use this.\n"));

View file

@ -827,7 +827,7 @@ const char *replaysuffixes[] = {
[REPLAY_GUEST] = "guest",
};
char *G_GetRecordReplay(const char *folder, UINT16 mapnum, UINT16 skinnum, recordreplay_e which)
char *G_GetRecordReplay(const char *folder, mapnum_t mapnum, UINT16 skinnum, recordreplay_e which)
{
const char *map = G_BuildMapName(mapnum), *suf = replaysuffixes[which];
if (which != REPLAY_GUEST)
@ -836,7 +836,7 @@ char *G_GetRecordReplay(const char *folder, UINT16 mapnum, UINT16 skinnum, recor
return strdup(va("%s"PATHSEP"%s-%s.lmp", folder, map, suf));
}
boolean G_CheckRecordReplay(const char *folder, UINT16 mapnum, UINT16 skinnum, recordreplay_e which)
boolean G_CheckRecordReplay(const char *folder, mapnum_t mapnum, UINT16 skinnum, recordreplay_e which)
{
const char *map = G_BuildMapName(mapnum), *suf = replaysuffixes[which];
if (which != REPLAY_GUEST)
@ -4783,7 +4783,7 @@ void G_AddMapToBuffer(mapnum_t map)
mapnum_t bufx;
mapnum_t refreshnum = (TOLMaps(gametype))-3;
if (refreshnum < 0)
//if (refreshnum < 0)
refreshnum = 3;
if (nummapheaders != randmaps.lastnummapheaders)
@ -4994,7 +4994,7 @@ void G_GPCupIntoRoundQueue(cupheader_t *cup, UINT8 setgametype, boolean setencor
void G_GetNextMap(void)
{
boolean spec = G_IsSpecialStage(prevmap+1);
//boolean spec = G_IsSpecialStage(prevmap+1);
INT32 i;
boolean setalready = false;

View file

@ -1401,7 +1401,7 @@ static int libd_getMapMinimap(lua_State *L)
else
mapnum = G_MapNumber(luaL_checkstring(L, 1));
if (mapnum >= 0 && mapnum < nummapheaders && mapheaderinfo[mapnum])
if (/*mapnum >= 0 && */mapnum < nummapheaders && mapheaderinfo[mapnum])
patch = mapheaderinfo[mapnum]->minimapPic;
if (!patch)
patch = missingpat;

View file

@ -522,7 +522,7 @@ emblem_t *M_GetLevelEmblems(mapnum_t mapnum)
static mapnum_t map = NEXTMAP_INVALID;
static INT32 i = -1;
if (mapnum >= 0)
//if (mapnum >= 0)
{
map = mapnum;
i = numemblems;

View file

@ -642,7 +642,7 @@ fixed_t M_GetMapThumbnail(mapnum_t mapnum, patch_t **out)
patch_t *patch = NULL;
if (mapnum == NEXTMAP_INVALID)
patch = randomlvl;
else if (mapnum >= 0 && mapnum < nummapheaders && mapheaderinfo[mapnum])
else if (/*mapnum >= 0 &&*/ mapnum < nummapheaders && mapheaderinfo[mapnum])
patch = mapheaderinfo[mapnum]->thumbnailPic;
if (!patch)
@ -3055,7 +3055,7 @@ static boolean M_LevelAvailableOnPlatter(mapnum_t mapnum)
static boolean M_CanShowLevelOnPlatter(mapnum_t mapnum)
{
// Does the map exist?
if (mapnum < 0 || mapnum >= nummapheaders || !mapheaderinfo[mapnum])
if (/*mapnum < 0 || */mapnum >= nummapheaders || !mapheaderinfo[mapnum])
return false;
// Does the map have a name?