TheLegoRebel's quick guide to fixing your mod's errors!

Recently, I’ve been seeing multiple threads of people who want to start modding, which is great! It’s always a good thing for more people to get involved with modding. But, as was inevitable, many of these aspiring modders get errors when trying to create their mod, most of which, their solutions are easy. However, new modders might not know all the steps to take when checking for coding issues.

So I’ve decided to make a quick little list of steps to take when your mod throws an error, and you don’t know what caused it.

  1. Always, always, copy and paste your code in This website will check and see if you’re missing anything basic, like a missing semi-colon (;), comma (,), or squiggle bracket ({ or })

  2. The log is your friend. Located at C:\Program Files (x86)\Steam\steamapps\common\Stonehearth, any error that pops up in game will appear here, along with some others. If something’s not working, check here. It’ll tell you what file is having a problem.

  3. A specific error that might appear when launching the game, or appear in the Log, is one that might look like this:

This occurs because somewhere in your mod, you’ve typed a line of code that is trying to reference the alias in your mod’s manifest. This is typically attributed to a crafter with a recipe that’s trying to make that item.

The Solution? Check for misspelling’s in your manifest and recipe file.

Sample messed up alias

"decoration:rune_ston_small" : "file(entities/decoration/rune_stone_small/rune_stone_small.json)",

[details=Line in recipe that refers to missing alias.] "produces": [ { "item": "runes:decoration:rune_stone_small" } ][/details]

In this example, the line in the recipe is looking for an alias called “decoration:rune_stone_small”, when the alias in the manifest is “decoration:rune_ston_small”.

This error can also happen when the file path to the Json is messed up. Make sure the file path in the Manifest is the same as the File Path in your file browser.

Sample messed up alias

"decoration:rune_stone_small" : "file(entities/decoration/rune_stone_small.json)",

Sample Correct alias

"decoration:rune_stone_small" : "file(entities/decoration/rune_stone_small/rune_stone_small.json)",

4. If you’re making a mod with an en.json (Stores all the Strings[words, tooltips, names, etc]), and the item in question displays the file path of the string, and not the string itself, something is spelled wrong. Double check all of your spellings, and make sure you aren’t missing anything.

Example wrong

"recipe_name": "i18n(runes:jobs.mason.rune_stone_small_recipe.recipe_name)",

Example right

"recipe_name": "i18n(",

The issues was the missing “recipes” inside the path.

If you think I should add in any steps (I’m gonna need too), or if they didn’t solve it for you, reply here and I’ll help you out.

Example code was taken from @8BitCrab’s Rune mod, for which I am an official updater for.


Great guide! I’ve been modding a ton of items lately and the biggest thing I find myself screwing up is commas. ALWAYS COMMAS unless it’s the last thing in a list; a comma that shouldn’t be there is as bad as a missing one. :slight_smile:

Also, one I see occasionally when I hiccup something is “$crafter has a recipe that does not refer to an item in the manifest [recipe name]”. Always double and triple check your manifest against your other stuff and make sure everything is spelled exactly the same and referred to exactly the same in every location. Usually this one’s just forgetting/messing up the alias, or my best friend the missing trailing comma.