I've messed up code to reveal the map, and now it's too big and I'm having perfomance issues.
Have any code to revert this map reveal?
Reset map revealed
Re: Reset map revealed
Malcomn wrote:I've messed up code to reveal the map, and now it's too big and I'm having perfomance issues.
Have any code to revert this map reveal?
Nope
Re: Reset map revealed
You can use the map seed to get the exact same layout in another game, for what that's worth.
- StoneLegion
- Filter Inserter
- Posts: 687
- Joined: Fri Sep 05, 2014 7:34 pm
- Contact:
Re: Reset map revealed
Sorry to pop this up again. Why is it lagging? If it's all shutdown it should not lag and this seems to be more of a performance issue / bug if that is the case.
Re: Reset map revealed
This thread popped up when I was doing a search for this main topic. I eventually found the solution in the WIKI. Reproduced below for other people who stumble here.
In answer to the "why is it slow" question, with all those biters to calculate every tick, it certainly would run slow even with no user buildings made.
In answer to the "why is it slow" question, with all those biters to calculate every tick, it certainly would run slow even with no user buildings made.
Reference https://wiki.factorio.com/Console#World_ManipulationIf much of the map is revealed, it increases the size of the save file. The following command cancels the generation of all chunks that are currently queued for generation and removes chunks outside a 32 chunks radius around 0,0. Note that this will remove player entities if there are any on these chunks.Code: Select all
/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
Re: Reset map revealed
I assume most, if not all of those biters are inactive, so they should take up very little processing time.mewtwoEX wrote:This thread popped up when I was doing a search for this main topic. I eventually found the solution in the WIKI. Reproduced below for other people who stumble here.
In answer to the "why is it slow" question, with all those biters to calculate every tick, it certainly would run slow even with no user buildings made.
Reference https://wiki.factorio.com/Console#World_ManipulationIf much of the map is revealed, it increases the size of the save file. The following command cancels the generation of all chunks that are currently queued for generation and removes chunks outside a 32 chunks radius around 0,0. Note that this will remove player entities if there are any on these chunks.Code: Select all
/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
There are 10 types of people: those who get this joke and those who don't.