This is a workaround for not being able to reload a tree in the way we'd like. In this PR we reload a tree by
loading a game from disk
creating a new game from the first game's configuration (with all nodes allocated)
copying the memory from the loaded game into the new game (e.g., cf_values, strategies, etc)
locking the copied nodes and resolving.
This is a bit memory inefficient, but actually isn't much less efficient than the original version.
In the future the correct way is to probably serialize a file into an archive that can be read from disk as individual components. For instance, the ability to read just the configuration, or just the strategy, or just the cf_values, possibly for individual streets, etc.
This is a workaround for not being able to reload a tree in the way we'd like. In this PR we reload a tree by
This is a bit memory inefficient, but actually isn't much less efficient than the original version.
In the future the correct way is to probably serialize a file into an archive that can be read from disk as individual components. For instance, the ability to read just the configuration, or just the strategy, or just the cf_values, possibly for individual streets, etc.