- more menus implemented

This commit is contained in:
Christoph Oelckers 2019-12-04 01:38:51 +01:00
parent 6a6d6e3694
commit 7d1eb74b5e
16 changed files with 331 additions and 782 deletions

View file

@ -258,8 +258,11 @@ CVARD(Bool, hud_position, false, CVAR_ARCHIVE, "aligns the status bar to the bot
CVARD(Bool, hud_bgstretch, false, CVAR_ARCHIVE|CVAR_FRONTEND_DUKELIKE, "enable/disable background image stretching in wide resolutions") CVARD(Bool, hud_bgstretch, false, CVAR_ARCHIVE|CVAR_FRONTEND_DUKELIKE, "enable/disable background image stretching in wide resolutions")
CVARD(Int, hud_messagetime, 120, CVAR_ARCHIVE|CVAR_FRONTEND_DUKELIKE, "length of time to display multiplayer chat messages") CVARD(Int, hud_messagetime, 120, CVAR_ARCHIVE|CVAR_FRONTEND_DUKELIKE, "length of time to display multiplayer chat messages")
// Should be available to all games - the message handling should also be consolidated into a game independent feature. // Should be available to all games - the message handling should also be consolidated into a game independent feature.
/*CUSTOM_*/CVARD(Bool, hud_messages, true, CVAR_ARCHIVE, "enable/disable showing messages") CUSTOM_CVARD(Int, hud_messages, 1, CVAR_ARCHIVE, "enable/disable showing messages")
CVAR(Bool, hud_messagenative, true, CVAR_ARCHIVE) {
if (self < 0 || self > 2) self = 1;
}
CCMD (togglemessages) CCMD (togglemessages)
{ {
@ -530,6 +533,16 @@ CUSTOM_CVARD(Float, vid_brightness, 0.f, CVAR_ARCHIVE | CVAR_GLOBALCONFIG, "adju
// todo: tell the system to update // todo: tell the system to update
} }
CUSTOM_CVARD(Float, vid_saturation, 0.f, CVAR_ARCHIVE | CVAR_GLOBALCONFIG, "adjusts saturation component of gamma ramp")
{
if (self < -3) self = -3;
else if (self > 3) self = 3;
// todo: tell the system to update
}
CVAR(Int, gl_satformula, 1, CVAR_ARCHIVE|CVAR_GLOBALCONFIG);
CCMD (bumpgamma) CCMD (bumpgamma)
{ {
// [RH] Gamma correction tables are now generated on the fly for *any* gamma level // [RH] Gamma correction tables are now generated on the fly for *any* gamma level
@ -555,32 +568,44 @@ CUSTOM_CVAR(String, rtsname, "", CVAR_ARCHIVE | CVAR_USERINFO)
CVAR(String, usermapfolder, "", CVAR_ARCHIVE); CVAR(String, usermapfolder, "", CVAR_ARCHIVE);
CUSTOM_CVAR(Int, playercolor, 0, CVAR_ARCHIVE|CVAR_USERINFO)
{
if (self < 0 || self > 10) self = 0;
else ;// gi->UpdatePlayerColor(); // this part is game specific
}
CUSTOM_CVAR(Int, playerteam, 0, CVAR_USERINFO) // this one is transient and won't be saved.
{
if (self < 0 || self > 3) self = 0;
else ;// gi->UpdatePlayerTeam(); // this part is game specific
}
// Will only become useful if the obituary system gets overhauled.
CUSTOM_CVAR(Int, playergender, 0, CVAR_USERINFO|CVAR_ARCHIVE)
{
if (self < 0 || self > 3) self = 0;
}
// Internal settings for demo recording and the multiplayer menu. These won't get saved and only are CVARs so that the menu code can use them. // Internal settings for demo recording and the multiplayer menu. These won't get saved and only are CVARs so that the menu code can use them.
CVAR(Bool, m_recstat, false, CVAR_NOSET) CVAR(Bool, m_recstat, false, CVAR_NOSET)
CVAR(Int, m_coop, 0, CVAR_NOSET) CVAR(Int, m_coop, 0, CVAR_NOSET)
CVAR(Int, m_ffire, 1, CVAR_NOSET) CVAR(Int, m_ffire, 1, CVAR_NOSET)
CVAR(Int, m_monsters, 1, CVAR_NOSET)
CVAR(Int, m_marker, 1, CVAR_NOSET) CVAR(Int, m_marker, 1, CVAR_NOSET)
CVAR(Int, m_level_number, 0, CVAR_NOSET) CVAR(Int, m_level_number, 0, CVAR_NOSET)
CVAR(Int, m_episode_number, 0, CVAR_NOSET)
CVAR(Int, m_noexits, 0, CVAR_NOSET) CVAR(Int, m_noexits, 0, CVAR_NOSET)
CVAR(Int, playercolor, 0, CVAR_NOSET) CVAR(String, m_server, "localhost", CVAR_NOSET)
CVAR(Int, playerteam, 0, CVAR_NOSET) CVAR(String, m_netport, "19014", CVAR_NOSET)
#if 0 #if 0
// These have to wait until the HUD code is cleaned up (no idea which may survive and which won't.)
/* /*
// Currently unavailable due to dependency on an obsolete OpenGL feature // Currently unavailable due to dependency on an obsolete OpenGL feature
{ "deliriumblur", "enable/disable delirium blur effect(polymost)", (void *)&gDeliriumBlur, CVAR_BOOL, 0, 1 }, { "deliriumblur", "enable/disable delirium blur effect(polymost)", (void *)&gDeliriumBlur, CVAR_BOOL, 0, 1 },
if (!Bstrcasecmp(parm->name, "color"))
{
playercolor = G_CheckPlayerColor(playercolor);
g_player[0].ps->palookup = g_player[0].pcolor = playercolor;
}
// This one gets changed at run time by the game code, so making it persistent does not work // This one gets changed at run time by the game code, so making it persistent does not work
// This option is not really useful anymore // This option is not really useful anymore
@ -589,9 +614,6 @@ CVAR(Int, playerteam, 0, CVAR_NOSET)
// This requires a different approach, because it got used like a CCMD, not a CVAR. // This requires a different approach, because it got used like a CCMD, not a CVAR.
{ "skill","changes the game skill setting", (void *)&ud.m_player_skill, CVAR_INT|CVAR_FUNCPTR|CVAR_NOSAVE/*|CVAR_NOMULTI*/, 0, 5 }, { "skill","changes the game skill setting", (void *)&ud.m_player_skill, CVAR_INT|CVAR_FUNCPTR|CVAR_NOSAVE/*|CVAR_NOMULTI*/, 0, 5 },
// requires cleanup first
//{ "team","change team in multiplayer", (void *)&playerteam, CVAR_INT|CVAR_MULTI, 0, 3 },
// just as a reminder: // just as a reminder:
/* /*
else if (!Bstrcasecmp(parm->name, "vid_gamma")) else if (!Bstrcasecmp(parm->name, "vid_gamma"))

View file

@ -63,7 +63,7 @@ EXTERN_CVAR(Int, hud_messagetime)
EXTERN_CVAR(Bool, hud_glowingquotes) EXTERN_CVAR(Bool, hud_glowingquotes)
EXTERN_CVAR(Int, hud_textscale) EXTERN_CVAR(Int, hud_textscale)
EXTERN_CVAR(Int, hud_weaponscale) EXTERN_CVAR(Int, hud_weaponscale)
EXTERN_CVAR(Bool, hud_messages) EXTERN_CVAR(Int, hud_messages)
EXTERN_CVAR(Int, althud_numbertile) EXTERN_CVAR(Int, althud_numbertile)
EXTERN_CVAR(Int, althud_numberpal) EXTERN_CVAR(Int, althud_numberpal)

View file

@ -187,9 +187,6 @@ void G_SetupCheats(void)
Bstrcpy(CheatStrings[23], "<RESERVED>"); Bstrcpy(CheatStrings[23], "<RESERVED>");
Bstrcpy(CheatStrings[24], "2debug"); Bstrcpy(CheatStrings[24], "2debug");
Bstrcpy(CheatStrings[26], "2cgs"); Bstrcpy(CheatStrings[26], "2cgs");
Bstrcpy(g_gametypeNames[0], "GI Match (Spawn)");
Bstrcpy(g_gametypeNames[2], "GI Match (No Spawn)");
} }
else if (NAM) else if (NAM)
{ {
@ -219,9 +216,6 @@ void G_SetupCheats(void)
Bstrcpy(CheatStrings[23], "<RESERVED>"); Bstrcpy(CheatStrings[23], "<RESERVED>");
Bstrcpy(CheatStrings[24], "adebug"); Bstrcpy(CheatStrings[24], "adebug");
Bstrcpy(CheatStrings[26], "acgs"); Bstrcpy(CheatStrings[26], "acgs");
Bstrcpy(g_gametypeNames[0], "GruntMatch (Spawn)");
Bstrcpy(g_gametypeNames[2], "GruntMatch (No Spawn)");
} }
} }
#endif #endif

View file

@ -757,6 +757,12 @@ void GameInterface::DrawCenteredTextScreen(const DVector2 &origin, const char *t
mgametextcenter(int(origin.X * 65536), int((origin.Y + position) * 65536), text); mgametextcenter(int(origin.X * 65536), int((origin.Y + position) * 65536), text);
} }
#if 0
void GameInterface::DrawPlayerSprite(int x, int y)
{
rotatesprite_fs(origin.x + (260<<16), origin.y + ((24+(tilesiz[APLAYER].y>>1))<<16), 49152L,0,1441-((((4-((int32_t) totalclock>>4)))&3)*5),0,entry == &ME_PLAYER_TEAM ? G_GetTeamPalette(playerteam) : playercolor,10);
}
#endif
END_DUKE_NS END_DUKE_NS

View file

@ -5744,7 +5744,7 @@ void G_UpdatePlayerFromMenu(void)
/*int32_t j = p.team;*/ /*int32_t j = p.team;*/
P_SetupMiscInputSettings(); P_SetupMiscInputSettings();
p.palookup = g_player[myconnectindex].pcolor = playercolor; p.palookup = g_player[myconnectindex].pcolor = G_CheckPlayerColor(playercolor);
g_player[myconnectindex].pteam = playerteam; g_player[myconnectindex].pteam = playerteam;
@ -6150,7 +6150,7 @@ MAIN_LOOP_RESTART:
myplayer.palookup = g_player[myconnectindex].pcolor = G_GetTeamPalette(g_player[myconnectindex].pteam); myplayer.palookup = g_player[myconnectindex].pcolor = G_GetTeamPalette(g_player[myconnectindex].pteam);
else else
{ {
if (playercolor) myplayer.palookup = g_player[myconnectindex].pcolor = playercolor; if (playercolor) myplayer.palookup = g_player[myconnectindex].pcolor = G_CheckPlayerColor(playercolor);
else myplayer.palookup = g_player[myconnectindex].pcolor; else myplayer.palookup = g_player[myconnectindex].pcolor;
} }

View file

@ -1646,7 +1646,7 @@ void __fastcall VM_SetUserdef(int const labelNum, int const lParm2, int32_t cons
case USERDEFS_MOUSEAIMING: in_aimmode.SetGenericRepDefault(iSet, CVAR_Int); break; case USERDEFS_MOUSEAIMING: in_aimmode.SetGenericRepDefault(iSet, CVAR_Int); break;
case USERDEFS_WEAPONSWITCH: cl_weaponswitch.SetGenericRepDefault(iSet, CVAR_Int); break; case USERDEFS_WEAPONSWITCH: cl_weaponswitch.SetGenericRepDefault(iSet, CVAR_Int); break;
case USERDEFS_DEMOCAMS: cl_democams = iSet; break; case USERDEFS_DEMOCAMS: cl_democams = iSet; break;
case USERDEFS_COLOR: playercolor = iSet; break; case USERDEFS_COLOR: /*playercolor.SetGenericRepDefault(iSet, CVAR_Int);*/ break; // the value range here does not match, so better leave the CVar alone.
case USERDEFS_MSGDISPTIME: hud_messagetime.SetGenericRepDefault(iSet, CVAR_Int); break; case USERDEFS_MSGDISPTIME: hud_messagetime.SetGenericRepDefault(iSet, CVAR_Int); break;
case USERDEFS_STATUSBARMODE: ud.statusbarmode = iSet; break; case USERDEFS_STATUSBARMODE: ud.statusbarmode = iSet; break;
case USERDEFS_M_NOEXITS: m_noexits = iSet; break; case USERDEFS_M_NOEXITS: m_noexits = iSet; break;
@ -1654,7 +1654,7 @@ void __fastcall VM_SetUserdef(int const labelNum, int const lParm2, int32_t cons
case USERDEFS_AUTOVOTE: cl_autovote.SetGenericRepDefault(iSet, CVAR_Int); break; case USERDEFS_AUTOVOTE: cl_autovote.SetGenericRepDefault(iSet, CVAR_Int); break;
case USERDEFS_AUTOMSG: cl_automsg.SetGenericRepDefault(iSet, CVAR_Int); break; case USERDEFS_AUTOMSG: cl_automsg.SetGenericRepDefault(iSet, CVAR_Int); break;
case USERDEFS_IDPLAYERS: cl_idplayers.SetGenericRepDefault(iSet, CVAR_Int); break; case USERDEFS_IDPLAYERS: cl_idplayers.SetGenericRepDefault(iSet, CVAR_Int); break;
case USERDEFS_TEAM: playerteam = iSet; break; case USERDEFS_TEAM: playerteam.SetGenericRepDefault(iSet, CVAR_Int); break;
case USERDEFS_VIEWBOB: cl_viewbob.SetGenericRepDefault(iSet, CVAR_Int); break; case USERDEFS_VIEWBOB: cl_viewbob.SetGenericRepDefault(iSet, CVAR_Int); break;
case USERDEFS_WEAPONSWAY: cl_weaponsway.SetGenericRepDefault(iSet, CVAR_Int); break; case USERDEFS_WEAPONSWAY: cl_weaponsway.SetGenericRepDefault(iSet, CVAR_Int); break;
case USERDEFS_ANGLEINTERPOLATION: ud.angleinterpolation = iSet; break; case USERDEFS_ANGLEINTERPOLATION: ud.angleinterpolation = iSet; break;

View file

@ -34,14 +34,9 @@ user_defs ud;
const char *s_buildDate = "20120522"; const char *s_buildDate = "20120522";
#ifndef EDUKE32_STANDALONE char g_gametypeNames[MAXGAMETYPES][33]
= { "$NETMNU_GAMETYPE1", "$NETMNU_GAMETYPE2", "NETMNU_GAMETYPE3", "NETMNU_GAMETYPE4", "NETMNU_GAMETYPE5" };
char g_gametypeNames[MAXGAMETYPES][33]
= { "DukeMatch (Spawn)", "Cooperative Play", "DukeMatch (No Spawn)", "Team DM (Spawn)", "Team DM (No Spawn)" };
#else
char g_gametypeNames[MAXGAMETYPES][33]
= { "Deathmatch (Spawn)", "Cooperative Play", "Deathmatch (No Spawn)", "Team DM (Spawn)", "Team DM (No Spawn)" };
#endif
int32_t g_gametypeFlags[MAXGAMETYPES] = int32_t g_gametypeFlags[MAXGAMETYPES] =
{ {

View file

@ -56,83 +56,6 @@ BEGIN_DUKE_NS
#define USERMAPENTRYLENGTH 25 #define USERMAPENTRYLENGTH 25
/*
All MAKE_* macros are generally for the purpose of keeping state initialization
separate from actual data. Alternatively, they can serve to factor out repetitive
stuff and keep the important bits from getting lost to our eyes.
They serve as a stand-in for C++ default value constructors, since this was written
when the codebase still used C89.
Note that I prefer to include a space on the inside of the macro parentheses, since
they effectively stand in for curly braces as struct initializers.
*/
static MenuMenuFormat_t MMF_Top_Options = { { MENU_MARGIN_CENTER<<16, 38<<16, }, -(190<<16) };
static MenuMenuFormat_t MMF_Top_Joystick_Network = { { MENU_MARGIN_CENTER<<16, 70<<16, }, -(190<<16) };
static MenuMenuFormat_t MMF_BigOptions = { { MENU_MARGIN_WIDE<<16, 38<<16, }, -(190<<16) };
static MenuMenuFormat_t MMF_SmallOptions = { { MENU_MARGIN_WIDE<<16, 37<<16, }, 170<<16 };
static MenuMenuFormat_t MMF_Macros = { { 26<<16, 40<<16, }, 160<<16 };
static MenuMenuFormat_t MMF_SmallOptionsNarrow = { { MENU_MARGIN_REGULAR<<16, 38<<16, }, -(190<<16) };
static MenuMenuFormat_t MMF_KeyboardSetupFuncs = { { 50<<16, 34<<16, }, 151<<16 };
static MenuMenuFormat_t MMF_MouseJoySetupBtns = { { 76<<16, 34<<16, }, 143<<16 };
static MenuMenuFormat_t MMF_FuncList = { { 100<<16, 51<<16, }, 152<<16 };
static MenuMenuFormat_t MMF_ColorCorrect = { { MENU_MARGIN_REGULAR<<16, 86<<16, }, 190<<16 };
static MenuMenuFormat_t MMF_BigSliders = { { MENU_MARGIN_WIDE<<16, 37<<16, }, 190<<16 };
static MenuMenuFormat_t MMF_LoadSave = { { 200<<16, 49<<16, }, 145<<16 };
static MenuMenuFormat_t MMF_NetSetup = { { 36<<16, 38<<16, }, 190<<16 };
static MenuMenuFormat_t MMF_FileSelectLeft = { { 40<<16, 45<<16, }, 162<<16 };
static MenuMenuFormat_t MMF_FileSelectRight = { { 164<<16, 45<<16, }, 162<<16 };
static MenuEntryFormat_t MEF_OptionsMenu = { 7<<16, 0, 0 };
static MenuEntryFormat_t MEF_LeftMenu = { 7<<16, 0, 120<<16 };
static MenuEntryFormat_t MEF_CenterMenu = { 7<<16, 0, 0 };
static MenuEntryFormat_t MEF_BigOptions_Apply = { 4<<16, 16<<16, -(260<<16) };
static MenuEntryFormat_t MEF_BigOptionsRt = { 4<<16, 0, -(260<<16) };
static MenuEntryFormat_t MEF_BigOptionsRtSections = { 3<<16, 0, -(260<<16) };
#if defined USE_OPENGL || !defined EDUKE32_ANDROID_MENU
static MenuEntryFormat_t MEF_SmallOptions = { 1<<16, 0, -(260<<16) };
#endif
static MenuEntryFormat_t MEF_BigCheats = { 3<<16, 0, -(260<<16) };
static MenuEntryFormat_t MEF_Cheats = { 2<<16, 0, -(260<<16) };
static MenuEntryFormat_t MEF_PlayerNarrow = { 1<<16, 0, 90<<16 };
static MenuEntryFormat_t MEF_Macros = { 2<<16, -1, 268<<16 };
static MenuEntryFormat_t MEF_VideoSetup = { 4<<16, 0, 168<<16 };
static MenuEntryFormat_t MEF_VideoSetup_Apply = { 4<<16, 16<<16, 168<<16 };
static MenuEntryFormat_t MEF_KBFuncList = { 3<<16, 0, -(225<<16) };
static MenuEntryFormat_t MEF_FuncList = { 3<<16, 0, -(170<<16) };
static MenuEntryFormat_t MEF_ColorCorrect = { 2<<16, 0, -(240<<16) };
static MenuEntryFormat_t MEF_BigSliders = { 2<<16, 0, -(260<<16) };
static MenuEntryFormat_t MEF_LoadSave = { 2<<16, -1, 78<<16 };
static MenuEntryFormat_t MEF_NetSetup = { 4<<16, 0, 112<<16 };
static MenuEntryFormat_t MEF_NetSetup_Confirm = { 4<<16, 16<<16, 112<<16 };
// common menu option sets
#define MAKE_MENUOPTIONSET(optionNames, optionValues, features) { optionNames, optionValues, &MMF_FuncList, &MEF_FuncList, &MF_Minifont, ARRAY_SIZE(optionNames), -1, 0, features }
#define MAKE_MENUOPTIONSETDYN(optionNames, optionValues, numOptions, features) { optionNames, optionValues, &MMF_FuncList, &MEF_FuncList, &MF_Minifont, numOptions, -1, 0, features }
#define MAKE_MENUOPTIONSETNULL { NULL, NULL, &MMF_FuncList, &MEF_FuncList, &MF_Minifont, 0, -1, 0, 0 }
static char const *MEOSN_OffOn[] = { "Off", "On", };
static MenuOptionSet_t MEOS_OffOn = MAKE_MENUOPTIONSET( MEOSN_OffOn, NULL, 0x3 );
static char const *MEOSN_OnOff[] = { "On", "Off", };
static MenuOptionSet_t MEOS_OnOff = MAKE_MENUOPTIONSET( MEOSN_OnOff, NULL, 0x3 );
static char const *MEOSN_NoYes[] = { "No", "Yes", };
static MenuOptionSet_t MEOS_NoYes = MAKE_MENUOPTIONSET( MEOSN_NoYes, NULL, 0x3 );
static char const *MEOSN_YesNo[] = { "Yes", "No", };
static MenuOptionSet_t MEOS_YesNo = MAKE_MENUOPTIONSET( MEOSN_YesNo, NULL, 0x3 );
static FString MenuGameFuncs[NUMGAMEFUNCTIONS];
static char const *MenuGameFuncNone = " -None-";
static char const *MEOSN_Gamefuncs[NUMGAMEFUNCTIONS+1];
static int32_t MEOSV_Gamefuncs[NUMGAMEFUNCTIONS+1];
static MenuOptionSet_t MEOS_Gamefuncs = MAKE_MENUOPTIONSET( MEOSN_Gamefuncs, MEOSV_Gamefuncs, 0x1 );
/* /*
MenuEntry_t is passed in arrays of pointers so that the callback function MenuEntry_t is passed in arrays of pointers so that the callback function
that is called when an entry is modified or activated can test equality of the current that is called when an entry is modified or activated can test equality of the current
@ -141,97 +64,6 @@ entry pointer directly against the known ones, instead of relying on an ID numbe
That way, individual menu entries can be ifdef'd out painlessly. That way, individual menu entries can be ifdef'd out painlessly.
*/ */
static MenuLink_t MEO_NULL = { MENU_NULL, MA_None, };
static const char* MenuCustom = "Custom";
#define MAKE_MENUSTRING(...) { NULL, __VA_ARGS__, }
#define MAKE_MENUOPTION(...) { __VA_ARGS__, -1, }
#define MAKE_MENURANGE(...) { __VA_ARGS__, }
#define MAKE_MENUENTRY(...) { __VA_ARGS__, 0, 0, 0, }
#define MAKE_SPACER( EntryName, Height ) \
static MenuSpacer_t MEO_ ## EntryName = { Height };
MAKE_SPACER( Space2, 2<<16 ); // bigoptions
MAKE_SPACER( Space4, 4<<16 ); // usermap, smalloptions, anything else non-top
MAKE_SPACER( Space6, 6<<16 ); // videosetup
MAKE_SPACER( Space8, 8<<16 ); // colcorr, redslide
static MenuEntry_t ME_Space2_Redfont = MAKE_MENUENTRY( NULL, &MF_Redfont, &MEF_Null, &MEO_Space2, Spacer );
static MenuEntry_t ME_Space4_Bluefont = MAKE_MENUENTRY( NULL, &MF_Bluefont, &MEF_Null, &MEO_Space4, Spacer );
static MenuEntry_t ME_Space4_Redfont = MAKE_MENUENTRY( NULL, &MF_Redfont, &MEF_Null, &MEO_Space4, Spacer );
#ifndef EDUKE32_SIMPLE_MENU
static MenuEntry_t ME_Space8_Bluefont = MAKE_MENUENTRY( NULL, &MF_Bluefont, &MEF_Null, &MEO_Space8, Spacer );
#endif
static MenuEntry_t ME_Space6_Redfont = MAKE_MENUENTRY( NULL, &MF_Redfont, &MEF_Null, &MEO_Space6, Spacer );
static MenuEntry_t ME_Space8_Redfont = MAKE_MENUENTRY( NULL, &MF_Redfont, &MEF_Null, &MEO_Space8, Spacer );
static MenuEntry_t ME_SKILL_TEMPLATE = MAKE_MENUENTRY( NULL, &MF_Redfont, &MEF_CenterMenu, &MEO_NULL, Link );
static MenuEntry_t ME_SKILL[MAXSKILLS];
static MenuEntry_t *MEL_SKILL[MAXSKILLS];
static char const *MEOSN_GAMESETUP_AIM_AUTO[] = { "Never", "Always", "Hitscan only",
};
static int32_t MEOSV_GAMESETUP_AIM_AUTO[] = { 0, 1, 2,
};
static MenuOptionSet_t MEOS_GAMESETUP_AIM_AUTO = MAKE_MENUOPTIONSET( MEOSN_GAMESETUP_AIM_AUTO, MEOSV_GAMESETUP_AIM_AUTO, 0x2 );
static MenuOption_t MEO_GAMESETUP_AIM_AUTO = MAKE_MENUOPTION( &MF_Redfont, &MEOS_GAMESETUP_AIM_AUTO, &cl_autoaim );
static MenuEntry_t ME_GAMESETUP_AIM_AUTO = MAKE_MENUENTRY( "Auto aim:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_GAMESETUP_AIM_AUTO, Option );
static MenuOption_t MEO_GAMESETUP_ALWAYS_RUN = MAKE_MENUOPTION( &MF_Redfont, &MEOS_NoYes, &cl_autorun);
static MenuEntry_t ME_GAMESETUP_ALWAYS_RUN = MAKE_MENUENTRY( "Always run:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_GAMESETUP_ALWAYS_RUN, Option );
static char const *MEOSN_GAMESETUP_WEAPSWITCH_PICKUP[] = { "Never", "If new", /*"If favored",*/ };
static MenuOptionSet_t MEOS_GAMESETUP_WEAPSWITCH_PICKUP = MAKE_MENUOPTIONSET( MEOSN_GAMESETUP_WEAPSWITCH_PICKUP, NULL, 0x2 );
static MenuOption_t MEO_GAMESETUP_WEAPSWITCH_PICKUP = MAKE_MENUOPTION( &MF_Redfont, &MEOS_GAMESETUP_WEAPSWITCH_PICKUP, NULL );
static MenuEntry_t ME_GAMESETUP_WEAPSWITCH_PICKUP = MAKE_MENUENTRY( "Equip pickups:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_GAMESETUP_WEAPSWITCH_PICKUP, Option );
static char const *MEOSN_DemoRec[] = { "Off", "Running", };
static MenuOptionSet_t MEOS_DemoRec = MAKE_MENUOPTIONSET( MEOSN_DemoRec, NULL, 0x3 );
static MenuOption_t MEO_GAMESETUP_DEMOREC = MAKE_MENUOPTION( &MF_Redfont, &MEOS_OffOn, &m_recstat );
static MenuEntry_t ME_GAMESETUP_DEMOREC = MAKE_MENUENTRY( "Record demo:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_GAMESETUP_DEMOREC, Option );
static MenuOption_t MEO_ADULTMODE = MAKE_MENUOPTION(&MF_Redfont, &MEOS_OffOn, &adult_lockout);
static MenuEntry_t ME_ADULTMODE = MAKE_MENUENTRY( "Parental lock:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_ADULTMODE, Option );
#if defined(EDUKE32_ANDROID_MENU) || !defined(EDUKE32_SIMPLE_MENU)
static MenuLink_t MEO_GAMESETUP_CHEATS = { MENU_CHEATS, MA_Advance, };
static MenuEntry_t ME_GAMESETUP_CHEATS = MAKE_MENUENTRY( "Cheats", &MF_Redfont, &MEF_BigOptionsRt, &MEO_GAMESETUP_CHEATS, Link );
static MenuEntry_t *MEL_GAMESETUP[] = {
&ME_ADULTMODE,
#if defined STARTUP_SETUP_WINDOW && !defined EDUKE32_SIMPLE_MENU
&ME_GAMESETUP_STARTWIN,
#endif
#ifndef EDUKE32_ANDROID_MENU
&ME_GAMESETUP_DEMOREC,
#endif
&ME_GAMESETUP_CHEATS,
};
#endif
#ifndef EDUKE32_SIMPLE_MENU
MAKE_MENU_TOP_ENTRYLINK( "Game Setup", MEF_OptionsMenu, OPTIONS_GAMESETUP, MENU_GAMESETUP );
#endif
MAKE_MENU_TOP_ENTRYLINK( "Sound Setup", MEF_OptionsMenu, OPTIONS_SOUNDSETUP, MENU_SOUND );
MAKE_MENU_TOP_ENTRYLINK( "Display Setup", MEF_OptionsMenu, OPTIONS_DISPLAYSETUP, MENU_DISPLAYSETUP );
MAKE_MENU_TOP_ENTRYLINK( "Player Setup", MEF_OptionsMenu, OPTIONS_PLAYERSETUP, MENU_PLAYER );
#ifndef EDUKE32_ANDROID_MENU
MAKE_MENU_TOP_ENTRYLINK( "Control Setup", MEF_OptionsMenu, OPTIONS_CONTROLS, MENU_CONTROLS );
MAKE_MENU_TOP_ENTRYLINK( "Configure Controls", MEF_BigOptionsRtSections, OPTIONS_KEYBOARDSETUP, MENU_KEYBOARDSETUP );
MAKE_MENU_TOP_ENTRYLINK( "Mouse Setup", MEF_BigOptionsRtSections, OPTIONS_MOUSESETUP, MENU_MOUSESETUP );
#endif
MAKE_MENU_TOP_ENTRYLINK( "Gamepad Setup", MEF_BigOptionsRtSections, OPTIONS_JOYSTICKSETUP, MENU_JOYSTICKSETUP );
#ifdef EDUKE32_ANDROID_MENU
MAKE_MENU_TOP_ENTRYLINK( "Touch Setup", MEF_BigOptionsRtSections, OPTIONS_TOUCHSETUP, MENU_TOUCHSETUP );
#endif
#ifdef EDUKE32_SIMPLE_MENU
MAKE_MENU_TOP_ENTRYLINK("Cheats", MEF_OptionsMenu, OPTIONS_CHEATS, MENU_CHEATS);
#endif
// Zhe menu code lacks flexibility, it can either be hardwired to ints or to CVARs. // Zhe menu code lacks flexibility, it can either be hardwired to ints or to CVARs.
// Since CVARs are more important it means that these need to be implemented as CVARs even though they are just temporaries. // Since CVARs are more important it means that these need to be implemented as CVARs even though they are just temporaries.
@ -295,63 +127,8 @@ static MenuEntry_t ME_VIDEOSETUP_VSYNC = MAKE_MENUENTRY("VSync:", &MF_Redfont, &
static MenuEntry_t ME_VIDEOSETUP_APPLY = MAKE_MENUENTRY( "Apply Changes", &MF_Redfont, &MEF_BigOptions_Apply, &MEO_NULL, Link ); static MenuEntry_t ME_VIDEOSETUP_APPLY = MAKE_MENUENTRY( "Apply Changes", &MF_Redfont, &MEF_BigOptions_Apply, &MEO_NULL, Link );
static MenuLink_t MEO_DISPLAYSETUP_COLORCORR = { MENU_COLCORR, MA_Advance, };
static MenuEntry_t ME_DISPLAYSETUP_COLORCORR = MAKE_MENUENTRY( "Color Correction", &MF_Redfont, &MEF_BigOptionsRt, &MEO_DISPLAYSETUP_COLORCORR, Link );
#ifndef EDUKE32_ANDROID_MENU
static MenuOption_t MEO_DISPLAYSETUP_ASPECTRATIO = MAKE_MENUOPTION(&MF_Redfont, &MEOS_OffOn, &r_usenewaspect);
static MenuEntry_t ME_DISPLAYSETUP_ASPECTRATIO = MAKE_MENUENTRY( "Widescreen:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_DISPLAYSETUP_ASPECTRATIO, Option );
#endif
static MenuOption_t MEO_DISPLAYSETUP_VOXELS = MAKE_MENUOPTION(&MF_Redfont, &MEOS_OffOn, &r_voxels);
static MenuEntry_t ME_DISPLAYSETUP_VOXELS = MAKE_MENUENTRY( "Voxels:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_DISPLAYSETUP_VOXELS, Option );
static MenuRangeInt32_t MEO_DISPLAYSETUP_FOV = MAKE_MENURANGE( &r_fov, &MF_Redfont, 70, 120, 0, 11, 1 );
static MenuEntry_t ME_DISPLAYSETUP_FOV = MAKE_MENUENTRY( "FOV:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_DISPLAYSETUP_FOV, RangeInt32 );
#ifdef USE_OPENGL
static char const *MEOSN_DISPLAYSETUP_TEXFILTER[] = { "Classic", "Filtered" };
static int32_t MEOSV_DISPLAYSETUP_TEXFILTER[] = { TEXFILTER_OFF, TEXFILTER_ON };
static MenuOptionSet_t MEOS_DISPLAYSETUP_TEXFILTER = MAKE_MENUOPTIONSET( MEOSN_DISPLAYSETUP_TEXFILTER, MEOSV_DISPLAYSETUP_TEXFILTER, 0x2 );
static MenuOption_t MEO_DISPLAYSETUP_TEXFILTER = MAKE_MENUOPTION( &MF_Redfont, &MEOS_DISPLAYSETUP_TEXFILTER, &hw_texfilter );
static MenuEntry_t ME_DISPLAYSETUP_TEXFILTER = MAKE_MENUENTRY( "Texture Mode:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_DISPLAYSETUP_TEXFILTER, Option );
static char const *MEOSN_DISPLAYSETUP_ANISOTROPY[] = { "Max", "None", "2x", "4x", "8x", "16x", };
static int32_t MEOSV_DISPLAYSETUP_ANISOTROPY[] = { 0, 1, 2, 4, 8, 16, };
static MenuOptionSet_t MEOS_DISPLAYSETUP_ANISOTROPY = MAKE_MENUOPTIONSET( MEOSN_DISPLAYSETUP_ANISOTROPY, MEOSV_DISPLAYSETUP_ANISOTROPY, 0x0 );
static MenuOption_t MEO_DISPLAYSETUP_ANISOTROPY = MAKE_MENUOPTION(&MF_Redfont, &MEOS_DISPLAYSETUP_ANISOTROPY, &hw_anisotropy);
static MenuEntry_t ME_DISPLAYSETUP_ANISOTROPY = MAKE_MENUENTRY( "Anisotropy:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_DISPLAYSETUP_ANISOTROPY, Option );
#endif
static char const s_Scale[] = "Scale:";
static MenuOption_t MEO_SCREENSETUP_CROSSHAIR = MAKE_MENUOPTION(&MF_Redfont, &MEOS_OffOn, &cl_crosshair);
static MenuEntry_t ME_SCREENSETUP_CROSSHAIR = MAKE_MENUENTRY( "Crosshair:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_SCREENSETUP_CROSSHAIR, Option );
static MenuRangeInt32_t MEO_SCREENSETUP_CROSSHAIRSIZE = MAKE_MENURANGE( &cl_crosshairscale, &MF_Redfont, 25, 100, 0, 16, 2 );
static MenuEntry_t ME_SCREENSETUP_CROSSHAIRSIZE = MAKE_MENUENTRY( s_Scale, &MF_Redfont, &MEF_BigOptions_Apply, &MEO_SCREENSETUP_CROSSHAIRSIZE, RangeInt32 );
static MenuRangeInt32_t MEO_SCREENSETUP_SCREENSIZE = MAKE_MENURANGE( &hud_size, &MF_Redfont, 0, 11, 0, 1, EnforceIntervals );
static MenuOption_t MEO_SCREENSETUP_SCREENSIZE_TWO = MAKE_MENUOPTION( &MF_Redfont, &MEOS_OffOn, &hud_size );
static MenuEntry_t ME_SCREENSETUP_SCREENSIZE = MAKE_MENUENTRY( "Status bar:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_SCREENSETUP_SCREENSIZE, RangeInt32 );
static MenuRangeInt32_t MEO_SCREENSETUP_TEXTSIZE = MAKE_MENURANGE( &hud_textscale, &MF_Redfont, 100, 400, 0, 16, 2 );
static MenuEntry_t ME_SCREENSETUP_TEXTSIZE = MAKE_MENUENTRY( s_Scale, &MF_Redfont, &MEF_BigOptions_Apply, &MEO_SCREENSETUP_TEXTSIZE, RangeInt32 );
static MenuOption_t MEO_SCREENSETUP_LEVELSTATS = MAKE_MENUOPTION(&MF_Redfont, &MEOS_OffOn, &hud_stats);
static MenuEntry_t ME_SCREENSETUP_LEVELSTATS = MAKE_MENUENTRY( "Level stats:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_SCREENSETUP_LEVELSTATS, Option );
static MenuOption_t MEO_SCREENSETUP_SHOWPICKUPMESSAGES = MAKE_MENUOPTION(&MF_Redfont, &MEOS_OffOn, &hud_messages);
static MenuEntry_t ME_SCREENSETUP_SHOWPICKUPMESSAGES = MAKE_MENUENTRY( "Game messages:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_SCREENSETUP_SHOWPICKUPMESSAGES, Option );
static MenuRangeInt32_t MEO_SCREENSETUP_SBARSIZE = MAKE_MENURANGE( &hud_scale, &MF_Redfont, 50, 100, 0, 10, 2 );
static MenuEntry_t ME_SCREENSETUP_SBARSIZE = MAKE_MENUENTRY( s_Scale, &MF_Redfont, &MEF_BigOptions_Apply, &MEO_SCREENSETUP_SBARSIZE, RangeInt32 );
static MenuLink_t MEO_DISPLAYSETUP_SCREENSETUP = { MENU_SCREENSETUP, MA_Advance, };
static MenuEntry_t ME_DISPLAYSETUP_SCREENSETUP = MAKE_MENUENTRY( "HUD setup", &MF_Redfont, &MEF_BigOptionsRt, &MEO_DISPLAYSETUP_SCREENSETUP, Link );
#ifdef USE_OPENGL #ifdef USE_OPENGL
static MenuLink_t MEO_DISPLAYSETUP_ADVANCED_GL_POLYMOST = { MENU_POLYMOST, MA_Advance, }; static MenuLink_t MEO_DISPLAYSETUP_ADVANCED_GL_POLYMOST = { MENU_POLYMOST, MA_Advance, };
@ -446,225 +223,6 @@ static MenuEntry_t *MEL_DISPLAYSETUP_GL[] = {
static char const MenuKeyNone[] = " -";
static char const *MEOSN_Keys[NUMKEYS];
static MenuCustom2Col_t MEO_KEYBOARDSETUPFUNCS_TEMPLATE = { 0, &MF_Minifont, NUMKEYS, 54<<16, 0 };
static MenuCustom2Col_t MEO_KEYBOARDSETUPFUNCS[NUMGAMEFUNCTIONS];
static MenuEntry_t ME_KEYBOARDSETUPFUNCS_TEMPLATE = MAKE_MENUENTRY( NULL, &MF_Minifont, &MEF_KBFuncList, &MEO_KEYBOARDSETUPFUNCS_TEMPLATE, Custom2Col );
static MenuEntry_t ME_KEYBOARDSETUPFUNCS[NUMGAMEFUNCTIONS];
static MenuEntry_t *MEL_KEYBOARDSETUPFUNCS[NUMGAMEFUNCTIONS];
static MenuLink_t MEO_KEYBOARDSETUP_KEYS = { MENU_KEYBOARDKEYS, MA_Advance, };
static MenuEntry_t ME_KEYBOARDSETUP_KEYS = MAKE_MENUENTRY( "Edit Configuration", &MF_Redfont, &MEF_CenterMenu, &MEO_KEYBOARDSETUP_KEYS, Link );
static MenuLink_t MEO_KEYBOARDSETUP_RESET = { MENU_KEYSRESETVERIFY, MA_None, };
static MenuEntry_t ME_KEYBOARDSETUP_RESET = MAKE_MENUENTRY( "Reset To Defaults", &MF_Redfont, &MEF_CenterMenu, &MEO_KEYBOARDSETUP_RESET, Link );
static MenuLink_t MEO_KEYBOARDSETUP_RESETCLASSIC = { MENU_KEYSCLASSICVERIFY, MA_None, };
static MenuEntry_t ME_KEYBOARDSETUP_RESETCLASSIC = MAKE_MENUENTRY( "Reset To Classic", &MF_Redfont, &MEF_CenterMenu, &MEO_KEYBOARDSETUP_RESETCLASSIC, Link );
static MenuEntry_t *MEL_KEYBOARDSETUP[] = {
&ME_KEYBOARDSETUP_KEYS,
&ME_KEYBOARDSETUP_RESET,
&ME_KEYBOARDSETUP_RESETCLASSIC,
};
// There is no better way to do this than manually.
#define MENUMOUSEFUNCTIONS 12
static char const *MenuMouseNames[MENUMOUSEFUNCTIONS] = {
"Button 1",
"Double Button 1",
"Button 2",
"Double Button 2",
"Button 3",
"Double Button 3",
"Wheel Up",
"Wheel Down",
"Button 4",
"Double Button 4",
"Button 5",
"Double Button 5",
};
static int32_t MenuMouseDataIndex[MENUMOUSEFUNCTIONS][2] = {
{ 0, 0, },
{ 0, 1, },
{ 1, 0, },
{ 1, 1, },
{ 2, 0, },
{ 2, 1, },
// note the mouse wheel
{ 4, 0, },
{ 5, 0, },
{ 3, 0, },
{ 3, 1, },
{ 6, 0, },
{ 6, 1, },
};
static MenuOption_t MEO_MOUSEJOYSETUPBTNS_TEMPLATE = MAKE_MENUOPTION( &MF_Minifont, &MEOS_Gamefuncs, NULL );
static MenuOption_t MEO_MOUSESETUPBTNS[MENUMOUSEFUNCTIONS];
static MenuEntry_t ME_MOUSEJOYSETUPBTNS_TEMPLATE = MAKE_MENUENTRY( NULL, &MF_Minifont, &MEF_FuncList, NULL, Option );
static MenuRangeFloat_t MEO_MOUSESETUP_SENSITIVITY = MAKE_MENURANGE( &in_mousesensitivity, &MF_Redfont, .5f, 16.f, 0.f, 32, 1 );
static MenuEntry_t ME_MOUSESETUP_SENSITIVITY = MAKE_MENUENTRY( "Sensitivity:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_MOUSESETUP_SENSITIVITY, RangeFloat );
#ifndef EDUKE32_SIMPLE_MENU
static char const *MEOSN_MOUSESETUP_AIM_TYPE [] = { "Toggle", "Hold" };
static MenuOptionSet_t MEOS_MOUSESETUP_AIM_TYPE = MAKE_MENUOPTIONSET(MEOSN_MOUSESETUP_AIM_TYPE, NULL, 0x2);
static MenuOption_t MEO_MOUSESETUP_MOUSEAIMINGTYPE = MAKE_MENUOPTION(&MF_Redfont, &MEOS_MOUSESETUP_AIM_TYPE, &in_aimmode);
static MenuEntry_t ME_MOUSESETUP_MOUSEAIMINGTYPE = MAKE_MENUENTRY("Aiming type:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_MOUSESETUP_MOUSEAIMINGTYPE, Option);
static MenuOption_t MEO_MOUSESETUP_MOUSEAIMING = MAKE_MENUOPTION( &MF_Redfont, &MEOS_NoYes, &in_mousemode );
static MenuEntry_t ME_MOUSESETUP_MOUSEAIMING = MAKE_MENUENTRY( "Vertical aiming:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_MOUSESETUP_MOUSEAIMING, Option );
#endif
static MenuOption_t MEO_MOUSESETUP_INVERT = MAKE_MENUOPTION( &MF_Redfont, &MEOS_YesNo, &in_mouseflip );
static MenuEntry_t ME_MOUSESETUP_INVERT = MAKE_MENUENTRY( "Invert aiming:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_MOUSESETUP_INVERT, Option );
static MenuOption_t MEO_MOUSESETUP_SMOOTH = MAKE_MENUOPTION( &MF_Redfont, &MEOS_NoYes, &in_mousesmoothing );
static MenuEntry_t ME_MOUSESETUP_SMOOTH = MAKE_MENUENTRY( "Filter input:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_MOUSESETUP_SMOOTH, Option );
#ifndef EDUKE32_SIMPLE_MENU
static MenuLink_t MEO_MOUSESETUP_ADVANCED = { MENU_MOUSEADVANCED, MA_Advance, };
static MenuEntry_t ME_MOUSESETUP_ADVANCED = MAKE_MENUENTRY( "Advanced setup", &MF_Redfont, &MEF_BigOptionsRt, &MEO_MOUSESETUP_ADVANCED, Link );
#endif
static MenuRangeInt32_t MEO_MOUSEADVANCED_SCALEX = MAKE_MENURANGE(&in_mousescalex, &MF_Redfont, -262144, 262144, 65536, 161, 3);
static MenuEntry_t ME_MOUSEADVANCED_SCALEX = MAKE_MENUENTRY("X-Scale:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_MOUSEADVANCED_SCALEX, RangeInt32);
static MenuRangeInt32_t MEO_MOUSEADVANCED_SCALEY = MAKE_MENURANGE(&in_mousescaley, &MF_Redfont, -262144, 262144, 65536, 161, 3);
static MenuEntry_t ME_MOUSEADVANCED_SCALEY = MAKE_MENUENTRY("Y-Scale:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_MOUSEADVANCED_SCALEY, RangeInt32);
static MenuEntry_t *MEL_MOUSESETUP[] = {
&ME_MOUSESETUP_SENSITIVITY,
#ifdef EDUKE32_SIMPLE_MENU
&ME_MOUSEADVANCED_SCALEX,
&ME_MOUSEADVANCED_SCALEY,
#endif
&ME_Space2_Redfont,
&ME_MOUSESETUP_INVERT,
&ME_MOUSESETUP_SMOOTH,
#ifndef EDUKE32_SIMPLE_MENU
&ME_MOUSESETUP_MOUSEAIMINGTYPE,
&ME_MOUSESETUP_MOUSEAIMING,
&ME_MOUSESETUP_ADVANCED,
#endif
};
#ifdef EDUKE32_ANDROID_MENU
static MenuRangeFloat_t MEO_TOUCHSETUP_SENSITIVITY_MOVE = MAKE_MENURANGE(&droidinput.forward_sens, &MF_Redfont, 1.f, 9.f, 0.f, 17, 1 + EnforceIntervals);
static MenuEntry_t ME_TOUCHSETUP_SENSITIVITY_MOVE = MAKE_MENUENTRY("Running:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_TOUCHSETUP_SENSITIVITY_MOVE, RangeFloat);
static MenuRangeFloat_t MEO_TOUCHSETUP_SENSITIVITY_STRAFE = MAKE_MENURANGE(&droidinput.strafe_sens, &MF_Redfont, 1.f, 9.f, 0.f, 17, 1 + EnforceIntervals);
static MenuEntry_t ME_TOUCHSETUP_SENSITIVITY_STRAFE = MAKE_MENUENTRY("Strafing:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_TOUCHSETUP_SENSITIVITY_STRAFE, RangeFloat);
static MenuRangeFloat_t MEO_TOUCHSETUP_SENSITIVITY_LOOK = MAKE_MENURANGE(&droidinput.pitch_sens, &MF_Redfont, 1.f, 9.f, 0.f, 17, 1 + EnforceIntervals);
static MenuEntry_t ME_TOUCHSETUP_SENSITIVITY_LOOK = MAKE_MENUENTRY("Looking:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_TOUCHSETUP_SENSITIVITY_LOOK, RangeFloat);
static MenuRangeFloat_t MEO_TOUCHSETUP_SENSITIVITY_TURN = MAKE_MENURANGE(&droidinput.yaw_sens, &MF_Redfont, 1.f, 9.f, 0.f, 17, 1 + EnforceIntervals);
static MenuEntry_t ME_TOUCHSETUP_SENSITIVITY_TURN = MAKE_MENUENTRY("Turning:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_TOUCHSETUP_SENSITIVITY_TURN, RangeFloat);
static MenuOption_t MEO_TOUCHSETUP_INVERT = MAKE_MENUOPTION(&MF_Redfont, &MEOS_NoYes, &droidinput.invertLook);
static MenuEntry_t ME_TOUCHSETUP_INVERT = MAKE_MENUENTRY("Invert look:", &MF_Redfont, &MEF_BigOptionsRt, &MEO_TOUCHSETUP_INVERT, Option);
MAKE_MENU_TOP_ENTRYLINK("Sensitivity", MEF_CenterMenu, TOUCHSENS, MENU_TOUCHSENS);
MAKE_MENU_TOP_ENTRYLINK("Button Setup", MEF_CenterMenu, TOUCHBUTTONS, MENU_TOUCHBUTTONS);
static MenuEntry_t *MEL_TOUCHSETUP [] = {
&ME_TOUCHSENS,
&ME_TOUCHBUTTONS,
};
static MenuEntry_t *MEL_TOUCHSENS [] = {
&ME_TOUCHSETUP_SENSITIVITY_MOVE,
&ME_TOUCHSETUP_SENSITIVITY_STRAFE,
&ME_TOUCHSETUP_SENSITIVITY_LOOK,
&ME_TOUCHSETUP_SENSITIVITY_TURN,
&ME_Space2_Redfont,
&ME_TOUCHSETUP_INVERT,
};
#endif
static MenuOption_t MEO_JOYSTICK_ENABLE = MAKE_MENUOPTION( &MF_Redfont, &MEOS_OffOn, &in_joystick );
static MenuEntry_t ME_JOYSTICK_ENABLE = MAKE_MENUENTRY( "Enable Gamepad:", &MF_Redfont, &MEF_BigOptionsRtSections, &MEO_JOYSTICK_ENABLE, Option );
MAKE_MENU_TOP_ENTRYLINK( "Edit Buttons", MEF_BigOptionsRtSections, JOYSTICK_EDITBUTTONS, MENU_JOYSTICKBTNS );
MAKE_MENU_TOP_ENTRYLINK( "Edit Axes", MEF_BigOptionsRtSections, JOYSTICK_EDITAXES, MENU_JOYSTICKAXES );
static MenuLink_t MEO_JOYSTICK_DEFAULTS_STANDARD = { MENU_JOYSTANDARDVERIFY, MA_None, };
static MenuEntry_t ME_JOYSTICK_DEFAULTS_STANDARD = MAKE_MENUENTRY( "Use Standard Layout", &MF_Redfont, &MEF_BigOptionsRtSections, &MEO_JOYSTICK_DEFAULTS_STANDARD, Link );
static MenuLink_t MEO_JOYSTICK_DEFAULTS_PRO = { MENU_JOYPROVERIFY, MA_None, };
static MenuEntry_t ME_JOYSTICK_DEFAULTS_PRO = MAKE_MENUENTRY( "Use Pro Layout", &MF_Redfont, &MEF_BigOptionsRtSections, &MEO_JOYSTICK_DEFAULTS_PRO, Link );
static MenuLink_t MEO_JOYSTICK_DEFAULTS_CLEAR = { MENU_JOYCLEARVERIFY, MA_None, };
static MenuEntry_t ME_JOYSTICK_DEFAULTS_CLEAR = MAKE_MENUENTRY( "Clear All Settings", &MF_Redfont, &MEF_BigOptionsRtSections, &MEO_JOYSTICK_DEFAULTS_CLEAR, Link );
static MenuEntry_t *MEL_JOYSTICKSETUP[] = {
&ME_JOYSTICK_ENABLE,
&ME_Space6_Redfont,
&ME_JOYSTICK_EDITBUTTONS,
&ME_JOYSTICK_EDITAXES,
&ME_Space6_Redfont,
&ME_JOYSTICK_DEFAULTS_STANDARD,
&ME_JOYSTICK_DEFAULTS_PRO,
&ME_JOYSTICK_DEFAULTS_CLEAR,
};
#define MAXJOYBUTTONSTRINGLENGTH 32
static char MenuJoystickNames[MAXJOYBUTTONSANDHATS*2][MAXJOYBUTTONSTRINGLENGTH];
static MenuOption_t MEO_JOYSTICKBTNS[MAXJOYBUTTONSANDHATS*2];
static MenuEntry_t ME_JOYSTICKBTNS[MAXJOYBUTTONSANDHATS*2];
static MenuEntry_t *MEL_JOYSTICKBTNS[MAXJOYBUTTONSANDHATS*2];
static MenuLink_t MEO_JOYSTICKAXES = { MENU_JOYSTICKAXIS, MA_Advance, };
static MenuEntry_t ME_JOYSTICKAXES_TEMPLATE = MAKE_MENUENTRY( NULL, &MF_Redfont, &MEF_BigSliders, &MEO_JOYSTICKAXES, Link );
static MenuEntry_t ME_JOYSTICKAXES[MAXJOYAXES];
static char MenuJoystickAxes[MAXJOYAXES][MAXJOYBUTTONSTRINGLENGTH];
static MenuEntry_t *MEL_JOYSTICKAXES[MAXJOYAXES];
static MenuEntry_t *MEL_MOUSEADVANCED[] = {
&ME_MOUSEADVANCED_SCALEX,
&ME_MOUSEADVANCED_SCALEY,
};
static const char *MenuJoystickHatDirections[] = { "Up", "Right", "Down", "Left", };
static char const *MEOSN_JOYSTICKAXIS_ANALOG[] = { " -None-", "Turning", "Strafing", "Looking", "Moving", };
static int32_t MEOSV_JOYSTICKAXIS_ANALOG[] = { -1, analog_turning, analog_strafing, analog_lookingupanddown, analog_moving, };
static MenuOptionSet_t MEOS_JOYSTICKAXIS_ANALOG = MAKE_MENUOPTIONSET( MEOSN_JOYSTICKAXIS_ANALOG, MEOSV_JOYSTICKAXIS_ANALOG, 0x0 );
static MenuOption_t MEO_JOYSTICKAXIS_ANALOG = MAKE_MENUOPTION( &MF_Bluefont, &MEOS_JOYSTICKAXIS_ANALOG, NULL );
static MenuEntry_t ME_JOYSTICKAXIS_ANALOG = MAKE_MENUENTRY( "Analog", &MF_Redfont, &MEF_BigSliders, &MEO_JOYSTICKAXIS_ANALOG, Option );
static MenuRangeInt32_t MEO_JOYSTICKAXIS_SCALE = MAKE_MENURANGE( NULL, &MF_Bluefont, -262144, 262144, 65536, 161, 3 );
static MenuEntry_t ME_JOYSTICKAXIS_SCALE = MAKE_MENUENTRY( "Scale", &MF_Redfont, &MEF_BigSliders, &MEO_JOYSTICKAXIS_SCALE, RangeInt32 );
static MenuOption_t MEO_JOYSTICKAXIS_INVERT = MAKE_MENUOPTION( &MF_Redfont, &MEOS_OffOn, NULL );
static MenuEntry_t ME_JOYSTICKAXIS_INVERT = MAKE_MENUENTRY( "Invert", &MF_Redfont, &MEF_BigSliders, &MEO_JOYSTICKAXIS_INVERT, Option );
static MenuRangeInt32_t MEO_JOYSTICKAXIS_DEAD = MAKE_MENURANGE( NULL, &MF_Bluefont, 0, 10000, 0, 101, 2 );
static MenuEntry_t ME_JOYSTICKAXIS_DEAD = MAKE_MENUENTRY( "Dead Zone", &MF_Redfont, &MEF_BigSliders, &MEO_JOYSTICKAXIS_DEAD, RangeInt32 );
static MenuRangeInt32_t MEO_JOYSTICKAXIS_SATU = MAKE_MENURANGE( NULL, &MF_Bluefont, 0, 10000, 0, 101, 2 );
static MenuEntry_t ME_JOYSTICKAXIS_SATU = MAKE_MENUENTRY( "Saturation", &MF_Redfont, &MEF_BigSliders, &MEO_JOYSTICKAXIS_SATU, RangeInt32 );
static MenuOption_t MEO_JOYSTICKAXIS_DIGITALNEGATIVE = MAKE_MENUOPTION( &MF_Minifont, &MEOS_Gamefuncs, NULL );
static MenuEntry_t ME_JOYSTICKAXIS_DIGITALNEGATIVE = MAKE_MENUENTRY( "Digital -", &MF_Bluefont, &MEF_BigSliders, &MEO_JOYSTICKAXIS_DIGITALNEGATIVE, Option );
static MenuOption_t MEO_JOYSTICKAXIS_DIGITALPOSITIVE = MAKE_MENUOPTION( &MF_Minifont, &MEOS_Gamefuncs, NULL );
static MenuEntry_t ME_JOYSTICKAXIS_DIGITALPOSITIVE = MAKE_MENUENTRY( "Digital +", &MF_Bluefont, &MEF_BigSliders, &MEO_JOYSTICKAXIS_DIGITALPOSITIVE, Option );
static MenuEntry_t *MEL_JOYSTICKAXIS[] = {
&ME_JOYSTICKAXIS_ANALOG,
&ME_JOYSTICKAXIS_SCALE,
&ME_JOYSTICKAXIS_INVERT,
&ME_JOYSTICKAXIS_DEAD,
&ME_JOYSTICKAXIS_SATU,
&ME_Space8_Redfont,
&ME_JOYSTICKAXIS_DIGITALNEGATIVE,
&ME_JOYSTICKAXIS_DIGITALPOSITIVE,
};
static MenuEntry_t *MEL_INTERNAL_JOYSTICKAXIS_DIGITAL[] = {
&ME_JOYSTICKAXIS_DIGITALNEGATIVE,
&ME_JOYSTICKAXIS_DIGITALPOSITIVE,
};
#ifdef USE_OPENGL #ifdef USE_OPENGL
static MenuOption_t MEO_RENDERERSETUP_HIGHTILE = MAKE_MENUOPTION( &MF_Bluefont, &MEOS_NoYes, &hw_hightile ); static MenuOption_t MEO_RENDERERSETUP_HIGHTILE = MAKE_MENUOPTION( &MF_Bluefont, &MEOS_NoYes, &hw_hightile );
@ -702,14 +260,6 @@ static MenuEntry_t *MEL_RENDERERSETUP_POLYMOST[] = {
#endif #endif
static MenuRangeFloat_t MEO_COLCORR_GAMMA = MAKE_MENURANGE( &vid_gamma, &MF_Bluefont, 0.3f, 4.f, 0.f, 75, 1 );
static MenuEntry_t ME_COLCORR_GAMMA = MAKE_MENUENTRY( "Gamma:", &MF_Redfont, &MEF_ColorCorrect, &MEO_COLCORR_GAMMA, RangeFloat );
static MenuRangeFloat_t MEO_COLCORR_CONTRAST = MAKE_MENURANGE( &vid_contrast, &MF_Bluefont, 0.1f, 2.7f, 0.f, 53, 1 );
static MenuEntry_t ME_COLCORR_CONTRAST = MAKE_MENUENTRY( "Contrast:", &MF_Redfont, &MEF_ColorCorrect, &MEO_COLCORR_CONTRAST, RangeFloat );
static MenuRangeFloat_t MEO_COLCORR_BRIGHTNESS = MAKE_MENURANGE( &vid_brightness, &MF_Bluefont, -0.8f, 0.8f, 0.f, 33, 1 );
static MenuEntry_t ME_COLCORR_BRIGHTNESS = MAKE_MENUENTRY( "Brightness:", &MF_Redfont, &MEF_ColorCorrect, &MEO_COLCORR_BRIGHTNESS, RangeFloat );
static MenuLink_t MEO_COLCORR_RESET = { MENU_COLCORRRESETVERIFY, MA_None, };
static MenuEntry_t ME_COLCORR_RESET = MAKE_MENUENTRY( "Reset To Defaults", &MF_Redfont, &MEF_ColorCorrect, &MEO_COLCORR_RESET, Link );
#ifdef EDUKE32_ANDROID_MENU #ifdef EDUKE32_ANDROID_MENU
#define MINVIS 1.f #define MINVIS 1.f
#else #else
@ -748,22 +298,6 @@ static MenuEntry_t *MEL_SCREENSETUP[] = {
&ME_SCREENSETUP_SHOWPICKUPMESSAGES, &ME_SCREENSETUP_SHOWPICKUPMESSAGES,
}; };
// Save and load will be filled in before every viewing of the save/load screen.
static MenuLink_t MEO_LOAD = { MENU_LOADVERIFY, MA_None, };
static MenuEntry_t ME_LOAD_TEMPLATE = MAKE_MENUENTRY( NULL, &MF_Minifont, &MEF_LoadSave, &MEO_LOAD, Link );
static MenuEntry_t ME_LOAD_EMPTY = MAKE_MENUENTRY( NULL, &MF_Minifont, &MEF_LoadSave, nullptr, Dummy );
static MenuEntry_t *ME_LOAD;
static MenuEntry_t **MEL_LOAD;
static char const s_NewSaveGame[] = "(New Save Game)";
static MenuString_t MEO_SAVE_TEMPLATE = MAKE_MENUSTRING( NULL, &MF_Minifont, MAXSAVEGAMENAME, 0 );
static MenuString_t MEO_SAVE_NEW = MAKE_MENUSTRING( NULL, &MF_Minifont, MAXSAVEGAMENAME, 0 );
static MenuString_t *MEO_SAVE;
static MenuEntry_t ME_SAVE_TEMPLATE = MAKE_MENUENTRY( NULL, &MF_Minifont, &MEF_LoadSave, &MEO_SAVE_TEMPLATE, String );
static MenuEntry_t ME_SAVE_NEW = MAKE_MENUENTRY( s_NewSaveGame, &MF_Minifont, &MEF_LoadSave, &MEO_SAVE_NEW, String );
static MenuEntry_t *ME_SAVE;
static MenuEntry_t **MEL_SAVE;
CVAR_UNAMED(Int, soundrate) CVAR_UNAMED(Int, soundrate)
CVAR_UNAMED(Int, soundvoices) CVAR_UNAMED(Int, soundvoices)
CVAR_UNAMED(Int, musicdevice) CVAR_UNAMED(Int, musicdevice)
@ -865,123 +399,6 @@ static MenuEntry_t *MEL_SAVESETUP[] = {
}; };
MAKE_MENU_TOP_ENTRYLINK( "Player Setup", MEF_CenterMenu, NETWORK_PLAYERSETUP, MENU_PLAYER );
MAKE_MENU_TOP_ENTRYLINK( "Join Game", MEF_CenterMenu, NETWORK_JOINGAME, MENU_NETJOIN );
MAKE_MENU_TOP_ENTRYLINK( "Host Game", MEF_CenterMenu, NETWORK_HOSTGAME, MENU_NETHOST );
static MenuEntry_t *MEL_NETWORK[] = {
&ME_NETWORK_PLAYERSETUP,
&ME_NETWORK_JOINGAME,
&ME_NETWORK_HOSTGAME,
};
//static MenuString_t MEO_PLAYER_NAME = MAKE_MENUSTRING( playername, &MF_Bluefont, MAXPLAYERNAME, 0 );
//static MenuEntry_t ME_PLAYER_NAME = MAKE_MENUENTRY( "Name", &MF_Bluefont, &MEF_PlayerNarrow, &MEO_PLAYER_NAME, String );
static char const *MEOSN_PLAYER_COLOR[] = { "Auto", "Blue", "Red", "Green", "Gray", "Dark gray", "Dark green", "Brown", "Dark blue", "Bright red", "Yellow", };
static int32_t MEOSV_PLAYER_COLOR[] = { 0, 9, 10, 11, 12, 13, 14, 15, 16, 21, 23, };
static MenuOptionSet_t MEOS_PLAYER_COLOR = MAKE_MENUOPTIONSET( MEOSN_PLAYER_COLOR, MEOSV_PLAYER_COLOR, 0x2 );
static MenuOption_t MEO_PLAYER_COLOR = MAKE_MENUOPTION( &MF_Bluefont, &MEOS_PLAYER_COLOR, &playercolor );
static MenuEntry_t ME_PLAYER_COLOR = MAKE_MENUENTRY( "Color", &MF_Bluefont, &MEF_PlayerNarrow, &MEO_PLAYER_COLOR, Option );
static char const *MEOSN_PLAYER_TEAM[] = { "Blue", "Red", "Green", "Gray", };
static MenuOptionSet_t MEOS_PLAYER_TEAM = MAKE_MENUOPTIONSET( MEOSN_PLAYER_TEAM, NULL, 0x2 );
static MenuOption_t MEO_PLAYER_TEAM = MAKE_MENUOPTION( &MF_Bluefont, &MEOS_PLAYER_TEAM, &playerteam );
static MenuEntry_t ME_PLAYER_TEAM = MAKE_MENUENTRY( "Team", &MF_Bluefont, &MEF_PlayerNarrow, &MEO_PLAYER_TEAM, Option );
#ifndef EDUKE32_SIMPLE_MENU
static MenuLink_t MEO_PLAYER_MACROS = { MENU_MACROS, MA_Advance, };
static MenuEntry_t ME_PLAYER_MACROS = MAKE_MENUENTRY( "Multiplayer macros", &MF_Bluefont, &MEF_SmallOptions, &MEO_PLAYER_MACROS, Link );
#endif
static MenuEntry_t *MEL_PLAYER[] = {
//&ME_PLAYER_NAME,
&ME_Space4_Bluefont,
&ME_PLAYER_COLOR,
&ME_Space4_Bluefont,
&ME_PLAYER_TEAM,
#ifndef EDUKE32_SIMPLE_MENU
&ME_Space8_Bluefont,
&ME_PLAYER_MACROS,
#endif
};
#define MAXRIDECULE 10
#define MAXRIDECULELENGTH 40
static MenuString_t MEO_MACROS_TEMPLATE = MAKE_MENUSTRING( NULL, &MF_Bluefont, MAXRIDECULELENGTH, 0 );
static MenuString_t MEO_MACROS[10];
static MenuEntry_t ME_MACROS_TEMPLATE = MAKE_MENUENTRY( NULL, &MF_Bluefont, &MEF_Macros, &MEO_MACROS_TEMPLATE, String );
static char sink[50];
static MenuEntry_t ME_MACROS[MAXRIDECULE];
static MenuEntry_t *MEL_MACROS[MAXRIDECULE];
#ifndef EDUKE32_SIMPLE_MENU
static char const *MenuUserMap = "User Map";
#endif
static char const *MenuSkillNone = "None";
static char const *MEOSN_NetGametypes[MAXGAMETYPES];
static char const *MEOSN_NetEpisodes[MAXVOLUMES+1];
static int32_t MEOSV_NetEpisodes[MAXVOLUMES+1];
static char const *MEOSN_NetLevels[MAXVOLUMES][MAXLEVELS];
static char const *MEOSN_NetSkills[MAXSKILLS+1];
static MenuLink_t MEO_NETHOST_OPTIONS = { MENU_NETOPTIONS, MA_Advance, };
static MenuEntry_t ME_NETHOST_OPTIONS = MAKE_MENUENTRY( "Game Options", &MF_Redfont, &MEF_VideoSetup, &MEO_NETHOST_OPTIONS, Link );
static MenuEntry_t ME_NETHOST_LAUNCH = MAKE_MENUENTRY( "Launch Game", &MF_Redfont, &MEF_VideoSetup, &MEO_NULL, Link );
static MenuEntry_t *MEL_NETHOST[] = {
&ME_NETHOST_OPTIONS,
&ME_NETHOST_LAUNCH,
};
static MenuOptionSet_t MEOS_NETOPTIONS_GAMETYPE = MAKE_MENUOPTIONSET( MEOSN_NetGametypes, NULL, 0x0 );
static MenuOption_t MEO_NETOPTIONS_GAMETYPE = MAKE_MENUOPTION( &MF_Bluefont, &MEOS_NETOPTIONS_GAMETYPE, &m_coop );
static MenuEntry_t ME_NETOPTIONS_GAMETYPE = MAKE_MENUENTRY( "Game Type", &MF_Redfont, &MEF_NetSetup, &MEO_NETOPTIONS_GAMETYPE, Option );
static MenuOptionSet_t MEOS_NETOPTIONS_EPISODE = MAKE_MENUOPTIONSET( MEOSN_NetEpisodes, MEOSV_NetEpisodes, 0x0 );
CVAR_UNAMED(Int, NetEpisode);
static MenuOption_t MEO_NETOPTIONS_EPISODE = MAKE_MENUOPTION( &MF_Bluefont, &MEOS_NETOPTIONS_EPISODE, &NetEpisode );
static MenuEntry_t ME_NETOPTIONS_EPISODE = MAKE_MENUENTRY( "Episode", &MF_Redfont, &MEF_NetSetup, &MEO_NETOPTIONS_EPISODE, Option );
static MenuOptionSet_t MEOS_NETOPTIONS_LEVEL_TEMPLATE = MAKE_MENUOPTIONSETNULL;
static MenuOptionSet_t MEOS_NETOPTIONS_LEVEL[MAXVOLUMES];
static MenuOption_t MEO_NETOPTIONS_LEVEL = MAKE_MENUOPTION( &MF_Bluefont, NULL, &m_level_number );
static MenuEntry_t ME_NETOPTIONS_LEVEL = MAKE_MENUENTRY( "Level", &MF_Redfont, &MEF_NetSetup, &MEO_NETOPTIONS_LEVEL, Option );
static MenuLink_t MEO_NETOPTIONS_USERMAP = { MENU_NETUSERMAP, MA_Advance, };
static MenuEntry_t ME_NETOPTIONS_USERMAP = MAKE_MENUENTRY( "User Map", &MF_Redfont, &MEF_NetSetup, &MEO_NETOPTIONS_USERMAP, Link );
static MenuOptionSet_t MEOS_NETOPTIONS_MONSTERS = MAKE_MENUOPTIONSET( MEOSN_NetSkills, NULL, 0x0 );
static MenuOption_t MEO_NETOPTIONS_MONSTERS = MAKE_MENUOPTION( &MF_Bluefont, &MEOS_NETOPTIONS_MONSTERS, NULL );
static MenuEntry_t ME_NETOPTIONS_MONSTERS = MAKE_MENUENTRY( "Monsters", &MF_Redfont, &MEF_NetSetup, &MEO_NETOPTIONS_MONSTERS, Option );
static MenuOption_t MEO_NETOPTIONS_MARKERS = MAKE_MENUOPTION( &MF_Bluefont, &MEOS_OffOn, &m_marker );
static MenuEntry_t ME_NETOPTIONS_MARKERS = MAKE_MENUENTRY( "Markers", &MF_Redfont, &MEF_NetSetup, &MEO_NETOPTIONS_MARKERS, Option );
static MenuOption_t MEO_NETOPTIONS_MAPEXITS = MAKE_MENUOPTION( &MF_Bluefont, &MEOS_OnOff, &m_noexits );
static MenuEntry_t ME_NETOPTIONS_MAPEXITS = MAKE_MENUENTRY( "Map Exits", &MF_Redfont, &MEF_NetSetup, &MEO_NETOPTIONS_MAPEXITS, Option );
static MenuOption_t MEO_NETOPTIONS_FRFIRE = MAKE_MENUOPTION( &MF_Bluefont, &MEOS_OffOn, &m_ffire );
static MenuEntry_t ME_NETOPTIONS_FRFIRE = MAKE_MENUENTRY( "Fr. Fire", &MF_Redfont, &MEF_NetSetup, &MEO_NETOPTIONS_FRFIRE, Option );
static MenuEntry_t ME_NETOPTIONS_ACCEPT = MAKE_MENUENTRY( "Accept", &MF_Redfont, &MEF_NetSetup_Confirm, &MEO_NETWORK_HOSTGAME, Link );
static MenuEntry_t *MEL_NETOPTIONS[] = {
&ME_NETOPTIONS_GAMETYPE,
&ME_NETOPTIONS_EPISODE,
&ME_NETOPTIONS_LEVEL,
&ME_NETOPTIONS_MONSTERS,
&ME_NETOPTIONS_MARKERS,
&ME_NETOPTIONS_MAPEXITS,
&ME_NETOPTIONS_ACCEPT,
};
static char MenuServer[BMAX_PATH] = "localhost";
static MenuString_t MEO_NETJOIN_SERVER = MAKE_MENUSTRING( MenuServer, &MF_Bluefont, BMAX_PATH, 0 );
static MenuEntry_t ME_NETJOIN_SERVER = MAKE_MENUENTRY( "Server", &MF_Redfont, &MEF_VideoSetup, &MEO_NETJOIN_SERVER, String );
#define MAXPORTSTRINGLENGTH 6 // unsigned 16-bit integer
static char MenuPort[MAXPORTSTRINGLENGTH] = "19014";
static MenuString_t MEO_NETJOIN_PORT = MAKE_MENUSTRING( MenuPort, &MF_Bluefont, MAXPORTSTRINGLENGTH, INPUT_NUMERIC );
static MenuEntry_t ME_NETJOIN_PORT = MAKE_MENUENTRY( "Port", &MF_Redfont, &MEF_VideoSetup, &MEO_NETJOIN_PORT, String );
static MenuEntry_t ME_NETJOIN_CONNECT = MAKE_MENUENTRY( "Connect", &MF_Redfont, &MEF_VideoSetup_Apply, &MEO_NULL, Link );
static MenuEntry_t *MEL_NETJOIN[] = {
&ME_NETJOIN_SERVER,
&ME_NETJOIN_PORT,
&ME_NETJOIN_CONNECT,
};
#define NoTitle NULL #define NoTitle NULL
#define MAKE_MENUMENU(Title, Format, Entries) { Title, Format, Entries, ARRAY_SIZE(Entries), 0, 0, 0 } #define MAKE_MENUMENU(Title, Format, Entries) { Title, Format, Entries, ARRAY_SIZE(Entries), 0, 0, 0 }
@ -1052,86 +469,6 @@ static MenuTextForm_t M_CHEATENTRY = { NULL, "Enter Cheat Code:", MAXCHEATLEN, 0
static MenuTextForm_t M_CHEAT_WARP = { NULL, "Enter Warp #:", 3, 0 }; static MenuTextForm_t M_CHEAT_WARP = { NULL, "Enter Warp #:", 3, 0 };
static MenuTextForm_t M_CHEAT_SKILL = { NULL, "Enter Skill #:", 1, 0 }; static MenuTextForm_t M_CHEAT_SKILL = { NULL, "Enter Skill #:", 1, 0 };
//#define MAKE_MENUFILESELECT(a, dir, b, c) { a, { &MMF_FileSelectLeft, &MMF_FileSelectRight }, { &MF_Minifont, &MF_Minifont }, dir, b, c, { NULL, NULL }, { 0, 0 }, { 3<<16, 3<<16 }, FNLIST_INITIALIZER, 0 }
//static MenuFileSelect_t M_USERMAP = MAKE_MENUFILESELECT( "Select A User Map", "./usermaps/", "*.map", boardfilename );
// MUST be in ascending order of MenuID enum values due to binary search
static Menu_t Menus[] = {
#ifndef EDUKE32_SIMPLE_MENU
{ &M_GAMESETUP, MENU_GAMESETUP, MENU_OPTIONS, MA_Return, Menu },
#endif
{ &M_OPTIONS, MENU_OPTIONS, MENU_MAIN, MA_Return, Menu },
{ &M_VIDEOSETUP, MENU_VIDEOSETUP, MENU_DISPLAYSETUP, MA_Return, Menu },
{ &M_KEYBOARDSETUP, MENU_KEYBOARDSETUP, MENU_CONTROLS, MA_Return, Menu },
{ &M_MOUSESETUP, MENU_MOUSESETUP, MENU_CONTROLS, MA_Return, Menu },
{ &M_JOYSTICKSETUP, MENU_JOYSTICKSETUP, MENU_CONTROLS, MA_Return, Menu },
{ &M_JOYSTICKAXES, MENU_JOYSTICKAXES, MENU_JOYSTICKSETUP, MA_Return, Menu },
{ &M_KEYBOARDKEYS, MENU_KEYBOARDKEYS, MENU_KEYBOARDSETUP, MA_Return, Menu },
{ &M_MOUSEADVANCED, MENU_MOUSEADVANCED, MENU_MOUSESETUP, MA_Return, Menu },
{ &M_JOYSTICKAXIS, MENU_JOYSTICKAXIS, MENU_JOYSTICKAXES, MA_Return, Menu },
{ &M_CONTROLS, MENU_CONTROLS, MENU_OPTIONS, MA_Return, Menu },
#ifdef USE_OPENGL
{ &M_RENDERERSETUP_POLYMOST, MENU_POLYMOST, MENU_DISPLAYSETUP, MA_Return, Menu },
#endif
{ &M_COLCORR, MENU_COLCORR, MENU_DISPLAYSETUP, MA_Return, Menu },
{ &M_COLCORR, MENU_COLCORR_INGAME, MENU_CLOSE, MA_Return, Menu },
{ &M_SCREENSETUP, MENU_SCREENSETUP, MENU_DISPLAYSETUP, MA_Return, Menu },
{ &M_DISPLAYSETUP, MENU_DISPLAYSETUP, MENU_OPTIONS, MA_Return, Menu },
#ifdef POLYMER
{ &M_RENDERERSETUP_POLYMER, MENU_POLYMER, MENU_DISPLAYSETUP, MA_Return, Menu },
#endif
{ &M_LOAD, MENU_LOAD, MENU_MAIN, MA_Return, Menu },
{ &M_SAVE, MENU_SAVE, MENU_MAIN, MA_Return, Menu },
{ &M_STORY, MENU_STORY, MENU_MAIN, MA_Return, Panel },
{ &M_F1HELP, MENU_F1HELP, MENU_MAIN, MA_Return, Panel },
{ &M_QUIT, MENU_QUIT, MENU_PREVIOUS, MA_Return, Verify },
{ &M_QUITTOTITLE, MENU_QUITTOTITLE, MENU_PREVIOUS, MA_Return, Verify },
{ &M_QUIT, MENU_QUIT_INGAME, MENU_CLOSE, MA_None, Verify },
{ &M_NETHOST, MENU_NETSETUP, MENU_MAIN, MA_Return, Menu },
{ &M_NETWAITMASTER, MENU_NETWAITMASTER, MENU_MAIN, MA_Return, Message },
{ &M_NETWAITVOTES, MENU_NETWAITVOTES, MENU_MAIN, MA_Return, Message },
{ &M_SOUND, MENU_SOUND, MENU_OPTIONS, MA_Return, Menu },
{ &M_SOUND, MENU_SOUND_INGAME, MENU_CLOSE, MA_Return, Menu },
{ &M_ADVSOUND, MENU_ADVSOUND, MENU_SOUND, MA_Return, Menu },
{ &M_SAVESETUP, MENU_SAVESETUP, MENU_OPTIONS, MA_Return, Menu },
{ &M_SAVECLEANVERIFY, MENU_SAVECLEANVERIFY, MENU_SAVESETUP, MA_None, Verify },
#ifdef EDUKE32_SIMPLE_MENU
{ &M_CHEATS, MENU_CHEATS, MENU_OPTIONS, MA_Return, Menu },
#else
{ &M_CHEATS, MENU_CHEATS, MENU_GAMESETUP, MA_Return, Menu },
#endif
{ &M_CHEATENTRY, MENU_CHEATENTRY, MENU_CHEATS, MA_None, TextForm },
{ &M_CHEAT_WARP, MENU_CHEAT_WARP, MENU_CHEATS, MA_None, TextForm },
{ &M_CHEAT_SKILL, MENU_CHEAT_SKILL, MENU_CHEATS, MA_None, TextForm },
{ &M_CREDITS, MENU_CREDITS, MENU_MAIN, MA_Return, Panel },
{ &M_CREDITS2, MENU_CREDITS2, MENU_MAIN, MA_Return, Panel },
{ &M_CREDITS3, MENU_CREDITS3, MENU_MAIN, MA_Return, Panel },
{ &M_CREDITS4, MENU_CREDITS4, MENU_MAIN, MA_Return, Panel },
{ &M_CREDITS5, MENU_CREDITS5, MENU_MAIN, MA_Return, Panel },
{ &M_LOADVERIFY, MENU_LOADVERIFY, MENU_LOAD, MA_None, Verify },
{ &M_LOADDELVERIFY, MENU_LOADDELVERIFY, MENU_LOAD, MA_None, Verify },
{ &M_NEWVERIFY, MENU_NEWVERIFY, MENU_PREVIOUS, MA_Return, Verify },
{ &M_SAVEVERIFY, MENU_SAVEVERIFY, MENU_SAVE, MA_None, Verify },
{ &M_SAVEDELVERIFY, MENU_SAVEDELVERIFY, MENU_SAVE, MA_None, Verify },
{ &M_COLCORRRESETVERIFY, MENU_COLCORRRESETVERIFY, MENU_COLCORR, MA_None, Verify },
{ &M_KEYSRESETVERIFY, MENU_KEYSRESETVERIFY, MENU_KEYBOARDSETUP, MA_None, Verify },
{ &M_KEYSCLASSICVERIFY, MENU_KEYSCLASSICVERIFY, MENU_KEYBOARDSETUP, MA_None, Verify },
{ &M_JOYSTANDARDVERIFY, MENU_JOYSTANDARDVERIFY, MENU_JOYSTICKSETUP, MA_None, Verify },
{ &M_JOYPROVERIFY, MENU_JOYPROVERIFY, MENU_JOYSTICKSETUP, MA_None, Verify },
{ &M_JOYCLEARVERIFY, MENU_JOYCLEARVERIFY, MENU_JOYSTICKSETUP, MA_None, Verify },
{ &M_ADULTPASSWORD, MENU_ADULTPASSWORD, MENU_GAMESETUP, MA_None, TextForm },
{ &M_RESETPLAYER, MENU_RESETPLAYER, MENU_CLOSE, MA_None, Verify },
{ &M_BUYDUKE, MENU_BUYDUKE, MENU_EPISODE, MA_Return, Message },
{ &M_NETWORK, MENU_NETWORK, MENU_MAIN, MA_Return, Menu },
{ &M_PLAYER, MENU_PLAYER, MENU_OPTIONS, MA_Return, Menu },
{ &M_MACROS, MENU_MACROS, MENU_PLAYER, MA_Return, Menu },
{ &M_NETHOST, MENU_NETHOST, MENU_NETWORK, MA_Return, Menu },
{ &M_NETOPTIONS, MENU_NETOPTIONS, MENU_NETWORK, MA_Return, Menu },
// { &M_USERMAP, MENU_NETUSERMAP, MENU_NETOPTIONS, MA_Return, FileSelect },
{ &M_NETJOIN, MENU_NETJOIN, MENU_NETWORK, MA_Return, Menu },
};
/* /*
This function prepares data after ART and CON have been processed. This function prepares data after ART and CON have been processed.
@ -1159,15 +496,6 @@ void Menu_Init(void)
// prepare sound setup
#ifndef EDUKE32_STANDALONE
if (WW2GI)
ME_SOUND_DUKETALK.name = "GI talk:";
else if (NAM)
ME_SOUND_DUKETALK.name = "Grunt talk:";
#endif
// prepare shareware // prepare shareware
if (VOLUMEONE) if (VOLUMEONE)
{ {
@ -1401,38 +729,6 @@ static void Menu_PreDraw(MenuID_t cm, MenuEntry_t *entry, const vec2_t origin)
rotatesprite_fs(origin.x + (200<<16), origin.y + (32<<16), 16384, 0, LOADSCREEN, 0, 0, 2|8|16); rotatesprite_fs(origin.x + (200<<16), origin.y + (32<<16), 16384, 0, LOADSCREEN, 0, 0, 2|8|16);
break; break;
case MENU_NETSETUP:
case MENU_NETHOST:
mminitext(origin.x + (90<<16), origin.y + (90<<16), "Game Type", MF_Minifont.pal_deselected);
mminitext(origin.x + (90<<16), origin.y + ((90+8)<<16), "Episode", MF_Minifont.pal_deselected);
mminitext(origin.x + (90<<16), origin.y + ((90+8+8)<<16), "Level", MF_Minifont.pal_deselected);
mminitext(origin.x + (90<<16), origin.y + ((90+8+8+8)<<16), ME_NETOPTIONS_MONSTERS.name, MF_Minifont.pal_deselected);
if (m_coop == 0)
mminitext(origin.x + (90<<16), origin.y + ((90+8+8+8+8)<<16), "Markers", MF_Minifont.pal_deselected);
else if (m_coop == 1)
mminitext(origin.x + (90<<16), origin.y + ((90+8+8+8+8)<<16), "Friendly Fire", MF_Minifont.pal_deselected);
mminitext(origin.x + (90<<16), origin.y + ((90+8+8+8+8+8)<<16), "User Map", MF_Minifont.pal_deselected);
mminitext(origin.x + ((90+60)<<16), origin.y + (90<<16), g_gametypeNames[m_coop], MF_Minifont.pal_deselected_right);
mminitext(origin.x + ((90+60)<<16), origin.y + ((90+8)<<16), gVolumeNames[ud.m_volume_number], MF_Minifont.pal_deselected_right);
mminitext(origin.x + ((90+60)<<16), origin.y + ((90+8+8)<<16), g_mapInfo[MAXLEVELS*ud.m_volume_number+m_level_number].name, MF_Minifont.pal_deselected_right);
if (ud.m_monsters_off == 0 || ud.m_player_skill > 0)
mminitext(origin.x + ((90+60)<<16), origin.y + ((90+8+8+8)<<16), g_skillNames[ud.m_player_skill], MF_Minifont.pal_deselected_right);
else mminitext(origin.x + ((90+60)<<16), origin.y + ((90+8+8+8)<<16), "None", MF_Minifont.pal_deselected_right);
if (m_coop == 0)
{
if (m_marker) mminitext(origin.x + ((90+60)<<16), origin.y + ((90+8+8+8+8)<<16), "On", MF_Minifont.pal_deselected_right);
else mminitext(origin.x + ((90+60)<<16), origin.y + ((90+8+8+8+8)<<16), "Off", MF_Minifont.pal_deselected_right);
}
else if (m_coop == 1)
{
if (m_ffire) mminitext(origin.x + ((90+60)<<16), origin.y + ((90+8+8+8+8)<<16), "On", MF_Minifont.pal_deselected_right);
else mminitext(origin.x + ((90+60)<<16), origin.y + ((90+8+8+8+8)<<16), "Off", MF_Minifont.pal_deselected_right);
}
break;
case MENU_SAVECLEANVERIFY: case MENU_SAVECLEANVERIFY:
videoFadeToBlack(1); videoFadeToBlack(1);

View file

@ -49,6 +49,12 @@ extern MenuFont_t MF_Redfont, MF_Bluefont, MF_Minifont;
void Menu_Init(void); void Menu_Init(void);
int G_CheckPlayerColor(int color)
{
static int32_t player_pals[] = { 0, 9, 10, 11, 12, 13, 14, 15, 16, 21, 23, };
if (color >= 0 && color < 10) return player_pals[color];
}
#if 0 #if 0
@ -466,7 +472,6 @@ extern int32_t voting;
int Menu_Change(MenuID_t cm); int Menu_Change(MenuID_t cm);
void Menu_AnimateChange(int32_t cm, MenuAnimationType_t animtype); void Menu_AnimateChange(int32_t cm, MenuAnimationType_t animtype);
int32_t Menu_IsTextInput(Menu_t *cm); int32_t Menu_IsTextInput(Menu_t *cm);
int G_CheckPlayerColor(int color);
void M_DisplayMenus(void); void M_DisplayMenus(void);
#define M_MOUSETIMEOUT 210 #define M_MOUSETIMEOUT 210

View file

@ -4802,7 +4802,7 @@ void Net_SendClientInfo(void)
tempnetbuf[l++] = g_player[myconnectindex].ps->aim_mode = in_aimmode; tempnetbuf[l++] = g_player[myconnectindex].ps->aim_mode = in_aimmode;
tempnetbuf[l++] = g_player[myconnectindex].ps->auto_aim = cl_autoaim; tempnetbuf[l++] = g_player[myconnectindex].ps->auto_aim = cl_autoaim;
tempnetbuf[l++] = g_player[myconnectindex].ps->weaponswitch = cl_weaponswitch; tempnetbuf[l++] = g_player[myconnectindex].ps->weaponswitch = cl_weaponswitch;
tempnetbuf[l++] = g_player[myconnectindex].ps->palookup = g_player[myconnectindex].pcolor = playercolor; tempnetbuf[l++] = g_player[myconnectindex].ps->palookup = g_player[myconnectindex].pcolor = G_CheckPlayerColor(playercolor);
tempnetbuf[l++] = g_player[myconnectindex].pteam = playerteam; tempnetbuf[l++] = g_player[myconnectindex].pteam = playerteam;

View file

@ -211,9 +211,6 @@ void G_SetupCheats(void)
Bstrcpy(CheatStrings[23], "<RESERVED>"); Bstrcpy(CheatStrings[23], "<RESERVED>");
Bstrcpy(CheatStrings[24], "adebug"); Bstrcpy(CheatStrings[24], "adebug");
Bstrcpy(CheatStrings[26], "acgs"); Bstrcpy(CheatStrings[26], "acgs");
Bstrcpy(g_gametypeNames[0], "GruntMatch (Spawn)");
Bstrcpy(g_gametypeNames[2], "GruntMatch (No Spawn)");
} }
} }

View file

@ -475,6 +475,17 @@ void GameInterface::DrawCenteredTextScreen(const DVector2 &origin, const char *t
} }
#if 0
void GameInterface::DrawPlayerSprite(int x, int y)
{
if (RR)
rotatesprite_fs(origin.x + (260<<16), origin.y + ((24+(tilesiz[APLAYER].y>>2))<<16), 24576L,0,3845+36-((((8-((int32_t) totalclock>>4)))&7)*5),0,entry == &ME_PLAYER_TEAM ? G_GetTeamPalette(playerteam) : playercolor,10);
else
rotatesprite_fs(origin.x + (260<<16), origin.y + ((24+(tilesiz[APLAYER].y>>1))<<16), 49152L,0,1441-((((4-((int32_t) totalclock>>4)))&3)*5),0,entry == &ME_PLAYER_TEAM ? G_GetTeamPalette(playerteam) : playercolor,10);
}
#endif
END_RR_NS END_RR_NS
//---------------------------------------------------------------------------- //----------------------------------------------------------------------------

View file

@ -7177,7 +7177,7 @@ void G_UpdatePlayerFromMenu(void)
/*int32_t j = g_player[myconnectindex].ps->team;*/ /*int32_t j = g_player[myconnectindex].ps->team;*/
P_SetupMiscInputSettings(); P_SetupMiscInputSettings();
g_player[myconnectindex].ps->palookup = g_player[myconnectindex].pcolor = playercolor; g_player[myconnectindex].ps->palookup = g_player[myconnectindex].pcolor = G_CheckPlayerColor(playercolor);
g_player[myconnectindex].pteam = playerteam; g_player[myconnectindex].pteam = playerteam;
@ -7588,7 +7588,7 @@ MAIN_LOOP_RESTART:
g_player[myconnectindex].ps->palookup = g_player[myconnectindex].pcolor = G_GetTeamPalette(g_player[myconnectindex].pteam); g_player[myconnectindex].ps->palookup = g_player[myconnectindex].pcolor = G_GetTeamPalette(g_player[myconnectindex].pteam);
else else
{ {
if (playercolor) g_player[myconnectindex].ps->palookup = g_player[myconnectindex].pcolor = playercolor; if (playercolor) g_player[myconnectindex].ps->palookup = g_player[myconnectindex].pcolor = G_CheckPlayerColor(playercolor);
else g_player[myconnectindex].ps->palookup = g_player[myconnectindex].pcolor; else g_player[myconnectindex].ps->palookup = g_player[myconnectindex].pcolor;
} }

View file

@ -48,6 +48,12 @@ typedef struct MenuFont_t
extern MenuFont_t MF_Redfont, MF_Bluefont, MF_Minifont; extern MenuFont_t MF_Redfont, MF_Bluefont, MF_Minifont;
void Menu_Init(void); void Menu_Init(void);
int G_CheckPlayerColor(int color)
{
static int32_t player_pals[] = { 0, 9, 10, 11, 12, 13, 14, 15, 16, 21, 23, };
if (color >= 0 && color < 10) return player_pals[color];
}
#if 0 #if 0
@ -489,7 +495,6 @@ extern int32_t voting;
int Menu_Change(MenuID_t cm); int Menu_Change(MenuID_t cm);
void Menu_AnimateChange(int32_t cm, MenuAnimationType_t animtype); void Menu_AnimateChange(int32_t cm, MenuAnimationType_t animtype);
int32_t Menu_IsTextInput(Menu_t *cm); int32_t Menu_IsTextInput(Menu_t *cm);
int G_CheckPlayerColor(int color);
void Menu_Init(void); void Menu_Init(void);
void Menu_Open(uint8_t playerID); void Menu_Open(uint8_t playerID);
void Menu_Close(uint8_t playerID); void Menu_Close(uint8_t playerID);

View file

@ -3430,7 +3430,7 @@ void Net_SendClientInfo(void)
tempbuf[l++] = g_player[myconnectindex].ps->aim_mode = in_aimmode; tempbuf[l++] = g_player[myconnectindex].ps->aim_mode = in_aimmode;
tempbuf[l++] = g_player[myconnectindex].ps->auto_aim = cl_autoaim; tempbuf[l++] = g_player[myconnectindex].ps->auto_aim = cl_autoaim;
tempbuf[l++] = g_player[myconnectindex].ps->weaponswitch = cl_weaponswitch; tempbuf[l++] = g_player[myconnectindex].ps->weaponswitch = cl_weaponswitch;
tempbuf[l++] = g_player[myconnectindex].ps->palookup = g_player[myconnectindex].pcolor = playercolor; tempbuf[l++] = g_player[myconnectindex].ps->palookup = g_player[myconnectindex].pcolor = G_CheckPlayerColor(playercolor);
tempbuf[l++] = g_player[myconnectindex].pteam = playerteam; tempbuf[l++] = g_player[myconnectindex].pteam = playerteam;

View file

@ -353,43 +353,6 @@ LISTMENU "CustomSubMenu7"
class "Duke.ListMenu" class "Duke.ListMenu"
} }
//-------------------------------------------------------------------------------------------
//
// No multiplayer support for now, but kept as a reminder.
//
//-------------------------------------------------------------------------------------------
LISTMENU "MultiMenu"
{
ifgame(Duke, Nam, WW2GI, Fury)
{
position 160, 55, 135
centermenu
fixedspacing 5
ifgame(Duke, Nam, WW2GI, Fury)
{
class "Duke.ListMenu"
}
else
{
class "Redneck.ListMenu"
}
animatedtransition
NativeTextItem "$MNU_PLAYERSETUP", "p", "PlayerSetupMenu"
}
ifgame(blood)
{
position 160, 80, 150
class "Blood.ListMenu"
centermenu
Linespacing 20
}
Caption "$MNU_NETWORKGAME"
NativeTextItem "$MNU_JOINGAME", "j", "JoinGameMenu"
NativeTextItem "$MNU_HOSTGAME", "h", "HostGameMenu"
}
//------------------------------------------------------------------------------------------- //-------------------------------------------------------------------------------------------
// //
// //
@ -997,5 +960,260 @@ OptionMenu "JoystickConfigMenu" //protected
} }
OptionValue "PlayerColors"
{
0, OPTVAL_AUTO"
1, "$TXT_COLOR_BLUE"
2, "TXT_COLOR_RED"
3, "TXT_COLOR_GREEN"
4, "TXT_COLOR_GRAY"
5, "TXT_COLOR_DARKGRAY"
6, "TXT_COLOR_DARKGREEN"
7, "TXT_COLOR_BROWN"
8, "TXT_COLOR_DARKBLUE"
9, "TXT_COLOR_LIGHTRED"
10, "TXT_COLOR_YELLOW"
}
OptionValue "PlayerTeam"
{
0, "$TXT_COLOR_BLUE"
1, "TXT_COLOR_RED"
2, "TXT_COLOR_GREEN"
3, "TXT_COLOR_GRAY"
}
OptionValue "Gender"
{
0, "$OPTVAL_MALE"
1, "$OPTVAL_FEMALE"
2, "$OPTVAL_NEUTRAL"
3, "$OPTVAL_OTHER"
}
OptionMenu "NewPlayerMenu" //protected
{
Title "$MNU_PLAYERSETUP"
TextField "$PLYRMNU_NAME", playername
Option "$PLYRMNU_TEAM", "playerteam", "PlayerTeam"
Option "$PLYRMNU_PLAYERCOLOR", "playercolor", "PlayerColors"
Option "$PLYRMNU_PLAYERGENDER", "playergender", "Gender""
Submenu "$PLRMNU_TAUNTS", "TauntsMenu"
Class "NewPlayerMenu"
}
OptionMenu "TauntsMenu" //protected
{
Title "$PLRMNU_TAUNTS"
TextField "1", "combatmacro0"
TextField "2", "combatmacro0"
TextField "3", "combatmacro0"
TextField "4", "combatmacro0"
TextField "5", "combatmacro0"
TextField "6", "combatmacro0"
TextField "7", "combatmacro0"
TextField "8", "combatmacro0"
TextField "9", "combatmacro0"
TextField "10", "combatmacro0"
}
//-------------------------------------------------------------------------------------------
//
// Game Setup
//
//-------------------------------------------------------------------------------------------
OptionValue "AimMode"
{
0, "$OPTVAL_NEVER"
1, "$OPTVAL_ALWAYS"
2, "$OPTRAL_HITSCAN"
}
OptionValue "RunMode"
{
0, "$PLRMNU_TOGGLE"
1, "$PLRMNU_OVERRIDE"
}
OptionValue "WeapSwitch"
{
0, "$OPTVAL_NEVER"
1, "$PLRMNU_IFNEW"
3, "$PLRMNU_PREFERRED"
}
OptionMenu GameplayOptions //protected
{
Position -35
Title "$GMPLYMNU_TITLE"
Option "$PLRMNU_AUTOAIM", "cl_autoaim", "AimMode"
Option "$PLRMNU_ALWAYSRUN", "cl_autorun", "OnOff"
Option "$PLRMNU_RUNMODE", "cl_runmode", "RunMode"
Option "$PLRMNU_EQUIP", "cl_weaponswitch", "WeapSwitch"
Option "$PLRMNU_PLOCK", "adult_lockout", "OnOff" // I won't bother password protecting this piece of window dressing
// StaticText ""
// Option "Record Demo", "m_recstat", "OnOff"
// Submenu "Cheats" "CheatsMenu
}
//-------------------------------------------------------------------------------------------
//
// Display options
//
//-------------------------------------------------------------------------------------------
OptionValue "FilterModes"
{
0, "$OPTVAL_NONE"
1, "$OPTVAL_NONENEARESTMIPMAP"
5, "$OPTVAL_NONELINEARMIPMAP"
6, "$OPTVAL_NONETRILINEAR"
2, "$OPTVAL_LINEAR_2"
3, "$OPTVAL_BILINEAR"
4, "$OPTVAL_TRILINEAR"
}
OptionValue "Anisotropy"
{
1, "$OPTVAL_OFF"
2, "$OPTVAL_2X"
4, "$OPTVAL_4X"
8, "$OPTVAL_8X"
16, "$OPTVAL_16X"
}
OptionMenu "VideoOptions" //protected
{
Title "$DSPLYMNU_TITLE"
Submenu "$OPTMNU_HUD", "HUDOptions"
Submenu "$OPTMNU_POLYMOST", "PolymostOptions"
Slider "$DSPLYMNU_GAMMA", "vid_gamma", 0.75, 3.0, 0.05, 2
Slider "$DSPLYMNU_BRIGHTNESS", "vid_brightness", -0.8,0.8, 0.05,2
Slider "$DSPLYMNU_CONTRAST", "vid_contrast", 0.1, 3.0, 0.1
Slider "$DSPLYMNU_SATURATION", "vid_saturation", -3.0, 3.0, 0.25, 2
StaticText ""
Option "$GLTEXMNU_TEXFILTER", hw_texfilter, "FilterModes"
Option "$GLTEXMNU_ANISOTROPIC", hw_anisotropy, "Anisotropy"
}
//-------------------------------------------------------------------------------------------
//
// HUD options
//
//-------------------------------------------------------------------------------------------
OptionValue "HUDMessages"
{
0, "$OPTVAL_OFF"
1, "$OPTVAL_ON"
2, "$DSPLYMNU_GENERIC"
}
OptionMenu "HUDOptions" //protected
{
Title "$OPTMNU_HUD"
Slider "$DSPLYMNU_SCREENSIZE", "hud_size", 3.0, 12.0, 1.0, 0
Slider "$DSPLYMNU_SBSCALE", "hud_scale", 0.3, 1.0, 0.1, 2
Option "$DSPLYMNU_LEVELSTATS", "hud_stats", "OnOff"
Slider "$DSPLYMNU_TEXTSCALE", "hud_textscale", 0.3, 1.0, 0.1, 2
StaticText ""
Option "$DSPLYMNU_MESSAGES", "hud_messages", "HudMessages"
StaticText ""
Option "$DSPLYMNU_CROSSHAIR", "cl_crosshair", OnOff
Slider "$DSPLYMNU_CROSSHAIRSCALE", "cl_crosshairscale", 50, 100, 10, 1
StaticText ""
Option "$DSPLYMNU_VOXELS", "r_voxels", "OnOff"
StaticText ""
Option "$DSPLYMNU_FOV", "r_fov", 60, 130, 10, 1
}
//-------------------------------------------------------------------------------------------
//
// No multiplayer support for now, but kept for documentation.
//
//-------------------------------------------------------------------------------------------
LISTMENU "MultiMenu"
{
ifgame(Duke, Nam, WW2GI, Fury)
{
position 160, 55, 135
centermenu
fixedspacing 5
ifgame(Duke, Nam, WW2GI, Fury)
{
class "Duke.ListMenu"
}
else
{
class "Redneck.ListMenu"
}
animatedtransition
NativeTextItem "$MNU_PLAYERSETUP", "p", "PlayerSetupMenu"
}
ifgame(blood)
{
position 160, 80, 150
class "Blood.ListMenu"
centermenu
Linespacing 20
}
ifgame(shadowwarrior)
{
position 160, 80, 150
class "ShadowWarrior.ListMenu"
centermenu
Linespacing 20
}
Caption "$MNU_NETWORKGAME"
NativeTextItem "$MNU_JOINGAME", "j", "JoinGameMenu"
NativeTextItem "$MNU_HOSTGAME", "h", "HostGameMenu"
}
OptionMenu "HostGameMenu"
{
title "$MNU_HOSTGAME"
Submenu "$NETMNU_OPTIONS", "MultiOptionsMenu"
Command "$NETMNU_LAUNCH", "Launch_MP" // currently a no-op
}
OptionMenu "JoinGameMenu"
{
TextField "$NETMNU_SERVER", "m_server"
TextField "$NETMNU_PORT", "m_netport"
SaveCommand "$NETMNU_CONNECT", "MultiConnect"
}
OptionValue "MultiGameType"
{
0, "$NETMNU_GAMETYPE1"
1, "$NETMNU_GAMETYPE2"
2, "$NETMNU_GAMETYPE3"
3, "$NETMNU_GAMETYPE4"
4, "$NETMNU_GAMETYPE5"
}
OptionMenu "MultiOptionsMenu"
{
title "$NETMNU_OPTIONS"
Option "$NETMNU_GAMETYPE", "m_coop"
Option "$NETMNU_EPISODE", "m_episode_number"
Option "$NETMNU_LEVEL", "m_level_number"
Submenu "$MNU_USERMAP", "MultiUserMap" // todo: fileselect item
Option "$NETMNU_MONSTERS", "m_monsters"
Option "$NETMNU_MARKERS", "m_marker"
Option "$NETMNU_MAPEXITS", "m_noexit"
Option "$NETMNU_FFIRE", "m_ffire"
SafeCommand "$NETMNU_ACCEPT", "MultiAccept"
}