mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-05-05 00:12:16 +00:00
P_IsPickupCheesy: add debugcheese cvar
This commit is contained in:
parent
9ba5a93407
commit
a6f8f53312
2 changed files with 8 additions and 0 deletions
|
|
@ -773,6 +773,7 @@ extern CV_PossibleValue_t capsuletest_cons_t[];
|
||||||
void CapsuleTest_OnChange(void);
|
void CapsuleTest_OnChange(void);
|
||||||
consvar_t cv_capsuletest = OnlineCheat("capsuletest", "Off").values(capsuletest_cons_t).onchange(CapsuleTest_OnChange).description("Force item capsule spawning rules");
|
consvar_t cv_capsuletest = OnlineCheat("capsuletest", "Off").values(capsuletest_cons_t).onchange(CapsuleTest_OnChange).description("Force item capsule spawning rules");
|
||||||
|
|
||||||
|
consvar_t cv_debugcheese = OnlineCheat("debugcheese", "Off").on_off().description("Disable checks that prevent farming item boxes");
|
||||||
consvar_t cv_debugencorevote = OnlineCheat("debugencorevote", "Off").on_off().description("Force encore choice to appear on vote screen");
|
consvar_t cv_debugencorevote = OnlineCheat("debugencorevote", "Off").on_off().description("Force encore choice to appear on vote screen");
|
||||||
|
|
||||||
void ForceSkin_OnChange(void);
|
void ForceSkin_OnChange(void);
|
||||||
|
|
|
||||||
|
|
@ -165,6 +165,13 @@ boolean P_CanPickupItem(player_t *player, UINT8 weapon)
|
||||||
// 1 = floating item, 2 = perma ring, 3 = capsule
|
// 1 = floating item, 2 = perma ring, 3 = capsule
|
||||||
boolean P_IsPickupCheesy(player_t *player, UINT8 type)
|
boolean P_IsPickupCheesy(player_t *player, UINT8 type)
|
||||||
{
|
{
|
||||||
|
extern consvar_t cv_debugcheese;
|
||||||
|
|
||||||
|
if (cv_debugcheese.value)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
if (player->lastpickupdistance && player->lastpickuptype == type)
|
if (player->lastpickupdistance && player->lastpickuptype == type)
|
||||||
{
|
{
|
||||||
UINT32 distancedelta = min(player->distancetofinish - player->lastpickupdistance, player->lastpickupdistance - player->distancetofinish);
|
UINT32 distancedelta = min(player->distancetofinish - player->lastpickupdistance, player->lastpickupdistance - player->distancetofinish);
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue