TehNut-Mods / ResourcefulCrops

Simply JSON based resource crops
MIT License
12 stars 7 forks source link

server crash with custom seeds without metadata #12

Closed Saereth closed 9 years ago

Saereth commented 9 years ago

If a custom entry is made such as ThermalFoundation:Ore#4 for input it will crash the server. ThermalFoundation:Ore:0#4 works fine. The meta is intended to be included as per the instructions (which I didnt notice until I started digging around the code for the crash issue). A more graceful way of handling the error may be a good enhancement for the mod in the future

TehNut commented 9 years ago

What is the crash exactly?

TehNut commented 9 years ago

Alright, it was just an out of bounds exception.

With this commit, it'll swallow the crash and print an error to the log:

LogHelper.error("Error adding " + (input ? "inputStack" : "outputStack") + ": " + stackString + ". Is it formatted correctly?");