[Pokemon] Fixes and updates (#1108)

* [Pokemon] Logic fixes

* [Pokemon] Fix seed name length

* [Pokemon] Location name changes

* [Pokemon] Hidden Item Nurse Bed logic fix

* Badges Needed description update

* Ensure player name does not exceed 16 bytes

* Player name check fix

* Remove unique items in start_inventory from item pool

* Vending Machine Drinks will not be created as filler

* Skip trainer text

* Badges needed for viridian gym text

* Add slot data for trackers

* free fly map in slot data and old_man = vanilla allows more free fly maps

* Re-add mistakenly removed slot data item

* Add tracker link to setup doc

* Doc fix

* Fix base patch

* Change pre_fill to generate_basic so items are pre-filled before item links

* Rename some hidden locations

* missing file from commit and revert one errant location name change
This commit is contained in:
Alchav
2022-11-01 02:02:15 -04:00
committed by GitHub
parent c1d7abd06e
commit 813015e007
13 changed files with 121 additions and 69 deletions
+3 -3
View File
@@ -170,12 +170,12 @@ async def gb_sync_task(ctx: GBContext):
data_decoded = json.loads(data.decode())
#print(data_decoded)
if ctx.seed_name and ctx.seed_name != bytes(data_decoded['seedName']).decode():
if ctx.seed_name and ctx.seed_name != ''.join([chr(i) for i in data_decoded['seedName'] if i != 0]):
msg = "The server is running a different multiworld than your client is. (invalid seed_name)"
logger.info(msg, extra={'compact_gui': True})
ctx.gui_error('Error', msg)
error_status = CONNECTION_RESET_STATUS
ctx.seed_name = bytes(data_decoded['seedName']).decode()
ctx.seed_name = ''.join([chr(i) for i in data_decoded['seedName'] if i != 0])
if not ctx.auth:
ctx.auth = ''.join([chr(i) for i in data_decoded['playerName'] if i != 0])
if ctx.auth == '':
@@ -260,7 +260,7 @@ async def patch_and_run_game(game_version, patch_file, ctx):
patch = stream.read()
patched_rom_data = bsdiff4.patch(base_patched_rom_data, patch)
written_hash = patched_rom_data[0xFFCC:0xFFDC]
written_hash = patched_rom_data[0xFFCB:0xFFDB]
if written_hash == basemd5.digest():
with open(comp_path, "wb") as patched_rom_file:
patched_rom_file.write(patched_rom_data)