@sionco, I suppose you deal with the unloaded scenes by packing them and saving to file? (so that memory usage is kept to a minimum)
I tried that approach a few weeks ago to make an infinite space universe, and it does work pretty well. Performance-wise it seemed just perfect, as far as I tested it, although I had nothing but empty space and one dummy asteroid per sector (the unit I divided space into (3 * screen_size
) ).
The good thing is Godot makes it really easy to save stuff in this way. If you export all the necessary variables and set object ownerships properly, Godot does all the magic (and so you don't need a separate JSON file to store script variables).
There is a caveat that you'll end up with many separate files (one per sector/chunk). I never dealt with this before, so I don't know if that's to be expected. My sectors were big, but if I was making something like minecraft, I'd have a million files in a heartbeat. Still not sure if that would ever be a problem.
I still tried to get around that caveat, by saving the sectors in a single PackedScene, but then, for some reason, they were no longer saving all their children. In fact, they were saving as default sectors with nothing set... However, that allowed me to realize that bundling them like that did hurt performance (the game would hiccup when crossing sector boundaries), and the reason was that I was constantly packing and unpacking and saving and loading that same scene (and, by the way, switching the parent and owner of sectors to and from it).
I went around that by loading it and unpacking it at the start, and packing and saving it at the end, but I don't quite remember if that helped by much (did by a bit at least). However, that meant memory usage would grow as the player would travel. I guess the solution for that would be to divide space further into bigger chunks, which would once more involve creating more files, but still much less than before. So in a more Minecraft-ish type of game, my sectors would be the cells/blocks, and I'd save a bunch of them in a chunk scene.
Since I failed to successfully save the sectors in this way, I never got to implement that solution. But I'm guessing the problem is a mistake of mine and that that would be the way to go.