Tough As Nails

Tough As Nails

21M Downloads

[1.12.2] Crash when editing the drinks config.

KIdWither opened this issue ยท 7 comments

commented

TAN Version: 1.12.2.-3.1.0.73
Forge Version: 14.23.1.2581
Crash log: https://pastebin.com/iyGn2sir

I got the crash above when I loaded up the game after adding many of the Pam's Harvestcraft drinks to the drinks config and crashed (the link above is just TAN and forge, from what I can tell the crash logs are identical). Also, let me know if you want me to link my config.

commented

Yeah, we do indeed need the config file

commented

Got you.
config.zip

commented

@KIdWither
First, you are loading a config file that references items from HarvestCraft, but you aren't even loading HarvestCraft.
Second, In drink_stats.json...

Invalid names:
Line 22: harvestcraft:coconutmilk.item should be harvestcraft:coconutmilkitem
Line 337: harvestcraft:cactusjuiceitem should be harvestcraft:cactusfruitjuiceitem
Line 571: harvestcraft:permsimmonsmoothieitem should be harvestcraft:persimmonsmoothieitem
Line 652: harvestcraft:lemonadeitem should be harvestcraft:lemonaideitem (misspelling on HC's side)

Invalid thirst values (values must be integers):
Line 16: 1.5 is invalid, change to 1 or 2
Line 43: 1.5 is invalid, change to 1 or 2

@Adubbz It might be useful to check the validity of the Json entries in ModConfig#populateDataMap before trying to act on them in case they are invalid (misspelled name, erroneous values, etc).

commented

Ok got it.

commented

I'm getting the same exact crash, despite not misspelling anything (to my knowledge) nor forgetting to load Harvestcraft; the only config file I've edited is drink_stats.json as well:
https://pastebin.com/AMS9KwHr

I honestly can't figure out what I've done wrong, but it's incredibly frustrating and "juice" has stopped looking like a word to me with how many times I've gone back through this.

commented

@pharade You are not separating elements properly with ,. Use jsonlint to find your errors.

commented

Can you share a working config for pam's drinks?