TerraformGenerator icon indicating copy to clipboard operation
TerraformGenerator copied to clipboard

Be able to pass in a ConfigLoader/Config file to TerraformGenerator

Open svaningelgem opened this issue 1 year ago • 2 comments

This way one could load it as:

WorldCreator creator = new WorldCreator("fairy_kingdom");
creator.generator(new TerraformGenerator(new MushroomConfig()));
World fairyWorld = creator.createWorld();

WorldCreator creator = new WorldCreator("giant_world");
creator.generator(new TerraformGenerator(new GiantTreeConfig()));
World giantsWorld = creator.createWorld();

The issue I see is that the configuration is mostly static and everywhere I look it is referenced to the TFG class or enumerations that are statically built once.

Do you have any easy way I could do this? (I doubt it's possible right now, but if it's relatively easy, I'll change the code to accommodate for this paradigm.

Thanks

svaningelgem avatar Aug 13 '24 15:08 svaningelgem