mirror of
https://github.com/MarioSpore/Grinch-AP.git
synced 2025-10-21 20:21:32 -06:00
add seed_name to multidata and RoomInfo
This commit is contained in:
@@ -27,7 +27,7 @@ base_info = {
|
||||
"factorio_version": "1.1"
|
||||
}
|
||||
|
||||
def generate_mod(world: MultiWorld, player: int):
|
||||
def generate_mod(world: MultiWorld, player: int, seedname: str):
|
||||
global template, locale_template
|
||||
with template_load_lock:
|
||||
if not template:
|
||||
@@ -41,7 +41,7 @@ def generate_mod(world: MultiWorld, player: int):
|
||||
for location in world.get_filled_locations(player):
|
||||
if not location.name.startswith("recipe-"): # introduce this as a new location property?
|
||||
locations.append((location.name, location.item.name, location.item.player))
|
||||
mod_name = f"archipelago-client-{world.seed}-{player}"
|
||||
mod_name = f"archipelago-client-{seedname}-{player}"
|
||||
tech_cost = {0: 0.1,
|
||||
1: 0.25,
|
||||
2: 0.5,
|
||||
|
||||
@@ -76,9 +76,6 @@ def get_shapes(world: MultiWorld, player: int) -> Dict[str, List[str]]:
|
||||
# https://www.wolframalpha.com/input/?i=x+=+1/2+(n++++1)+(2++++n)+solve+for+n
|
||||
import math
|
||||
slice_size = int(0.5*(math.sqrt(8*len(tech_names)+1)-3))
|
||||
|
||||
import logging
|
||||
logging.info(slice_size)
|
||||
tech_names.sort()
|
||||
world.random.shuffle(tech_names)
|
||||
tech_names.sort(key=lambda tech_name: len(technology_table[tech_name].ingredients))
|
||||
|
||||
Reference in New Issue
Block a user