StS: Update location table and move item creation to `create_items` from `generate_basic`. ()

This commit is contained in:
KonoTyran 2023-07-21 22:51:13 -07:00 committed by GitHub
parent 86a55c7837
commit 9b1de8fea8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 6 additions and 13 deletions

View File

@ -26,9 +26,9 @@ item_table: Dict[str, ItemData] = {
item_pool: Dict[str, int] = {
'Card Draw': 15,
'Rare Card Draw': 3,
'Rare Card Draw': 2,
'Relic': 10,
'Boss Relic': 3
'Boss Relic': 2
}
event_item_pairs: Dict[str, str] = {

View File

@ -16,7 +16,6 @@ location_table = {
'Card Draw 15': 19015,
'Rare Card Draw 1': 21001,
'Rare Card Draw 2': 21002,
'Rare Card Draw 3': 21003,
'Relic 1': 20001,
'Relic 2': 20002,
'Relic 3': 20003,
@ -29,7 +28,6 @@ location_table = {
'Relic 10': 20010,
'Boss Relic 1': 22001,
'Boss Relic 2': 22002,
'Boss Relic 3': 22003,
'Heart Room': None,
'Act 1 Boss': None,
'Act 2 Boss': None,

View File

@ -69,8 +69,6 @@ def set_rules(world: MultiWorld, player: int):
# Act 3 Boss Event
set_rule(world.get_location("Act 3 Boss", player), lambda state: state.has("Beat Act 2 Boss", player) and state._spire_has_relics(player, 7) and state.has("Boss Relic", player, 2))
# Act 3 Boss Rewards
set_rule(world.get_location("Rare Card Draw 3", player), lambda state: state.has("Beat Act 3 Boss", player))
set_rule(world.get_location("Boss Relic 3", player), lambda state: state.has("Beat Act 3 Boss", player))
set_rule(world.get_location("Heart Room", player), lambda state: state.has("Beat Act 3 Boss", player))
world.completion_condition[player] = lambda state: state.has("Victory", player)

View File

@ -30,14 +30,14 @@ class SpireWorld(World):
option_definitions = spire_options
game = "Slay the Spire"
topology_present = False
data_version = 1
data_version = 2
web = SpireWeb()
required_client_version = (0, 3, 7)
item_name_to_id = {name: data.code for name, data in item_table.items()}
location_name_to_id = location_table
def generate_basic(self):
def create_items(self):
# Fill out our pool with our items from item_pool, assuming 1 item if not present in item_pool
pool = []
for name, data in item_table.items():
@ -53,9 +53,6 @@ class SpireWorld(World):
event_item = SpireItem(item, self.player)
self.multiworld.get_location(event, self.player).place_locked_item(event_item)
if self.multiworld.logic[self.player] != 'no logic':
self.multiworld.completion_condition[self.player] = lambda state: state.has("Victory", self.player)
def set_rules(self):
set_rules(self.multiworld, self.player)