write 1024 bytes in one go instead of one by one
This commit is contained in:
parent
07da1c510b
commit
770f3c305a
3
Rom.py
3
Rom.py
|
@ -727,8 +727,7 @@ def patch_rom(world, rom, player, team, enemized):
|
|||
rom.write_byte(0x180182, 0x00) # Don't auto equip silvers on pickup
|
||||
|
||||
# set up game internal RNG seed
|
||||
for i in range(1024):
|
||||
rom.write_byte(0x178000 + i, random.randint(0, 255))
|
||||
rom.write_bytes(0x178000, random.getrandbits(8 * 1024).to_bytes(1024, 'big'))
|
||||
|
||||
# shuffle prize packs
|
||||
prizes = [0xD8, 0xD8, 0xD8, 0xD8, 0xD9, 0xD8, 0xD8, 0xD9, 0xDA, 0xD9, 0xDA, 0xDB, 0xDA, 0xD9, 0xDA, 0xDA, 0xE0, 0xDF, 0xDF, 0xDA, 0xE0, 0xDF, 0xD8, 0xDF,
|
||||
|
|
Loading…
Reference in New Issue