From 3b595b00554a43676944f970e42a7683d4dc5c8d Mon Sep 17 00:00:00 2001 From: toaster Date: Fri, 21 Apr 2023 17:51:30 +0100 Subject: [PATCH 1/3] Replace TOL_BOSS with TOL_VERSUS Matches gametype name --- src/doomstat.h | 4 ++-- src/g_game.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/doomstat.h b/src/doomstat.h index 72a3a8c71..4c733b38f 100644 --- a/src/doomstat.h +++ b/src/doomstat.h @@ -581,8 +581,8 @@ enum TypeOfLevel // Gametypes TOL_RACE = 0x0001, ///< Race TOL_BATTLE = 0x0002, ///< Battle - TOL_BOSS = 0x0004, ///< Boss (variant of battle, but forbidden) - TOL_SPECIAL = 0x0008, ///< Special Stage (variant of race, but forbidden) + TOL_SPECIAL = 0x0004, ///< Special Stage (variant of race, but forbidden) + TOL_VERSUS = 0x0008, ///< Versus (variant of battle, but forbidden) TOL_TUTORIAL = 0x0010, ///< Tutorial (variant of race, but forbidden) // Modifiers diff --git a/src/g_game.c b/src/g_game.c index 5791fc7db..71ad164eb 100644 --- a/src/g_game.c +++ b/src/g_game.c @@ -3388,7 +3388,7 @@ static gametype_t defaultgametypes[] = "Versus", "GT_VERSUS", GTR_BOSS|GTR_SPHERES|GTR_BUMPERS|GTR_POINTLIMIT|GTR_CLOSERPLAYERS|GTR_NOCUPSELECT|GTR_ENCORE, - TOL_BOSS, + TOL_VERSUS, int_scoreortimeattack, 0, 0, @@ -3546,8 +3546,8 @@ char *G_PrepareGametypeConstant(const char *newgtconst) tolinfo_t TYPEOFLEVEL[NUMTOLNAMES] = { {"RACE",TOL_RACE}, {"BATTLE",TOL_BATTLE}, - {"BOSS",TOL_BOSS}, {"SPECIAL",TOL_SPECIAL}, + {"VERSUS",TOL_VERSUS}, {"TUTORIAL",TOL_TUTORIAL}, {"TV",TOL_TV}, {NULL, 0} From fdd5ee8dfc5f66c552b0f5d521c11b4fbdde0b82 Mon Sep 17 00:00:00 2001 From: toaster Date: Fri, 21 Apr 2023 18:15:14 +0100 Subject: [PATCH 2/3] K_KArtItemReelBoss: Adjust significantly - Have two loop arounds with varying quantities of orbinauts between gachaboms - Removes all bananas - Makes mashing for an item never give you something which can't attack a stationary target - Prevents complete autopilot timing --- src/k_roulette.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/k_roulette.c b/src/k_roulette.c index 89d265b68..505c85221 100644 --- a/src/k_roulette.c +++ b/src/k_roulette.c @@ -205,11 +205,15 @@ static kartitems_t K_KartItemReelBreakTheCapsules[] = static kartitems_t K_KartItemReelBoss[] = { - KITEM_ORBINAUT, - KITEM_BANANA, - KITEM_ORBINAUT, - KITEM_BANANA, KITEM_GACHABOM, + KITEM_ORBINAUT, + KITEM_ORBINAUT, + KITEM_ORBINAUT, + KITEM_ORBINAUT, + KITEM_GACHABOM, + KITEM_ORBINAUT, + KITEM_ORBINAUT, + KITEM_ORBINAUT, KITEM_NONE }; From 5c60a0958f2e763dfde912897f66d0f8346323f4 Mon Sep 17 00:00:00 2001 From: toaster Date: Sat, 22 Apr 2023 00:35:11 +0100 Subject: [PATCH 3/3] Versus roulette: Speed up based on boss healthbar (destination) fill % --- src/k_roulette.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/k_roulette.c b/src/k_roulette.c index 505c85221..4efa164a4 100644 --- a/src/k_roulette.c +++ b/src/k_roulette.c @@ -73,6 +73,7 @@ #define ROULETTE_SPEED_FASTEST (2) #define ROULETTE_SPEED_DIST (150*DISTVAR) #define ROULETTE_SPEED_TIMEATTACK (9) +#define ROULETTE_SPEED_VERSUS_SLOWEST (12) static UINT8 K_KartItemOddsRace[NUMKARTRESULTS-1][8] = { @@ -1135,6 +1136,14 @@ static void K_CalculateRouletteSpeed(itemroulette_t *const roulette) fixed_t progress = 0; fixed_t total = 0; + if (bossinfo.valid == true) + { + // Boss in action, use a speed controlled by boss health + total = FixedDiv(bossinfo.healthbar, BOSSHEALTHBARLEN); + roulette->tics = roulette->speed = ROULETTE_SPEED_FASTEST + FixedMul(ROULETTE_SPEED_VERSUS_SLOWEST - ROULETTE_SPEED_FASTEST, total); + return; + } + if (K_TimeAttackRules() == true) { // Time Attack rules; use a consistent speed.