Overcooked 2: Revert OC2Level world references to be named correctly, optimize location scouting. (#1175)
* fix oc2 level world references * optimize the local items discovery a bit
This commit is contained in:
@@ -376,17 +376,14 @@ class Overcooked2World(World):
|
||||
|
||||
# Place Items at Level Completion Screens (local only)
|
||||
on_level_completed: Dict[str, list[Dict[str, str]]] = dict()
|
||||
regions = self.multiworld.get_regions(self.player)
|
||||
for region in regions:
|
||||
for location in region.locations:
|
||||
if location.item is None:
|
||||
continue
|
||||
if location.item.code is None:
|
||||
continue # it's an event
|
||||
if location.item.player != self.player:
|
||||
continue # not for us
|
||||
level_id = str(oc2_location_name_to_id[location.name])
|
||||
on_level_completed[level_id] = [item_to_unlock_event(location.item.name)]
|
||||
locations = self.multiworld.get_filled_locations(self.player)
|
||||
for location in locations:
|
||||
if location.item.code is None:
|
||||
continue # it's an event
|
||||
if location.item.player != self.player:
|
||||
continue # not for us
|
||||
level_id = str(oc2_location_name_to_id[location.name])
|
||||
on_level_completed[level_id] = [item_to_unlock_event(location.item.name)]
|
||||
|
||||
# Put it all together
|
||||
star_threshold_scale = self.options["StarThresholdScale"] / 100
|
||||
|
||||
Reference in New Issue
Block a user