[2.0.66] UI generates incomplete map exchange string

Things that has been reported already before.
UpsideDownFoxxo
Burner Inserter
Burner Inserter
Posts: 11
Joined: Mon Aug 30, 2021 2:19 am
Contact:

[2.0.66] UI generates incomplete map exchange string

Post by UpsideDownFoxxo »

Previewing a map in the start screen and then copying the exchange string without generating the world yields this exchange string.

Code: Select all

>>>eNpjYmBgcGJgZGDgYUnOT8xhYGiwh2Gu5PyCgtQi3fyiVGRhzuSi0pRU3fxMVMWpeam5lbpJicUoijkyi/Lz0E3gyUssLcssjk/OyUxLQ5ZgLcpPzi5GFhErLkksKsnMS49PLEpNjM/NzywuKUU1jbW4JD8PVaSkKDUVxRju0qLEvMzSXHSXsJYnlqQWIYswMG6MEJVtaJFjAOH/9QwK//+DMJD1ABhUIMzA2ABRzQgUhAFWqGcYFByB2AlhHCNjtcg694dVU+wZISr1HKCMD1CRA0kwEU8Yw88Bp5QKjGGCZI4xGHxGYkAsLQFaAVXF4YBgQCRbQJKMjL1vty74fuyCHeOflR8v+SYl2DMauoq8+2C0zg4oyQ7yLhOcmDUTBHbCvMIAM/OBPVTqpj3j2TMg8MaekRWkQwREOFgAiQPezAyMAnxA1oIeIKEgwwBzmh3MGBEHxjQw+AbzyWMY47I9uj+AAWEDMlwORJwAEWAL4S5jhDAd+h0YHeRhspIIJUD9RgzIbkhB+PAkzNrDSPajOQQzIpD9gSai4oAlGrhAFqbAiRfMcNcAw/MCO4znMN+BkRnEAKn6AhSD8EAyMKMgtIADOLiZ4Ynygz1qSgMxQIbM2TkvHAAklb6k<<<
Generating the map, going into Editor and grabbing an exchange string through the Edit map gen settings dialogue yields this (different) exchange string:

Code: Select all

>>>eNp9Ur1LAzEUT1qP1lqkQxUErR261kEdxcQu4n/gVtJrKoftpeTuFHWwQ4cOgrMu+hcIjm6Ci4KC4ORWUcHBQVBca9K73BfFB+/ld7/3/bgEAKACIADZMZ2RJgAdpDSjs3ab8jLjNEyP69yp0zIzosHUpK29co1YkeC0wZkZr5A1ibNjWFW9aTQaYYfGmb5thZlpyybcNsytKuGUVFvMsGwnWk2zbGZGGZtTGikz4XBiGk4rPom2S2zKwwyAl5tTc51uAUgdHILiYCBVoL44lVQAO240FKQSzVsGFNeEVoKS8rZSFrCHrmvYozb+ocCyQEtD+UYBOMhfrL/s2wiqsDQOgOvsIo+BKWkSvjk9kXKl3EBl9pHnekbw4V7KJxrm5yaFOT8Spjjr77Gq0vIYNobyq+Z7VeAJxacrYbgiSxakuZVGC04jJoEuxMcY4nnlnQlCRP4iCM9QDza6U21vQv1jg5Swf9YRe8SYEh5x3IxsWPfNR9KfRtzvMaW+8BmGSQlk1I/g3C/pUaXcN4dhXjxJ/w/6Qv47bPH+1uv9Acnop3o=<<<
Generating the map, and querying the current surface's exchange string via /c print(game.player.surface.get_map_exchange_string()) yields this (again, different, but MUCH longer this time) exchange string.

Code: Select all

>>>eNqlVTFsEzEUPTdNm6QhSSFFQoJSoa6HaFKgA+pdKyGEEMxsxblzEivJXeS7axUY6NARxMIALHRlqcTAwFYJCYEEUgUTWxELA6AiECxIxT7fpefzHQuW7Py89/39/7PPHlEUZVkBilIcNWzYVZR1LewFw+73EVFtgqJw3iCeiVQbi87IQr2B2oCO4JzDxLbiEYoW9Faxs2J0cbMZJbLENjpOFDnquJC42GqtQILgSs/GjuuJ0bKOa1si4hKEhDATHoEW9nrxTLJr0EUkimQKJjJsAl28isCpUoPYa5YKHeqFnU7U8YhIqT1s4Sh/mPMGJH3kqi0CHTEjTje7nihBOYKrJhlEuUnOtSEmAznipEGg0UGm2vNMlRYhbmbJhKSTTOVakDRgt2sL0ULQLyyeSalFFU7RRaQkXcqcb3hOW9aMc2maFQOa2HTHxWR9wkQOIq4fOoFNka3A2T52YUKaDJbSDAI6PaqPHLDcxa22myz1RA+Z7Biycx7FKwHuQMuUyCKhm5okdYERshplBqdoUYlw8kFgZFyIgp+T5FvmsGchmStwZeJ1lDmcWGOefuMDCZ1ca2MXpdUyhiwXuwNQyDVwS5p7iIGJa/3fRTfaxGIa+bbXQtIiiReffFWlXUyjLu4iMJU3EepLd9SYiakcczJUk6G6DM3L0FkZOidD54UC6ZWgMjgKjvtfg5hagNUSsHoCNi8d/WD7z6QRc2lELY0QRfEPyZwM1WSo/u/HQ3l6ferE+sa0wvr+bWVmf591au3SZ5Z1BaxzZ0DBsGX9hzD2Ks4s0b7MHegEAMCt6taljzfva4CDp/XA2AuQ7UaIXA6Na3oqNRsa85E4db/9iBh8UZcuEXjl9AODkxuMBODu12ebv1/uLII/T76/u9q4oYG5i9Vve7WtRUqOs9JHhsOjh6w9D0tRwpi7WkB90MDbN6x90UCWzaiyQV+gw/aVjAIqJWpt3qHDzHElTG0xDFPVQdNvv8JKPoXGey1eBxXiAgs+zYZXbPAXHGYGuKnf04F+MmSPHbjQ+TUlmoN5UOHrcNkXkfVjicgbEa0jhszqCdtQYAuaw+FzZpgN1XNnPPynP9ZBhhnM6yfF+D/GhKH4b0X35c4MD+ieJp40ZrAgSw+yC38Bv7B0vw==<<<
The codes generated by the game UI seem to be in various states of incompleteness. For example, both UI-Strings have an empty table in the autoplace_settings field, and the one generated through the editor seems to also not have fields for some of the pollution settings (which is why it is slightly shorter).

While this might be fine for normal play, it seems to break down if you want to use the exchange string to generate modded maps through the Lua API.
The code for this used the parsing function provided by the helpers module and supplied the map_gen_settings field of the result directly to the game.create_surface function.
Of the above strings, the two generated by the UI yield this patchy mess when used with alien biomes.
Alien Biomes being very unhappy
Alien Biomes being very unhappy
10-02-2025, 15-35-53.png (6.33 MiB) Viewed 157 times
Only the exchange string generated by the command seems to have enough information to accurately recreate the map.
The &quot;Fixed&quot; Map for reference
The "Fixed" Map for reference
10-02-2025, 15-37-25.png (6.34 MiB) Viewed 157 times
Since the game indiscriminately refers to all of these as an "exchange string", I feel like they should be equivalent. This is also why I'm reporting this as a bug here, and not with the alien biomes mod.
Post Reply

Return to “Duplicates”