Mixintos and overrides

Hello there, so guys, i have been cracking my head here. I made a new animal and wanted to add him to the current shepherd animal option, but i have been only able to do it when i edit the stonehearth files… i have tryied to mixnto and override with no sucess. For what i can tell what determine the animals is the “shepherd_pasture.json” inside the shepherd jobs.
What have i tried:
1- I tried to creat another shepherd_pasture.json in my mod and override the other with my manifest, no lucky
2- I tried to mix my animal into the stonehearth shepherd_pasture.json with no lucky…
3- I created a new job called ExoticShepherd… it kind works… but the shepherd coding is to much for me…
4- I tried to overrite the animal files from the mod into the stonehearth via manifest…

any tip? thank you !

This example is from my outdated Candyland mod (but still works, just checked). Does your mixinto file look like this (but changing the critters to your alpacas aliases)? :

{
   "components": {
      "stonehearth:shepherd_pasture": {
         "pasture_data": {
               "candyland:critters:chocolate_bunny": {
                  "name": "Chocolate Bunny",
                  "description": "Adorable food",
                  "icon": "/candyland/entities/critters/chocolate_bunny/chocolate_bunny.png",
                  "min_population": 2,
                  "reproduction_uri": "candyland:critters:chocolate_bunny",
                  "max_num_per_10_square_unit": 0.48,
                  "base_reproduction_period": "18h",
                  "min_reproduction_period": "12h",
                  "feed_uri": "candyland:food:rabbit_feed"
             }
         }
      }
   }
}

And then in your manifest the mixinto is added like this?:

"mixintos": {
      "stonehearth/jobs/shepherd/shepherd_pasture/shepherd_pasture.json" : "file(jobs/shepherd/shepherd_pasture/shepherd_pasture.json)"
   }

If you still have trouble, you can share your mod files and some of the community modders can take a look at them :slightly_smiling_face:
Also take a look at the stonehearth.log, usually there’s info there if something couldn’t be loaded properly.

2 Likes

No bueno =/

Here is the file if any commynity modder could take a look ;3

animalz.smod (128.8 KB)

Your mixinto is inside your aliases.

2 Likes

i edited and still no good…

{
“info”: {
“name”: “Animalz”,
“namespace”: “animalz”,
“version”: 3

},
"default_locale": "en",
"aliases": {
	"critters:alpaca:outfits:redbell": "file(entities/critters/alpaca/outfits/redbell_outfit.json)",
	"pets:alpaca": "file(entities/critters/alpaca/alpaca_pet.json)",
	"alpaca": "file(entities/critters/alpaca)",
	"alpaca:young": "file(entities/critters/alpaca/alpaca_young.json)"
},




"mixintos": {

	"stonehearth/jobs/shepherd/shepherd_pasture/shepherd_pasture.json": "file(jobs/shepherd_pasture/shepherd_pasture.json)"
}

}

You are trying to mixinto a path that does not exist

1 Like

you live in my hearth <3

the problem i am running into now, is that stonehearth doesnt recognize the animalz en.json…

Your en.json does not have that string

stonehearth en.
“pasture”: {
“help”: “Shepherds bring animals to this region and tend to their needs here.”,
“choose_pasture_type”: “Choose Pasture Type”,
“sheep_pasture_name”: “Sheep Pasture”,
“rabbit_pasture_name”: “Rabbit Pen”,
“poyo_pasture_name”: “Poyo Coop”,
“sheep_pasture_description”: “Sheep produce wool, used by the weaver. Slaughtering sheep will produce mutton, a raw cooking ingredient”,
“rabbit_pasture_description”: “Rabbits reproduce quickly and can be slaughtered for jerky and pelts”,
“poyo_pasture_description”: “Poyos produce eggs, a valuable cooking ingredient. Slaughtering poyo will yield meat and, occasionally, feathers for crafting”,
“num_animals”: “Animals:”
},

my en

“pasture”: {
“alpaca_pasture_name”: “Alpaca Pasture”,
“alpaca_pasture_description”: “Alpaca produce wool, used by the weaver. Slaughtering alpaca will produce mutton, a raw cooking ingredient”
},

Yes, but you are pointing to “ui:game:zones…” and you do not have that in your en.json

Should i point at “stonehearth:ui:game:zones…” or put the ui:gama:zones in my en file?

If your i18n() is aimed at stonehearth, then it will look there, if you aimed it at your own mod (i18n(animalz:…)) then it will look at your mod.

now its working, only thing not loading is the icon. anything wrong with my pathing?

“icon”: “animalz/entities/critters/alpaca/alpaca.png”,

Sorry, should have posted the full code…

{
“components”: {
“stonehearth:shepherd_pasture”: {
“pasture_data”: {
“animalz:alpaca”: {
“name”: “i18n(animalz:ui.game.zones_mode.pasture.alpaca_pasture_name)”,
“description”: “i18n(animalz:ui.game.zones_mode.pasture.alpaca_pasture_description)”,
“icon”: “animalz/entities/critters/alpaca/alpaca.png”,
“min_population”: 2,
“reproduction_uri”: “animalz:alpaca:young”,
“max_num_per_10_square_unit”: 0.48,
“base_reproduction_period”: “36h”,
“min_reproduction_period”: “12h”,
“feed_uri”: “animalz:food:alpaca_feed”
}
}
}
}
}

Try enclosing it in the file() function:

“icon”: “file(animalz/entities/critters/alpaca/alpaca.png)”

1 Like

Didnt work ;s

i used now “icon”: “file(/entities/critters/alpaca/alpaca.png)”, and it works!

Thank you all!

ok… i am not sure, maybe from the beginning. But i just notice that now the alpaca is not showing the name wtf i was before… and o over saved the backups because i thought i was all good now… and i was doing other things when i noticed… any clue?

{
“ui”: {
“game”: {

		"zones_mode": {
			"pasture": {
				"alpaca_pasture_name": "Alpaca Pasture",
				"alpaca_pasture_description": "Alpaca produce wool, used by the weaver. Slaughtering alpaca will produce mutton, a raw cooking ingredient",





				"entities": {
					"critters": {
						"alpaca": {
							"display_name": "A alpaca",
							"description": "So fluffy!",
							"unripe_description": "This alpaca is still quite naked.",
							"alpaca_young": {
								"display_name": "A alpacaquita",
								"description": "Awww!"
							},

							"renewable_harvest_status_text": "shearing alpaca",
							"species": "alpaca"
						}
					}
				}
			}
		}
	}
}

}

Probably because in en.json your entities is now inside the pasture while you didn’t update your entity i18n to reflect that change.