mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
Don't allow auto-roulette to get challenging items
This commit is contained in:
parent
715cbd5590
commit
e01234285b
1 changed files with 20 additions and 0 deletions
|
|
@ -565,6 +565,18 @@ static boolean K_DenyShieldOdds(kartitems_t item)
|
|||
return false;
|
||||
}
|
||||
|
||||
static boolean K_DenyAutoRouletteOdds(kartitems_t item)
|
||||
{
|
||||
// Deny items that are too hard for newbies
|
||||
switch (item)
|
||||
{
|
||||
case KITEM_GARDENTOP:
|
||||
return true;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/*--------------------------------------------------
|
||||
static fixed_t K_AdjustSPBOdds(const itemroulette_t *roulette, UINT8 position)
|
||||
|
||||
|
|
@ -738,6 +750,14 @@ INT32 K_KartGetItemOdds(const player_t *player, itemroulette_t *const roulette,
|
|||
return 0;
|
||||
}
|
||||
|
||||
if (roulette->autoroulette == true)
|
||||
{
|
||||
if (K_DenyAutoRouletteOdds(item))
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
if (gametype == GT_BATTLE)
|
||||
{
|
||||
I_Assert(pos < 2); // DO NOT allow positions past the bounds of the table
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue