mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-25 11:10:47 +00:00
Miscellaneous NAM and WWII GI tweaks/fixes.
Remaining issues: - Inventory item gamefuncs still use their Duke 3D names. The buggy way custom gamefunc binds are saved and loaded needs to be addressed first. git-svn-id: https://svn.eduke32.com/eduke32@5452 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
4aae9378d0
commit
0fdeed231b
4 changed files with 46 additions and 26 deletions
|
@ -1213,7 +1213,8 @@ ACTOR_STATIC void G_MovePlayers(void)
|
|||
{
|
||||
s->extra = p->max_player_health;
|
||||
s->cstat = 257;
|
||||
p->inv_amount[GET_JETPACK] = 1599;
|
||||
if (!WW2GI)
|
||||
p->inv_amount[GET_JETPACK] = 1599;
|
||||
}
|
||||
|
||||
if (s->extra > 0)
|
||||
|
|
|
@ -2174,10 +2174,13 @@ static void G_DrawStatusBar(int32_t snum)
|
|||
|
||||
G_DrawInvNum(284-30-o, yofssh, 200-6, (uint8_t)i, 0, orient&~16);
|
||||
|
||||
if (j > 0)
|
||||
minitext(288-30-o, 180, "On", 0, orient);
|
||||
else if ((uint32_t)j != 0x80000000)
|
||||
minitext(284-30-o, 180, "Off", 2, orient);
|
||||
if (!WW2GI)
|
||||
{
|
||||
if (j > 0)
|
||||
minitext(288-30-o, 180, "On", 0, orient);
|
||||
else if ((uint32_t)j != 0x80000000)
|
||||
minitext(284-30-o, 180, "Off", 2, orient);
|
||||
}
|
||||
|
||||
if (p->inven_icon >= ICON_SCUBA)
|
||||
minitext(284-35-o, 180, "Auto", 2, orient);
|
||||
|
@ -2403,7 +2406,7 @@ static void G_DrawStatusBar(int32_t snum)
|
|||
if (p->inven_icon >= ICON_SCUBA) minitext(284-35-o,SBY+14,"Auto",2,10+16+permbit + ROTATESPRITE_MAX);
|
||||
}
|
||||
|
||||
if (u&(2048+4096))
|
||||
if (u&(2048+4096) && !WW2GI)
|
||||
{
|
||||
j = G_GetInvOn(p);
|
||||
|
||||
|
@ -11630,12 +11633,6 @@ int32_t app_main(int32_t argc, const char **argv)
|
|||
G_LoadGroups(!g_noAutoLoad && !ud.config.NoAutoLoad);
|
||||
// flushlogwindow = 1;
|
||||
|
||||
if (NAM_WW2GI)
|
||||
{
|
||||
Bstrcpy(GametypeNames[0],"GruntMatch (Spawn)");
|
||||
Bstrcpy(GametypeNames[2],"GruntMatch (No Spawn)");
|
||||
}
|
||||
|
||||
// KEEPINSYNC: NAM_WW2GI_CHEATS
|
||||
if (WW2GI)
|
||||
{
|
||||
|
@ -11664,6 +11661,9 @@ int32_t app_main(int32_t argc, const char **argv)
|
|||
Bstrcpy(CheatStrings[23], "<RESERVED>");
|
||||
Bstrcpy(CheatStrings[24], "2debug");
|
||||
Bstrcpy(CheatStrings[26], "2cgs");
|
||||
|
||||
Bstrcpy(GametypeNames[0],"GI Match (Spawn)");
|
||||
Bstrcpy(GametypeNames[2],"GI Match (No Spawn)");
|
||||
}
|
||||
else if (NAM)
|
||||
{
|
||||
|
@ -11693,6 +11693,9 @@ int32_t app_main(int32_t argc, const char **argv)
|
|||
Bstrcpy(CheatStrings[23], "<RESERVED>");
|
||||
Bstrcpy(CheatStrings[24], "adebug");
|
||||
Bstrcpy(CheatStrings[26], "acgs");
|
||||
|
||||
Bstrcpy(GametypeNames[0],"GruntMatch (Spawn)");
|
||||
Bstrcpy(GametypeNames[2],"GruntMatch (No Spawn)");
|
||||
}
|
||||
|
||||
if (!usecwd)
|
||||
|
@ -13018,6 +13021,7 @@ void G_BonusScreen(int32_t bonusonly)
|
|||
}
|
||||
if (!NAM_WW2GI && !DUKEBETA && MapInfo[G_LastMapInfoIndex()].designertime)
|
||||
{
|
||||
// EDuke 2.0 / NAM source suggests "Green Beret's Time:"
|
||||
gametext(10,yy+9,"3D Realms' Time:",0,2+8+16);
|
||||
yy+=10;
|
||||
}
|
||||
|
|
|
@ -73,8 +73,10 @@ FORCE_INLINE void WithSDL2_StopTextInput()
|
|||
#endif
|
||||
}
|
||||
|
||||
#define mgametext(x,y,t) G_ScreenText(STARTALPHANUM, x, y, 65536, 0, 0, t, 0, 0, 2|8|16|ROTATESPRITE_FULL16, 0, 5<<16, 8<<16, -1<<16, 0, 0, 0, 0, xdim-1, ydim-1)
|
||||
#define mgametextcenter(x,y,t) G_ScreenText(STARTALPHANUM, (MENU_MARGIN_CENTER<<16) + (x), y, 65536, 0, 0, t, 0, 0, 2|8|16|ROTATESPRITE_FULL16, 0, 5<<16, 8<<16, -1<<16, 1<<16, TEXT_XCENTER, 0, 0, xdim-1, ydim-1)
|
||||
static int32_t mgametext_xbetween = -(1<<16);
|
||||
|
||||
#define mgametext(x,y,t) G_ScreenText(STARTALPHANUM, x, y, 65536, 0, 0, t, 0, 0, 2|8|16|ROTATESPRITE_FULL16, 0, 5<<16, 8<<16, mgametext_xbetween, 0, 0, 0, 0, xdim-1, ydim-1)
|
||||
#define mgametextcenter(x,y,t) G_ScreenText(STARTALPHANUM, (MENU_MARGIN_CENTER<<16) + (x), y, 65536, 0, 0, t, 0, 0, 2|8|16|ROTATESPRITE_FULL16, 0, 5<<16, 8<<16, mgametext_xbetween, 1<<16, TEXT_XCENTER, 0, 0, xdim-1, ydim-1)
|
||||
#define mminitext(x,y,t,p) minitext_(x, y, t, 0, p, 2|8|16|ROTATESPRITE_FULL16)
|
||||
#define mmenutext(x,y,t) G_ScreenText(BIGALPHANUM, x, (y) - (12<<16), 65536L, 0, 0, (const char *)OSD_StripColors(menutextbuf,t), 0, 0, 2|8|16|ROTATESPRITE_FULL16, 0, 5<<16, 16<<16, 0, 0, TEXT_BIGALPHANUM|TEXT_UPPERCASE|TEXT_LITERALESCAPE, 0, 0, xdim-1, ydim-1)
|
||||
#define mmenutextcenter(x,y,t) G_ScreenText(BIGALPHANUM, (MENU_MARGIN_CENTER<<16) + (x), (y) - (12<<16), 65536L, 0, 0, (const char *)OSD_StripColors(menutextbuf,t), 0, 0, 2|8|16|ROTATESPRITE_FULL16, 0, 5<<16, 16<<16, 0, 0, TEXT_BIGALPHANUM|TEXT_UPPERCASE|TEXT_LITERALESCAPE|TEXT_XCENTER, 0, 0, xdim-1, ydim-1)
|
||||
|
@ -1382,6 +1384,8 @@ void M_Init(void)
|
|||
// prepare menu fonts
|
||||
MF_Redfont.tilenum = MF_RedfontBlue.tilenum = MF_RedfontGreen.tilenum = BIGALPHANUM;
|
||||
MF_Bluefont.tilenum = MF_BluefontRed.tilenum = STARTALPHANUM;
|
||||
if (NAM_WW2GI)
|
||||
mgametext_xbetween = MF_Bluefont.xbetween = MF_BluefontRed.xbetween = 0;
|
||||
MF_Minifont.tilenum = MF_MinifontRed.tilenum = MF_MinifontDarkGray.tilenum = MINIFONT;
|
||||
if (!minitext_lowercase)
|
||||
{
|
||||
|
@ -1479,6 +1483,8 @@ void M_Init(void)
|
|||
}
|
||||
++k;
|
||||
MEOS_NETOPTIONS_GAMETYPE.numOptions = k;
|
||||
if (NAM_WW2GI)
|
||||
ME_NETOPTIONS_MONSTERS.name = "Enemies";
|
||||
|
||||
// prepare savegames
|
||||
for (i = 0; i < MAXSAVEGAMES; ++i)
|
||||
|
@ -1584,6 +1590,12 @@ void M_Init(void)
|
|||
}
|
||||
}
|
||||
|
||||
// prepare sound setup
|
||||
if (WW2GI)
|
||||
ME_SOUND_DUKETALK.name = "GI talk:";
|
||||
else if (NAM)
|
||||
ME_SOUND_DUKETALK.name = "Grunt talk:";
|
||||
|
||||
// prepare shareware
|
||||
if (VOLUMEONE)
|
||||
{
|
||||
|
@ -1873,7 +1885,7 @@ static void M_PreMenuDraw(MenuID_t cm, MenuEntry_t *entry, const vec2_t origin)
|
|||
mminitext(origin.x + (90<<16), origin.y + (90<<16), "Game Type", 2);
|
||||
mminitext(origin.x + (90<<16), origin.y + ((90+8)<<16), "Episode", 2);
|
||||
mminitext(origin.x + (90<<16), origin.y + ((90+8+8)<<16), "Level", 2);
|
||||
mminitext(origin.x + (90<<16), origin.y + ((90+8+8+8)<<16), "Monsters", 2);
|
||||
mminitext(origin.x + (90<<16), origin.y + ((90+8+8+8)<<16), ME_NETOPTIONS_MONSTERS.name, 2);
|
||||
if (ud.m_coop == 0)
|
||||
mminitext(origin.x + (90<<16), origin.y + ((90+8+8+8+8)<<16), "Markers", 2);
|
||||
else if (ud.m_coop == 1)
|
||||
|
|
|
@ -1907,6 +1907,9 @@ static int32_t P_DisplayKnuckles(int32_t gs)
|
|||
static const int8_t knuckle_frames[] = {0,1,2,2,3,3,3,2,2,1,0};
|
||||
const DukePlayer_t *const ps = g_player[screenpeek].ps;
|
||||
|
||||
if (WW2GI)
|
||||
return 0;
|
||||
|
||||
if (ps->knuckle_incs == 0)
|
||||
return 0;
|
||||
|
||||
|
@ -3089,18 +3092,18 @@ static int32_t P_DoCounters(int32_t snum)
|
|||
{
|
||||
if (++p->knuckle_incs == 10)
|
||||
{
|
||||
if (totalclock > 1024)
|
||||
if (snum == screenpeek || GTFLAGS(GAMETYPE_COOPSOUND))
|
||||
{
|
||||
|
||||
if (rand()&1)
|
||||
A_PlaySound(DUKE_CRACK,p->i);
|
||||
else A_PlaySound(DUKE_CRACK2,p->i);
|
||||
|
||||
}
|
||||
|
||||
A_PlaySound(DUKE_CRACK_FIRST,p->i);
|
||||
if (!WW2GI)
|
||||
{
|
||||
if (totalclock > 1024)
|
||||
if (snum == screenpeek || GTFLAGS(GAMETYPE_COOPSOUND))
|
||||
{
|
||||
if (rand()&1)
|
||||
A_PlaySound(DUKE_CRACK,p->i);
|
||||
else A_PlaySound(DUKE_CRACK2,p->i);
|
||||
}
|
||||
|
||||
A_PlaySound(DUKE_CRACK_FIRST,p->i);
|
||||
}
|
||||
}
|
||||
else if (p->knuckle_incs == 22 || TEST_SYNC_KEY(g_player[snum].sync->bits, SK_FIRE))
|
||||
p->knuckle_incs=0;
|
||||
|
|
Loading…
Reference in a new issue