Page 1 of 3

[MOD 0.16 - 1.1] New Game+

Posted: Mon Sep 18, 2017 2:25 pm
by Bilka
Image
Description
Allows you to start a new game plus once you launch a rocket. Generate a new world and leave your home world, but carry over an inventory full of items and your research.

Enabled the mod option to be able to run the ngp-gui command. Then simply type /ngp-gui in chat (or the console, it's the same thing), and you will see the gui and be able to start the new game plus without launching the rocket.

The above processes can be repeated an infinite amount of times. Please know that it is not possible to go back to your old world(s)! Pressing the start button might also freeze your game for up to a few minutes. That's fine. It'll unfreeze eventually.

Works with mods that add ores or terrain etc. If you want to generate a new world with them, first enable them, then start the new game plus, not the other way around.

Details
  • Name: New Game+
  • Version: 5.0.1
  • Factorio-Version: 0.16 - 1.1 (0.15 on github)
  • Description: Allows you to start a new game plus once you launch a rocket (or run a command). Generate a new world, but carry over an inventory full of items and your research.
  • License: MIT
  • First release: 2017-09-18
  • Download: Mod portal
  • Dependencies: base
  • Category: Helper Mods
  • Tags: Helper Mods
  • Author: Bilka
  • Git repository: https://github.com/Bilka2/NewGamePlus
Pictures

Re: [MOD 0.15] New Game+

Posted: Sun Sep 24, 2017 7:20 pm
by ArchtypeOfEpic
Cool! I think a mod should be created to add new tiles to make a new "planet". And more tech. And more stuff...

Yeah, that would take a lot of effort, but could work really well with this mod!

Re: [MOD 0.15] New Game+

Posted: Mon Sep 25, 2017 4:12 pm
by elkillo
i personally believe this should be a vanilla option. Since its not im glad you made it! its now a permanent addition to my mod lineup.

Re: [MOD 0.15] New Game+

Posted: Mon Sep 25, 2017 7:37 pm
by Bilka
Version 1.1.0 is now out :)
  • Added all advanced settings that can be found in the map generation GUI to the advanced settings
  • Added option to reset enemy evolution
  • Added "Reset to default" button that resets all settings back to the default
  • The "Set to current map settings" button now also sets the advanced settings to the currently used settings

Re: [MOD 0.15] New Game+

Posted: Sat Oct 07, 2017 6:43 pm
by Bilka
Version 1.1.1 is now out
  • Added support for the building platform mod
  • Minor code cleanup
Sadly the support for the building platform mod is currently limited to the "default" generation option .The grid and concentric-circle options cannot be used on another surface than nauvis, as configured in the code of the building platform mod.

Re: [MOD 0.15] New Game+

Posted: Sat Oct 07, 2017 10:56 pm
by eradicator
Have you posted a feature request to delete/replace nauvis? Imho if allowing to straight out delete nauvis is not desirable it should cause far less problems if it was possible to create new surface -> swap new surface and nauvis (new surface becomes nauvis) and then delete the "new" surface that now contains what was formerly nauvis. That way nauvis always exists. Hm. Tho at the moment of swapping there would still be the need to fire an event for deletition+destruction of every entity on both surfaces :x.

Have you tried asking Rseding to allow changing the currently-unaccessible map generator settings instead? I've personally despaired before about the inability of changing map width/height, so i would certainly second a request.

Re: [MOD 0.15] New Game+

Posted: Sun Oct 08, 2017 12:18 pm
by Bilka
eradicator wrote:Have you tried asking Rseding to allow changing the currently-unaccessible map generator settings instead? I've personally despaired before about the inability of changing map width/height, so i would certainly second a request.
He said it's been on the to-do list for a while, so he'll work on it tomorrow :)

Re: [MOD 0.15] New Game+

Posted: Fri Oct 20, 2017 12:11 am
by eradicator
Looks like it's off the todo list now. :lol:

Code: Select all

Added support to change LuaSurface::map_gen_settings runtime.
[/url]

Re: [MOD 0.15] New Game+

Posted: Sat Nov 04, 2017 8:58 pm
by Bilka
Version 1.1.2 is now out
  • Fixed building platform option appearing although the building platform mod was not installed
  • Changed how on_entity_died is raised when deleting chunks, should prevent weirdness due to chunk borders when interacting with another mod's entities

Re: [MOD 0.15] New Game+

Posted: Sun Dec 31, 2017 12:07 am
by morcup
I'm getting the following error when a friend tries to join my game. I'm not sure which mod is causing it, but I suspect this mod might be trying to spawn him in one of the previous worlds.
The error is: Couldn't find suitable position to put th eplayer in the perimeter of 200 tiles from the point {0.00000,0.000000}

Re: [MOD 0.15] New Game+

Posted: Sun Dec 31, 2017 7:50 am
by Bilka
morcup wrote:I'm getting the following error when a friend tries to join my game. I'm not sure which mod is causing it, but I suspect this mod might be trying to spawn him in one of the previous worlds.
The error is: Couldn't find suitable position to put th eplayer in the perimeter of 200 tiles from the point {0.00000,0.000000}
What other mods are you using? Are you using a custom scenario?

Re: [MOD 0.15] New Game+

Posted: Sun Dec 31, 2017 1:11 pm
by morcup
I've attached the mod-list.json , but basically it's Angel+Bob with some QOL mods. No custom scenario.

Edit: I had another friend join successfully, he had been in the previous world, but the player who generated the error had not played before in the previous world. Hope this helps.

Re: [MOD 0.15] New Game+

Posted: Sun Dec 31, 2017 11:26 pm
by Bilka
Thank you for your cooperation. Just like I thought the issue was actually partially with the base game: 56004 . I still have to teleport the joining player to the new world due to 56003 but that's not a big issue :)

Re: [MOD 0.15] New Game+

Posted: Mon Jan 01, 2018 5:45 am
by morcup
Awesome, thanks for your help.

Re: [MOD 0.15] New Game+

Posted: Tue Jan 02, 2018 2:26 am
by eradicator
@Bilka:

Now that total control over all map-gen settings at runtime is possible (or are there still any missing?) is the extra surface hack even still needed? can't you just:
  1. teleport all players to temporary surface
  2. change map gen settings for nauvis
  3. delete all chunks on nauvis
  4. regenerate span chunks on nauvis
  5. teleport players back to new nauvis
  6. remove temporary surface
This would remove the memory/cpu burden of having another surface (minor) and make the mod better compatible with other mods, even those that don't properly handle other surfaces (major).

Re: [MOD 0.15] New Game+

Posted: Wed Jan 03, 2018 10:02 pm
by Bilka
Cliff compability and the suggestion by eradicator will be implemented another time when I finally overhaul the gui again.

Version 2.0.1 is out:
  • Fixed that new players in multiplayers games would spawn in the wrong world

Re: [MOD 0.15, 0.16] New Game+

Posted: Thu Jan 04, 2018 12:13 am
by morcup
Well 16.13 fixed the crashing when another player tried to join my game, but now he spawned on a different surface and I can't figure out how to get him to the current one. We tried killing him and teleporting him but he keeps respawning on the empty surface.

Re: [MOD 0.15, 0.16] New Game+

Posted: Thu Jan 04, 2018 7:36 am
by Bilka
Are you on the latest version of my mod? That should fix that for newly joining players.

If you friend joined the map before, that wont work though. You could run /c game.remove_offline_players("name of your friend") while he is offline and then my script should move him to the right world when he rejoins, he also loses his items though.

If you just teleport him to the right surface without doing any killing it should work too. You can find out the name of the surface you are on using /c game.print(game.player.surface.name)

Re: [MOD 0.15, 0.16] New Game+

Posted: Thu Jan 04, 2018 8:52 am
by eradicator
@Bilka:

Also you might even be able to get rid of the last temporary surface as well by:
  1. Change nauvis mapgen settings
  2. Teleport players to chunk 0,1 (i.e. anywhere safe, but not somewhere that doesn't exist yet (to ease the cpu burden))
  3. Delete chunk 0,0
  4. Teleport players to chunk 0,0
  5. Disable player character movement with active=false
  6. Delete the rest of nauvis chunks
That way it also works if all surface indexes are already used up by other mods (unlikely, i know. but i like to consider stuff like that :P), and you safe cpu/code for creation of temporary surfaces. Ofc the most optimal way would be to just store the entire player character in lua, but that would involve tons of extra code :/.

Re: [MOD 0.15, 0.16] New Game+

Posted: Thu Jan 04, 2018 1:58 pm
by morcup
Oh sorry, didn't see that you'd updated the mod already. I'll give those methods a try when my friend is available. Thanks for the quick help.