mirror of
https://github.com/ArchipelagoMW/Archipelago.git
synced 2026-03-07 07:03:44 -08:00
* Add the world * doc update * docs * Fix Blast/Missile not clearing Reflect * Update worlds/earthbound/__init__.py Co-authored-by: Duck <31627079+duckboycool@users.noreply.github.com> * Update worlds/earthbound/__init__.py remove unused import Co-authored-by: Duck <31627079+duckboycool@users.noreply.github.com> * Update worlds/earthbound/__init__.py Co-authored-by: Duck <31627079+duckboycool@users.noreply.github.com> * Update worlds/earthbound/modules/dungeon_er.py make bool optional Co-authored-by: Duck <31627079+duckboycool@users.noreply.github.com> * Update worlds/earthbound/modules/boss_shuffle.py typing update Co-authored-by: Duck <31627079+duckboycool@users.noreply.github.com> * Update worlds/earthbound/modules/boss_shuffle.py Co-authored-by: Duck <31627079+duckboycool@users.noreply.github.com> * Filter events out of item name to id * we call it a glorp * Update worlds/earthbound/Regions.py Co-authored-by: Duck <31627079+duckboycool@users.noreply.github.com> * Update worlds/earthbound/__init__.py Co-authored-by: Duck <31627079+duckboycool@users.noreply.github.com> * Update worlds/earthbound/Items.py Co-authored-by: Duck <31627079+duckboycool@users.noreply.github.com> * Update worlds/earthbound/Regions.py Co-authored-by: Duck <31627079+duckboycool@users.noreply.github.com> * Fix missing optional import * hint stuff * -Fix Apple Kid text being wrong -Fix Slimy Pile text being wrong * -Fix some sprite corruption if PSI was used when an enemy loaded another enemy -Fixed a visible artifact tile during some cutscenes * Update ver * Update docs * Fix some money scripting issues * Add argument to PSI fakeout attack * Updated monkey caves shop description * Remove closing markdown from doc * Add new flavors * Make flavors actually work * Update platforms * Fix common gear getting duplicated * Split region initialization * Condense checks for start inventory + some other junk * Fix some item groups - change receiver phone to warp pad * wow that one was really bad :glorp: * blah * Fix cutoff option text * switch start inventory concatenation to itertools * Fix sky runner scripting bug - added some new comm suggestions * Fix crash when generating with spoiler_only * Fix happy-happy teleport not unlocking after beating carpainter * Hint man hints can now use CreateHint packets to create hints in other games * Adjust some filler rarity * Update world to use CreateHints and deprecate old method * Fix epilogue skip being offset * Rearrange a couple regions * Fix tendapants getting deleted in battle * update doc * i got scared and forgot i had multiple none checks and am worried about this triggering but tested and it works * Fix mostly typing errors from silvris * More type checks * More typing * Typema * Type * Fix enemy levels overwriting music * Fix gihugic blunder * Fix Lumine Hall enabling OSS * del world * Rel 4.2.7 * Remove some debug logs * Fix vanilla bug with weird ambush detection * Fix Starman Junior having an unscaled Freeze * Change shop scaling * Fix shops using the wrong thankful script * Update some bosses in boss shuffle * Loc group adjustment * Update some boss shuffle stuff | Fix Enemizer attacks getting overwritten by Shuffle data | Fix flunkies not updating and still being used with enemizer * Get rid of some debug stuff * Get boss shuffle running, dont merge * Fix json and get boss shuffle no plando back up * Fix Magicant Boost not initializing to Ness if party count = 4 * Fix belch shop using wrong logic * Don't re-send goal status * EBitem * remove : * idk if this is whatvi wanted * All client messagesnow only send when relevant instead of constantly * Patch up the rest of boss plando * Fix Giygas being not excluded from enemizer * Fix epilogue again * adjust the sphere scaling name * add the things * Fix Ness being placed onto monotoli when monotoli was in sea of eden * Fix prefill properly * Fix boss shuffle on vanilla slots. * rename this, apparently * Update archipelago.json --------- Co-authored-by: Duck <31627079+duckboycool@users.noreply.github.com> Co-authored-by: NewSoupVi <57900059+NewSoupVi@users.noreply.github.com>
53 lines
1.9 KiB
Python
53 lines
1.9 KiB
Python
from ..game_data.palettes_organized import map_palettes, nice_palettes, ugly_palettes, nonsense_palettes
|
|
from typing import TYPE_CHECKING
|
|
if TYPE_CHECKING:
|
|
from . import EarthBoundWorld
|
|
from .Rom import LocalRom
|
|
|
|
|
|
event_palettes = {
|
|
"Happy-Happy Village": 0x8367,
|
|
"Threed": 0x85A7,
|
|
"Deep Darkness": 0x8F67
|
|
}
|
|
|
|
|
|
def randomize_psi_palettes(world: "EarthBoundWorld", rom: "LocalRom") -> None:
|
|
spell_palettes = []
|
|
for i in range(34):
|
|
spell_palettes.append(0x0CF47F + (i * 8))
|
|
|
|
for i in range(7):
|
|
spell_palettes.append(0x360710 + (i * 8))
|
|
|
|
shuffled_palettes = spell_palettes.copy()
|
|
|
|
if world.options.randomize_psi_palettes == 1:
|
|
world.random.shuffle(shuffled_palettes)
|
|
|
|
elif world.options.randomize_psi_palettes == 2:
|
|
for i in range(0x010E):
|
|
rom.write_bytes(0x0CF47F + i, bytearray([world.random.randint(0x00, 0xFF)]))
|
|
|
|
for i in range(0x50):
|
|
rom.write_bytes(0x36F710 + i, bytearray([world.random.randint(0x00, 0xFF)]))
|
|
|
|
for index, pointer in enumerate(spell_palettes):
|
|
rom.copy_bytes(pointer, 8, shuffled_palettes[index])
|
|
|
|
|
|
def map_palette_shuffle(world: "EarthBoundWorld", rom: "LocalRom") -> None:
|
|
for i in range(168):
|
|
rom.copy_bytes(0x1A7CA7 + (i * 192), 191, 0x381000 + (i * 192))
|
|
|
|
for item in map_palettes:
|
|
choosable_palettes = nice_palettes[item]
|
|
if world.options.map_palette_shuffle > 1:
|
|
choosable_palettes += ugly_palettes[item]
|
|
if world.options.map_palette_shuffle > 2:
|
|
choosable_palettes += nonsense_palettes[item]
|
|
|
|
chosen_palette = world.random.choice(choosable_palettes)
|
|
rom.copy_bytes(0x381002 + (chosen_palette * 192), 29, 0x1A7CA9 + (map_palettes[item] * 192))
|
|
rom.copy_bytes(0x381022 + (chosen_palette * 192), 157, 0x1A7CC9 + (map_palettes[item] * 192)) # The event palette pointer is between these 2 blocks
|