Skip to content

Commit

Permalink
OoS: Improved cosmetic random determinism by adding the player ID to …
Browse files Browse the repository at this point in the history
…the seed
  • Loading branch information
Dinopony committed Jul 21, 2024
1 parent 5918a2c commit f9aca46
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions worlds/tloz_oos/patching/ProcedurePatch.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,9 @@ def apply_patches(caller: APProcedurePatch, rom: bytes, patch_file: str) -> byte
apply_miscellaneous_options(rom_data, patch_data)
set_fixed_subrosia_seaside_location(rom_data, patch_data)

# Initialize random seed with the one used for generation, so that cosmetic stuff set to "random" always
# generate the same for successive patchings
random.seed(patch_data["seed"])
# Initialize random seed with the one used for generation + the player ID, so that cosmetic stuff set
# to "random" always generate the same for successive patchings for a given slot
random.seed(patch_data["seed"] + caller.player)
# Apply cosmetic settings
set_heart_beep_interval_from_settings(rom_data)
set_character_sprite_from_settings(rom_data)
Expand Down

0 comments on commit f9aca46

Please sign in to comment.