Ruh Roh Raggy, more r-r-r-random bugs!

This commit is contained in:
CookieCat
2023-08-30 00:20:37 -04:00
parent a3fd86539d
commit 949f152ec2
3 changed files with 21 additions and 8 deletions

View File

@@ -646,6 +646,7 @@ tihs_locations = [
]
event_locs = {
"HUMT Access": LocData(0, "Heating Up Mafia Town", act_complete_event=False),
"Birdhouse Cleared": LocData(0, "The Birdhouse"),
"Lava Cake Cleared": LocData(0, "The Lava Cake"),
"Windmill Cleared": LocData(0, "The Windmill"),

View File

@@ -474,16 +474,30 @@ def randomize_act_entrances(world: World):
if world.multiworld.VanillaAlpine[world.player].value > 0 and region.name == "Alpine Free Roam" \
or world.multiworld.VanillaAlpine[world.player].value == 2 and region.name == "The Illness has Spread":
candidate_list.clear()
candidate_list.append(region)
break
if world.multiworld.VanillaAlpine[world.player].value > 0 and candidate.name == "Alpine Free Roam" \
or world.multiworld.VanillaAlpine[world.player].value == 2 and candidate.name == "The Illness has Spread":
continue
if world.multiworld.VanillaMetro[world.player].value > 0 and region.name == "Nyakuza Free Roam":
candidate_list.clear()
candidate_list.append(region)
break
if world.multiworld.VanillaMetro[world.player].value > 0 and candidate.name == "Nyakuza Free Roam":
continue
if candidate.name == "Rush Hour" and world.multiworld.EndGoal[world.player].value == 2 or \
world.multiworld.VanillaMetro[world.player].value == 2:
continue
if region.name == "Rush Hour":
if world.multiworld.EndGoal[world.player].value == 2 or \
world.multiworld.VanillaMetro[world.player].value == 2:
candidate_list.clear()
candidate_list.append(region)
break

View File

@@ -32,7 +32,7 @@ act_connections = {
def can_use_hat(state: CollectionState, world: World, hat: HatType) -> bool:
return state.has("Yarn", world.player, get_hat_cost(world, hat))
return state.count("Yarn", world.player) >= get_hat_cost(world, hat)
def get_hat_cost(world: World, hat: HatType) -> int:
@@ -387,14 +387,12 @@ def set_specific_rules(world: World):
or state.can_reach("The Golden Vault", "Region", world.player))
# For some reason, the brewing crate is removed in HUMT
set_rule(world.multiworld.get_location("Mafia Town - Secret Cave", world.player),
lambda state: state.can_reach("Heating Up Mafia Town", "Region", world.player)
or can_use_hat(state, world, HatType.BREWING))
add_rule(world.multiworld.get_location("Mafia Town - Secret Cave", world.player),
lambda state: state.has("HUMT Access", world.player), "or")
# Can bounce across the lava to get this without Hookshot (need to die though :world.player)
set_rule(world.multiworld.get_location("Mafia Town - Above Boats", world.player),
lambda state: state.can_reach("Heating Up Mafia Town", "Region", world.player)
or can_use_hookshot(state, world))
# Can bounce across the lava to get this without Hookshot (need to die though)
add_rule(world.multiworld.get_location("Mafia Town - Above Boats", world.player),
lambda state: state.has("HUMT Access", world.player), "or")
set_rule(world.multiworld.get_location("Act Completion (Cheating the Race)", world.player),
lambda state: can_use_hat(state, world, HatType.TIME_STOP)