Thanks a lot.
Been having some issues. Took some time but I think I got it figured out.
In data-final-fixes, the recipes for blacklisted items are not showing up. In one of my mods, I set this mod as an optional dependency and enabled the added items as shown here. (I wasn't sure how to fix your mod to do this.) Also note that for cliff-explosives to be enabled, explosives need to be enabled for everyone.
if mods ["peaceful-plus"] and mods ["Bio_Industries"]
then
data.raw.technology["explosives"].prerequisites =
{
"automation"
}
data.raw.recipe['explosives'].enabled = true
data.raw.recipe['explosives'].hidden = false
data.raw.recipe['grenade'].enabled = true
data.raw.recipe['grenade'].hidden = false
data.raw.recipe['rocket'].enabled = true
data.raw.recipe['rocket'].hidden = false
data.raw.recipe['rocket-launcher'].enabled = true
data.raw.recipe['rocket-launcher'].hidden = false
end
In control.lua I added rocket, rocket-launcher and the seed bombs to the clear_ammo functions as shown below.
-- in clear_ammo function around line 31
if slot.valid_for_read
then
if slot.name ~= 'gun-nano-emitter' and slot.name ~= 'ammo-nano-constructors' and slot.name ~= 'ammo-nano-termites'
and slot.name ~= 'rocket-launcher' and slot.name ~= 'rocket' and slot.name ~= 'bi-seed-bomb-basic'
and slot.name ~= 'bi-seed-bomb-standard' and slot.name ~= 'bi-seed-bomb-advanced'
then
slot.clear()
end
end
Back in the data-final-fixes file, around line 61, I added rocket-launcher to the if statement.
And in the ammo section, around line 68, I added rocket to the if statement.
Somewhere in my code, I added the following. (I am not sure if you had already done that or not in your code.)
data.raw.technology["cliff-explosives"].prerequisites =
{
-- remove military
--"military",
"explosives"
}
Also, I wonder if the blacklist items can be placed in a global array in data-final-fixes so that they can be used by control.lua without explicitly adding them in the code of the control.lua file. I think it would be easier to maintain the mod if you only need to update the data-final-fixes file when adding the blacklist items.