Hello @GtX-Andy ,
I love the Butcher shop using your lua and have been trying for weeks to get it to work with Realistic Livestock using its animal weight and the genetics for meat production from said mod. This is what I had in mind.
You should be able to access the weight using (animalObject).weight
-- Meat yield % for each type
local MEAT_YIELDS = {
[AnimalSubType.COW] = 0.60, -- 60% of live weight
[AnimalSubType.PIG] = 0.70, -- 70% of live weight
[AnimalSubType.SHEEP] = 0.50, -- 50% of live weight
[AnimalSubType.CHICKEN] = 0.45, -- 45% of live weight
If the Gentics for quality are good, the values increase 5%, if Great, the values go up 8% and if excellent, the values go up 10%!
Is it also possible to have the mod check to see if the mod (Realistic Livestock) is loaded, and then implement this function? If the mod is not being used, it defaults back to its current setup!
I hope to hear from you soon, and please let me know if I can help
Hello @GtX-Andy ,
I love the Butcher shop using your lua and have been trying for weeks to get it to work with Realistic Livestock using its animal weight and the genetics for meat production from said mod. This is what I had in mind.
You should be able to access the weight using (animalObject).weight
-- Meat yield % for each type
local MEAT_YIELDS = {
[AnimalSubType.COW] = 0.60, -- 60% of live weight
[AnimalSubType.PIG] = 0.70, -- 70% of live weight
[AnimalSubType.SHEEP] = 0.50, -- 50% of live weight
[AnimalSubType.CHICKEN] = 0.45, -- 45% of live weight
If the Gentics for quality are good, the values increase 5%, if Great, the values go up 8% and if excellent, the values go up 10%!
Is it also possible to have the mod check to see if the mod (Realistic Livestock) is loaded, and then implement this function? If the mod is not being used, it defaults back to its current setup!
I hope to hear from you soon, and please let me know if I can help