Open hhyyrylainen opened 4 years ago
Copying a comment from discord:
I think the planet generator isn't like a microbe stage specific thing. So maybe a new sub folder like src/simulation/planet_generator.h would be the best place.
For where to construct the planet object: I think that if the GUI can tweak the parameters then it needs to work like so: GUI calls native function event updateNewGamePlanetDetails in ThriveGame, which fires an event after generating the planet maybe something line PlanetDetailsUpdated which the GUI listens to and updates waht it shows. Then when new game is started the planet details object is sent to the AngelScript patch generator (this needs adding reference counting and script bindings for the planet objects etc.) which then uses the properties when creating the map. The planet details object should also be probably stored in the created map.
Removing from the next release as this is not being actively worked on currently.
The code needs porting from C++ to C#, the code is on this branch: https://github.com/Revolutionary-Games/Thrive/tree/add_planet_generator
There is a prototype: https://github.com/Revolutionary-Games/thrive-prototypes/blob/master/Planetary_Model/planet_generator2.h that should be modified to fit into the game and put in. There are some style stuff and probably some script bindings needed.