YGO06: make sure it runs on 3.8 support (#3324)
* YGO06: make sure it runs on python 3.8 * YGO06: change merge of dict, so it runs on python 3.8
This commit is contained in:
parent
5e3c5dedf3
commit
2bc345504e
|
@ -193,7 +193,7 @@ class Yugioh06World(World):
|
||||||
self.multiworld.push_precollected(self.create_item(Banlist_Items[banlist]))
|
self.multiworld.push_precollected(self.create_item(Banlist_Items[banlist]))
|
||||||
|
|
||||||
if not self.removed_challenges:
|
if not self.removed_challenges:
|
||||||
challenge = list((Limited_Duels | Theme_Duels).keys())
|
challenge = list(({**Limited_Duels, **Theme_Duels}).keys())
|
||||||
noc = len(challenge) - max(
|
noc = len(challenge) - max(
|
||||||
self.options.third_tier_5_campaign_boss_challenges.value
|
self.options.third_tier_5_campaign_boss_challenges.value
|
||||||
if self.options.third_tier_5_campaign_boss_unlock_condition == "challenges"
|
if self.options.third_tier_5_campaign_boss_unlock_condition == "challenges"
|
||||||
|
@ -238,9 +238,9 @@ class Yugioh06World(World):
|
||||||
structure_deck = self.options.structure_deck.current_key
|
structure_deck = self.options.structure_deck.current_key
|
||||||
self.multiworld.regions += [
|
self.multiworld.regions += [
|
||||||
self.create_region("Menu", None, ["to Deck Edit", "to Campaign", "to Challenges", "to Card Shop"]),
|
self.create_region("Menu", None, ["to Deck Edit", "to Campaign", "to Challenges", "to Card Shop"]),
|
||||||
self.create_region("Campaign", Bonuses | Campaign_Opponents),
|
self.create_region("Campaign", {**Bonuses, **Campaign_Opponents}),
|
||||||
self.create_region("Challenges"),
|
self.create_region("Challenges"),
|
||||||
self.create_region("Card Shop", Required_Cards | collection_events),
|
self.create_region("Card Shop", {**Required_Cards, **collection_events}),
|
||||||
self.create_region("Structure Deck", get_deck_content_locations(structure_deck)),
|
self.create_region("Structure Deck", get_deck_content_locations(structure_deck)),
|
||||||
]
|
]
|
||||||
|
|
||||||
|
@ -308,7 +308,7 @@ class Yugioh06World(World):
|
||||||
|
|
||||||
challenge_region = self.get_region("Challenges")
|
challenge_region = self.get_region("Challenges")
|
||||||
# Challenges
|
# Challenges
|
||||||
for challenge, lid in (Limited_Duels | Theme_Duels).items():
|
for challenge, lid in ({**Limited_Duels, **Theme_Duels}).items():
|
||||||
if challenge in self.removed_challenges:
|
if challenge in self.removed_challenges:
|
||||||
continue
|
continue
|
||||||
region = self.create_region(challenge, {challenge: lid, challenge + " Complete": None})
|
region = self.create_region(challenge, {challenge: lid, challenge + " Complete": None})
|
||||||
|
|
|
@ -1,4 +1,6 @@
|
||||||
structure_contents: dict[str, set] = {
|
from typing import Dict, Set
|
||||||
|
|
||||||
|
structure_contents: Dict[str, Set] = {
|
||||||
"dragons_roar": {
|
"dragons_roar": {
|
||||||
"Luster Dragon",
|
"Luster Dragon",
|
||||||
"Armed Dragon LV3",
|
"Armed Dragon LV3",
|
||||||
|
@ -77,5 +79,5 @@ structure_contents: dict[str, set] = {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
def get_deck_content_locations(deck: str) -> dict[str, str]:
|
def get_deck_content_locations(deck: str) -> Dict[str, str]:
|
||||||
return {f"{deck} {i}": content for i, content in enumerate(structure_contents[deck])}
|
return {f"{deck} {i}": content for i, content in enumerate(structure_contents[deck])}
|
||||||
|
|
Loading…
Reference in New Issue