lunar-sway / minestuck

A Homestuck Minecraft mod
Other
54 stars 64 forks source link

Avoid/catch problems setting up a StructureBlockRegistry #592

Closed kirderf1 closed 4 months ago

kirderf1 commented 5 months ago

Fixes a problem that @akisephila encountered. When an exception is thrown in ILandType.registerBlocks(), the error ended up not being logged, thus making it harder to find the actual problem. This PR fixes this issue in two ways:

kirderf1 commented 5 months ago

If one really want to test this, you could try out TitleLandType.isAspectCompatible() by predefining land types, and creating a land/loading a save file with a land to test the LandGenSettings part. One could try it as-is to see that everything works fine normally, and one could purposefully make a land throw an exception in landType.registerBlocks() and see that the exception is handled properly.

Dweblenod commented 4 months ago

Using /sburbpredefine, it does correctly prevent a disallowed land type combo from being used, however it does not give a warning and automatically reassigns the offending land type