mirror of
https://git.do.srb2.org/KartKrew/Kart-Public.git
synced 2024-12-26 20:31:30 +00:00
Instead of reverting kartspeed on invalid set, prevent it from being set in the first place, just like Encore! Should resolve desync.
This commit is contained in:
parent
8c91b3650f
commit
cb5da4c3c3
2 changed files with 9 additions and 7 deletions
|
@ -1533,6 +1533,15 @@ static void CV_SetCVar(consvar_t *var, const char *value, boolean stealth)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (var == &cv_kartspeed && !M_SecretUnlocked(SECRET_HARDSPEED))
|
||||||
|
{
|
||||||
|
if (!stricmp(value, "Hard") || atoi(value) == 2)
|
||||||
|
{
|
||||||
|
CONS_Printf(M_GetText("You haven't unlocked this yet!\n"));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Only add to netcmd buffer if in a netgame, otherwise, just change it.
|
// Only add to netcmd buffer if in a netgame, otherwise, just change it.
|
||||||
if (netgame || multiplayer)
|
if (netgame || multiplayer)
|
||||||
{
|
{
|
||||||
|
|
|
@ -5728,13 +5728,6 @@ static void KartFrantic_OnChange(void)
|
||||||
|
|
||||||
static void KartSpeed_OnChange(void)
|
static void KartSpeed_OnChange(void)
|
||||||
{
|
{
|
||||||
if (!M_SecretUnlocked(SECRET_HARDSPEED) && cv_kartspeed.value == 2)
|
|
||||||
{
|
|
||||||
CONS_Printf(M_GetText("You haven't earned this yet.\n"));
|
|
||||||
CV_StealthSetValue(&cv_kartspeed, 1);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (G_RaceGametype())
|
if (G_RaceGametype())
|
||||||
{
|
{
|
||||||
if ((UINT8)cv_kartspeed.value != gamespeed && gamestate == GS_LEVEL && leveltime > starttime)
|
if ((UINT8)cv_kartspeed.value != gamespeed && gamestate == GS_LEVEL && leveltime > starttime)
|
||||||
|
|
Loading…
Reference in a new issue