mirror of
https://github.com/MarioSpore/Grinch-AP.git
synced 2025-10-21 12:11:33 -06:00
Core: Attribute per slot random directly to the World and discourage using MultiWorld's random (#1649)
* add a random object to the World * use it in The Messenger * the worlds don't exist until the end of set options * set seed in lttp tests * use world.random for shop shuffle
This commit is contained in:
@@ -81,6 +81,7 @@ class MultiWorld():
|
||||
|
||||
random: random.Random
|
||||
per_slot_randoms: Dict[int, random.Random]
|
||||
"""Deprecated. Please use `self.random` instead."""
|
||||
|
||||
class AttributeProxy():
|
||||
def __init__(self, rule):
|
||||
@@ -242,6 +243,7 @@ class MultiWorld():
|
||||
setattr(self, option_key, getattr(args, option_key, {}))
|
||||
|
||||
self.worlds[player] = world_type(self, player)
|
||||
self.worlds[player].random = self.per_slot_randoms[player]
|
||||
|
||||
def set_item_links(self):
|
||||
item_links = {}
|
||||
|
Reference in New Issue
Block a user