mirror of
https://github.com/MarioSpore/Grinch-AP.git
synced 2025-10-21 20:21:32 -06:00
mark utf-8 output as such
This commit is contained in:
11
Main.py
11
Main.py
@@ -205,10 +205,13 @@ def main(args, seed=None):
|
|||||||
|
|
||||||
multidata = zlib.compress(json.dumps({"names": parsed_names,
|
multidata = zlib.compress(json.dumps({"names": parsed_names,
|
||||||
"roms": rom_names,
|
"roms": rom_names,
|
||||||
"remote_items": [player for player in range(1, world.players + 1) if world.remote_items[player]],
|
"remote_items": [player for player in range(1, world.players + 1) if
|
||||||
"locations": [((location.address, location.player), (location.item.code, location.item.player))
|
world.remote_items[player]],
|
||||||
for location in world.get_filled_locations() if type(location.address) is int]
|
"locations": [((location.address, location.player),
|
||||||
}).encode("utf-8"))
|
(location.item.code, location.item.player))
|
||||||
|
for location in world.get_filled_locations() if
|
||||||
|
type(location.address) is int]
|
||||||
|
}).encode("utf-8-sig"))
|
||||||
if args.jsonout:
|
if args.jsonout:
|
||||||
jsonout["multidata"] = list(multidata)
|
jsonout["multidata"] = list(multidata)
|
||||||
else:
|
else:
|
||||||
|
|||||||
Reference in New Issue
Block a user