Require help with modding

Hi guys,

I want to add custom perks to pre-existing jobs/professions. The mod idea I am working on is called Master Crafters and it should increase the chance of fine obj to be crafted by any crafter of lvl 6 so i wanted to simply mixintos a perk to the carpenter

{  
       "level_data" : {
          "6" : {
             "perks" : [
    			{
                   "type" : "set_fine_percentage",
                   "name" : "Master Perfectionist", 
                   "id" : "crafter_recipe_unlock_6", 
                   "icon" : "file(../common/images/artistic_inspiration.png)", 
                   "description" : "The Carpenter has Mastered his Craft. Perfection seems natural to him.",
                   "percent_chance" : 100,  
                   "level" : 6,
                   "demote_fn" : "unset_fine_percentage"
                }
    		]

}

Now my problem is just making a manifest that mixintos that into the carpenter_description.json and a file contaning the above apperently is not enough or the correct way to do it.

Hi @Sral92x, and welcome to the forum!

Is that the entire file? It’s missing a couple of ‘}’, one for "level_data" and one for "6".

Also, a tip: if you’re not getting the expected results you can always check out stonehearth.log. It can tell you if something’s not right; like if a file isn’t valid or even found.

thanks an overlook by me. I’ll keep this thread up to date on progress on my mod and the walls i run into also the log said missing source but i was too blind to see where

New question can i tell my manifest to override a luac file? and if so is there anything i should pay attention to?

You want to overwrite MANIFEST?! not best idea…

Yes you can. Use overwrite in your manifest. There are a lot of examples of that on the forum.
You have to pay attention to the uri’s that they still have the right file location.

I dont know why but the log keeps on telling me that the luac file was not mixintos cause missing resource but i put it under the override section.

2015-Jul-08 16:39:36.984513 | server |  1 |                        resources | could not find resource for /mastercrafters/overrides/new_game_call_handlers.luac while processing mixintos for mastercrafters.  ignoring.

{
    "info": {
        "name": "mastercrafters",
        "version": 1
    },
    
    "aliases" : {
    },

    "overrides": {
        "stonehearth/call_handlers/new_game_call_handler.luac": "file(overrides/new_game_call_handlers.luac)"
    },

    "controllers": {
    },

    "mixintos": {
        "stonehearth/jobs/carpenter/carpenter_description.json": "file(mixins/carpenter_description_mod.json)",
        "stonehearth/jobs/mason/mason_description.json": "file(mixins/mason_description_mod.json)",
        "stonehearth/jobs/weaver/weaver_description.json": "file(mixins/weaver_description_mod.json)",
        "stonehearth/jobs/blacksmith/blacksmith_description.json": "file(mixins/blacksmith_description_mod.json)",
        "stonehearth/jobs/blacksmith/recipes/recipes.json": "file(mixins/recipes/recipes.json)"
    }
}

You are overriding new_game_call_handler.luac with new_game_call_handlers.luac
Notice the extra s. You sure that is right?

i tend to like to name the files within my mod slightly different to the ones in the stonehearth mod to prevent confusion on my end. but ill look into it

not all mixinto work correct right now, i need overwrite ton of files in my mod, sadly, but only one inclusion into manifest

It works fine as long as the file itself has that extra s too. I don’t know why it is not loading.

i was irritaed by the log saying mixintos eventhough i am using override for the luac file. when i used override before and had an error for missing resource it would tell me it was override and not mixintos

ya forgot the s on the file faceplam

Don’t feel bad. Happens to all of us, even at team Radiant. It is one of the things you have to check as a first priority.

1 Like