Merge branch 'more-gameplay-option-restrictions' into 'master'

More gameplay option restrictions

See merge request KartKrew/Kart!2269
This commit is contained in:
Oni 2024-04-12 03:40:29 +00:00
commit 81644692d0
5 changed files with 2 additions and 13 deletions

View file

@ -7282,13 +7282,6 @@ void KartEncore_OnChange(void)
void KartEliminateLast_OnChange(void);
void KartEliminateLast_OnChange(void)
{
#ifndef DEVELOP
if (K_CanChangeRules(false) == false)
{
CV_StealthSet(&cv_karteliminatelast, cv_karteliminatelast.defaultvalue);
}
#endif
P_CheckRacers();
}

View file

@ -60,7 +60,7 @@ INT32 K_StartingBumperCount(void)
if (tutorialchallenge == TUTORIALSKIP_INPROGRESS)
return 0;
if (battleprisons || K_CheckBossIntro())
if (battleprisons || K_CheckBossIntro() || !K_CanChangeRules(true))
{
if (grandprixinfo.gp)
{

View file

@ -478,7 +478,6 @@ typedef enum
{
gopt_spacer0 = 0,
gopt_gamespeed,
gopt_baselapcount,
gopt_frantic,
gopt_encore,
gopt_exitcountdown,

View file

@ -21,9 +21,6 @@ menuitem_t OPTIONS_Gameplay[] =
{IT_STRING | IT_CVAR, "Game Speed", "Gear for the next map.",
NULL, {.cvar = &cv_kartspeed}, 0, 0},
{IT_STRING | IT_CVAR, "Base Lap Count", "How many laps must be completed per race.",
NULL, {.cvar = &cv_numlaps}, 0, 0},
{IT_STRING | IT_CVAR, "Frantic Items", "Make item odds crazier with more powerful items!",
NULL, {.cvar = &cv_kartfrantic}, 0, 0},

View file

@ -1525,7 +1525,7 @@ boolean P_CheckRacers(void)
{
const boolean griefed = (spectateGriefed > 0);
boolean eliminateLast = cv_karteliminatelast.value;
boolean eliminateLast = (!K_CanChangeRules(true) || (cv_karteliminatelast.value != 0));
boolean allHumansDone = true;
//boolean allBotsDone = true;