Merge branch 'blentran-update' into udmf-full

This commit is contained in:
MascaraSnake 2022-01-04 19:36:20 +01:00
commit ca1d844278
9 changed files with 59 additions and 52 deletions

View file

@ -5151,6 +5151,7 @@ struct int_const_s const INT_CONST[] = {
{"PAL_MIXUP",PAL_MIXUP},
{"PAL_RECYCLE",PAL_RECYCLE},
{"PAL_NUKE",PAL_NUKE},
{"PAL_INVERT",PAL_INVERT},
// for P_DamageMobj
//// Damage types
{"DMG_WATER",DMG_WATER},

View file

@ -3300,7 +3300,7 @@ boolean G_EnoughPlayersFinished(void)
for (i = 0; i < MAXPLAYERS; i++)
{
if (!playeringame[i] || players[i].spectator || players[i].bot == BOT_2PAI || players[i].bot == BOT_2PHUMAN)
if (!playeringame[i] || players[i].spectator || players[i].bot)
continue;
if (players[i].quittime > 30 * TICRATE)
continue;

View file

@ -2476,7 +2476,7 @@ static void HU_Draw32TeamTabRankings(playersort_t *tab, INT32 whiteplayer)
if (!players[tab[i].num].quittime || (leveltime / (TICRATE/2) & 1))
V_DrawString(x + 10, y,
((tab[i].num == whiteplayer) ? V_YELLOWMAP : 0)
| (greycheck ? 0 : V_TRANSLUCENT)
| (greycheck ? V_TRANSLUCENT : 0)
| V_ALLOWLOWERCASE, name);
if (gametyperules & GTR_TEAMFLAGS)
@ -2737,12 +2737,12 @@ void HU_DrawDualTabRankings(INT32 x, INT32 y, playersort_t *tab, INT32 scoreline
if (circuitmap)
{
if (players[tab[i].num].exiting)
V_DrawRightAlignedThinString(x+146, y, 0, va("%i:%02i.%02i", G_TicsToMinutes(players[tab[i].num].realtime,true), G_TicsToSeconds(players[tab[i].num].realtime), G_TicsToCentiseconds(players[tab[i].num].realtime)));
V_DrawRightAlignedThinString(x+100, y, 0, va("%i:%02i.%02i", G_TicsToMinutes(players[tab[i].num].realtime,true), G_TicsToSeconds(players[tab[i].num].realtime), G_TicsToCentiseconds(players[tab[i].num].realtime)));
else
V_DrawRightAlignedThinString(x+146, y, (greycheck ? V_TRANSLUCENT : 0), va("%u", tab[i].count));
V_DrawRightAlignedThinString(x+100, y, (greycheck ? V_TRANSLUCENT : 0), va("%u", tab[i].count));
}
else
V_DrawRightAlignedThinString(x+146, y, (greycheck ? V_TRANSLUCENT : 0), va("%i:%02i.%02i", G_TicsToMinutes(tab[i].count,true), G_TicsToSeconds(tab[i].count), G_TicsToCentiseconds(tab[i].count)));
V_DrawRightAlignedThinString(x+100, y, (greycheck ? V_TRANSLUCENT : 0), va("%i:%02i.%02i", G_TicsToMinutes(tab[i].count,true), G_TicsToSeconds(tab[i].count), G_TicsToCentiseconds(tab[i].count)));
}
else
V_DrawRightAlignedThinString(x+100, y, (greycheck ? V_TRANSLUCENT : 0), va("%u", tab[i].count));
@ -2790,7 +2790,7 @@ static void HU_Draw32TabRankings(INT32 x, INT32 y, playersort_t *tab, INT32 scor
if (!players[tab[i].num].quittime || (leveltime / (TICRATE/2) & 1))
V_DrawString(x + 10, y,
((tab[i].num == whiteplayer) ? V_YELLOWMAP : 0)
| (greycheck ? 0 : V_TRANSLUCENT)
| (greycheck ? V_TRANSLUCENT : 0)
| V_ALLOWLOWERCASE, name);
if (G_GametypeUsesLives()) //show lives
@ -2850,13 +2850,13 @@ static void HU_Draw32TabRankings(INT32 x, INT32 y, playersort_t *tab, INT32 scor
if (players[tab[i].num].exiting)
V_DrawRightAlignedThinString(x+128, y, 0, va("%i:%02i.%02i", G_TicsToMinutes(players[tab[i].num].realtime,true), G_TicsToSeconds(players[tab[i].num].realtime), G_TicsToCentiseconds(players[tab[i].num].realtime)));
else
V_DrawRightAlignedThinString(x+128, y, (greycheck ? 0 : V_TRANSLUCENT), va("%u", tab[i].count));
V_DrawRightAlignedThinString(x+128, y, (greycheck ? V_TRANSLUCENT : 0), va("%u", tab[i].count));
}
else
V_DrawRightAlignedThinString(x+128, y, (greycheck ? 0 : V_TRANSLUCENT), va("%i:%02i.%02i", G_TicsToMinutes(tab[i].count,true), G_TicsToSeconds(tab[i].count), G_TicsToCentiseconds(tab[i].count)));
V_DrawRightAlignedThinString(x+128, y, (greycheck ? V_TRANSLUCENT : 0), va("%i:%02i.%02i", G_TicsToMinutes(tab[i].count,true), G_TicsToSeconds(tab[i].count), G_TicsToCentiseconds(tab[i].count)));
}
else
V_DrawRightAlignedThinString(x+128, y, (greycheck ? 0 : V_TRANSLUCENT), va("%u", tab[i].count));
V_DrawRightAlignedThinString(x+128, y, (greycheck ? V_TRANSLUCENT : 0), va("%u", tab[i].count));
y += 9;
if (i == 16)
@ -3095,7 +3095,7 @@ static void HU_DrawRankings(void)
HU_DrawTeamTabRankings(tab, whiteplayer);
else if (scorelines <= 9 && !cv_compactscoreboard.value)
HU_DrawTabRankings(40, 32, tab, scorelines, whiteplayer);
else if (scorelines <= 20 && !cv_compactscoreboard.value)
else if (scorelines <= 18 && !cv_compactscoreboard.value)
HU_DrawDualTabRankings(32, 32, tab, scorelines, whiteplayer);
else
HU_Draw32TabRankings(14, 28, tab, scorelines, whiteplayer);

View file

@ -11588,9 +11588,7 @@ static void M_ServerOptions(INT32 choice)
OP_ServerOptionsMenu[ 2].status = IT_STRING | IT_CVAR;
OP_ServerOptionsMenu[ 3].status = IT_STRING | IT_CVAR;
OP_ServerOptionsMenu[ 4].status = IT_STRING | IT_CVAR;
OP_ServerOptionsMenu[36].status = (netgame
? IT_GRAYEDOUT
: (IT_STRING | IT_CVAR | IT_CV_STRING));
OP_ServerOptionsMenu[36].status = IT_STRING | IT_CVAR | IT_CV_STRING;
OP_ServerOptionsMenu[37].status = IT_STRING | IT_CVAR;
OP_ServerOptionsMenu[38].status = IT_STRING | IT_CVAR;
}

View file

@ -348,6 +348,7 @@ void P_FlashPal(player_t *pl, UINT16 type, UINT16 duration);
#define PAL_MIXUP 2
#define PAL_RECYCLE 3
#define PAL_NUKE 4
#define PAL_INVERT 5
//
// P_ENEMY

View file

@ -2522,7 +2522,7 @@ boolean P_ZMovement(mobj_t *mo)
{
P_KillMobj(mo, NULL, NULL, 0);
}
return false;
return !P_MobjWasRemoved(mo); // allows explosion states to run
}
else
{

View file

@ -3183,48 +3183,55 @@ static void P_AddBinaryMapTags(void)
{
size_t i;
for (i = 0; i < numlines; i++)
{
// 96: Apply Tag to Tagged Sectors
for (i = 0; i < numlines; i++) {
// 97: Apply Tag to Front Sector
// 98: Apply Tag to Back Sector
// 99: Apply Tag to Front and Back Sectors
if (lines[i].special == 96) {
size_t j;
mtag_t tag = Tag_FGet(&lines[i].frontsector->tags);
mtag_t target_tag = Tag_FGet(&lines[i].tags);
mtag_t offset_tags[4];
memset(offset_tags, 0, sizeof(mtag_t)*4);
if (lines[i].flags & ML_EFFECT6) {
offset_tags[0] = (INT32)sides[lines[i].sidenum[0]].textureoffset / FRACUNIT;
offset_tags[1] = (INT32)sides[lines[i].sidenum[0]].rowoffset / FRACUNIT;
}
if (lines[i].flags & ML_TFERLINE) {
offset_tags[2] = (INT32)sides[lines[i].sidenum[1]].textureoffset / FRACUNIT;
offset_tags[3] = (INT32)sides[lines[i].sidenum[1]].rowoffset / FRACUNIT;
}
if (lines[i].special == 97 || lines[i].special == 99)
P_AddBinaryMapTagsFromLine(lines[i].frontsector, &lines[i]);
if (lines[i].special == 98 || lines[i].special == 99)
P_AddBinaryMapTagsFromLine(lines[i].backsector, &lines[i]);
}
for (j = 0; j < numsectors; j++) {
boolean matches_target_tag = target_tag && Tag_Find(&sectors[j].tags, target_tag);
size_t k; for (k = 0; k < 4; k++) {
if (lines[i].flags & ML_EFFECT5) {
if (matches_target_tag || (offset_tags[k] && Tag_Find(&sectors[j].tags, offset_tags[k]))) {
Tag_Add(&sectors[j].tags, tag);
break;
}
} else if (matches_target_tag) {
if (k == 0)
Tag_Add(&sectors[j].tags, tag);
if (offset_tags[k])
Tag_Add(&sectors[j].tags, offset_tags[k]);
// Run this loop after the 97-99 loop to ensure that 96 can search through all of the
// 97-99-applied tags.
for (i = 0; i < numlines; i++) {
size_t j;
mtag_t tag, target_tag;
mtag_t offset_tags[4];
// 96: Apply Tag to Tagged Sectors
if (lines[i].special != 96)
continue;
tag = Tag_FGet(&lines[i].frontsector->tags);
target_tag = Tag_FGet(&lines[i].tags);
memset(offset_tags, 0, sizeof(mtag_t)*4);
if (lines[i].flags & ML_EFFECT6) {
offset_tags[0] = (INT32)sides[lines[i].sidenum[0]].textureoffset / FRACUNIT;
offset_tags[1] = (INT32)sides[lines[i].sidenum[0]].rowoffset / FRACUNIT;
}
if (lines[i].flags & ML_TFERLINE) {
offset_tags[2] = (INT32)sides[lines[i].sidenum[1]].textureoffset / FRACUNIT;
offset_tags[3] = (INT32)sides[lines[i].sidenum[1]].rowoffset / FRACUNIT;
}
for (j = 0; j < numsectors; j++) {
boolean matches_target_tag = target_tag && Tag_Find(&sectors[j].tags, target_tag);
size_t k;
for (k = 0; k < 4; k++) {
if (lines[i].flags & ML_EFFECT5) {
if (matches_target_tag || (offset_tags[k] && Tag_Find(&sectors[j].tags, offset_tags[k]))) {
Tag_Add(&sectors[j].tags, tag);
break;
}
} else if (matches_target_tag) {
if (k == 0)
Tag_Add(&sectors[j].tags, tag);
if (offset_tags[k])
Tag_Add(&sectors[j].tags, offset_tags[k]);
}
}
} else {
if (lines[i].special == 97 || lines[i].special == 99)
P_AddBinaryMapTagsFromLine(lines[i].frontsector, &lines[i]);
if (lines[i].special == 98 || lines[i].special == 99)
P_AddBinaryMapTagsFromLine(lines[i].backsector, &lines[i]);
}
}

View file

@ -11488,7 +11488,7 @@ void P_PlayerThink(player_t *player)
for (i = 0; i < MAXPLAYERS; i++)
{
if (!playeringame[i] || players[i].spectator || players[i].bot == BOT_2PAI || players[i].bot == BOT_2PHUMAN)
if (!playeringame[i] || players[i].spectator || players[i].bot)
continue;
if (players[i].lives <= 0)
continue;
@ -11520,7 +11520,7 @@ void P_PlayerThink(player_t *player)
for (i = 0; i < MAXPLAYERS; i++)
{
if (!playeringame[i] || players[i].spectator || players[i].bot == BOT_2PAI || players[i].bot == BOT_2PHUMAN)
if (!playeringame[i] || players[i].spectator || players[i].bot)
continue;
if (players[i].quittime > 30 * TICRATE)
continue;

View file

@ -2291,7 +2291,7 @@ static void ST_drawTextHUD(void)
for (i = 0; i < MAXPLAYERS; i++)
{
if (!playeringame[i] || players[i].spectator)
if (!playeringame[i] || players[i].spectator || players[i].bot)
continue;
if (players[i].lives <= 0)
continue;