Core: provide a way to add to CollectionState init and copy

SM: use that way
OoT: use that way
This commit is contained in:
Fabian Dill
2022-02-17 07:07:34 +01:00
parent c525c80b49
commit daea0f3e5e
8 changed files with 125 additions and 153 deletions

View File

@@ -1,6 +1,6 @@
from argparse import Namespace
from BaseClasses import MultiWorld
from BaseClasses import MultiWorld, CollectionState
from worlds.AutoWorld import call_all
gen_steps = ["generate_early", "create_regions", "create_items", "set_rules", "generate_basic", "pre_fill"]
@@ -18,4 +18,4 @@ def setup_default_world(world_type):
world.set_default_common_options()
for step in gen_steps:
call_all(world, step)
return world
return world

View File

@@ -1,10 +0,0 @@
from test.hollow_knight import TestVanilla
class TestBasic(TestVanilla):
def testSimple(self):
self.run_location_tests([
["200_Geo-False_Knight_Chest", True, [], []],
["380_Geo-Soul_Master_Chest", False, [], ["Mantis_Claw"]],
])

View File

@@ -1,20 +0,0 @@
from worlds.hk import HKWorld
from BaseClasses import MultiWorld
from worlds import AutoWorld
from worlds.hk.Options import hollow_knight_randomize_options, hollow_knight_skip_options
from test.TestBase import TestBase
class TestVanilla(TestBase):
def setUp(self):
self.world = MultiWorld(1)
self.world.game[1] = "Hollow Knight"
self.world.worlds[1] = HKWorld(self.world, 1)
for hk_option in hollow_knight_randomize_options:
setattr(self.world, hk_option, {1: True})
for hk_option, option in hollow_knight_skip_options.items():
setattr(self.world, hk_option, {1: option.default})
AutoWorld.call_single(self.world, "create_regions", 1)
AutoWorld.call_single(self.world, "generate_basic", 1)
AutoWorld.call_single(self.world, "set_rules", 1)