Page 1 of 1

BUG - Map revealed when scenario loaded

Posted: Wed Feb 27, 2019 10:07 pm
by Omarflyjoemacky
Hello Dev's!

I'm playing with the map editor in .17, but when I go to test the scenario I've made, the explored areas of the map (areas created or explored in the editor) show up as already explored for the player. Verified in .16 that the map shows as unexplored when the scenario is loaded.

Re: BUG - Map revealed when scenario loaded

Posted: Thu Feb 28, 2019 12:09 am
by Rseding91
Thanks for the report however this is working as intended. The map editor is no different than a normal game just you can use the editing tools.

If you want to un-explore the explored area there are Lua commands that can do that.

I might in the future add some editing tools to do it through the GUI but for now there are other things to work on.

Re: BUG - Map revealed when scenario loaded

Posted: Thu Feb 28, 2019 12:23 am
by Omarflyjoemacky
Forgive me - I know you're a busy guy.

Like I mentioned, .16 did this automatically. I know nothing about Lua - can you help?

Re: BUG - Map revealed when scenario loaded

Posted: Thu Feb 28, 2019 12:26 am
by Omarflyjoemacky
Thanks so much for your advice. Found a fix online.

/c local surface = game.player.surface;
game.player.force.cancel_charting(surface);
local chunk_radius = 32;
for chunk in surface.get_chunks() do
if (chunk.x < -chunk_radius or chunk.x > chunk_radius or chunk.y < -chunk_radius or chunk.y > chunk_radius) then
surface.delete_chunk(chunk)
end
end

Enjoy watching you bugfix on Twitch, btw. Thank you, thank you, thank you.

Re: BUG - Map revealed when scenario loaded

Posted: Sun Mar 03, 2019 11:45 pm
by Omarflyjoemacky
This command it turns out wipes everything you might have changed in a map. Frustrating.

Any advice? I know you're a busy guy. .16 hid the map automatically, I don't see how this is a feature on the new editor.