Merge branch 'auto-roulette-warning' into 'master'

Auto Roulette Warning

See merge request KartKrew/Kart!2358
This commit is contained in:
James R. 2024-05-04 04:56:27 +00:00
commit f300623e55
3 changed files with 32 additions and 1 deletions

View file

@ -210,6 +210,27 @@ static void M_ChangeCvar(INT32 choice)
}
#endif
if (cvar == &cv_dummyprofileautoroulette &&
// Turning Auto Roulette on
cv_dummyprofileautoroulette.value == 0 &&
// Not setting to default (ie changing the value)
choice != -1)
{
M_StartMessage(
"Turning on Auto Roulette",
"\"Ring Racers\" is not designed with random items in mind. With Auto Roulette, you cannot select the item results you want or select an item early."
"\n"
"You will be at a distinct \x85" "disadvantage. \x80\n"
"\n"
"ARE YOU SURE?",
M_ChangeCvarResponse,
MM_YESNO,
NULL,
NULL
);
return;
}
M_ChangeCvarDirect(choice, cvar);
}

View file

@ -518,6 +518,15 @@ void PR_LoadProfiles(void)
converted = true;
}
if (jsprof.version < 3)
{
// Version 2 -> 3:
// - Auto Roulette is turned off again so people have to see the warning message
newprof->autoroulette = false;
converted = true;
}
if (converted)
{
CONS_Printf("Profile '%s' was converted from version %d to version %d\n",

View file

@ -112,8 +112,9 @@ extern "C" {
// Version history:
// 1 - first
// 2 - litesteer is off by default, old profiles litesteer
// 3 - auto roulette is switched off again
// option is reset to default
#define PROFILEVER 2
#define PROFILEVER 3
#define MAXPROFILES 16
#define PROFILESFILE "ringprofiles.prf"
#define PROFILE_GUEST 0