How to add leaves as drops to existing tree crops with Zen Script (Botany Trees 1.16.4)
jengendler opened this issue ยท 5 comments
I would like to add leaves as drops for tree sapling crops with Botany Trees. I am using Zen Script for all of my additions, and wondered if it's possible to add drops to an existing crop that's already coded into the mod like a Spruce Sapling crop without recreating it entirely. I couldn't figure out how to target the crop id in Zen Script, as I don't know if one exists or if I have to create one. Is there a way to target a pre-existing crop (obtain the crop id) to add drops, or do I have to create an entirely new crop for each sapling in Zen Script? Much help appreciated!
Hi, jengendler... I've been trying to do the same thing and other stuff also with Zen and CraftTweaker with no success, apparently I'm using the wrong id's (but don't know which ones are valid). So, did a work around using ExNihilo Sequentia Barrel (FluidBlockTransormRegistry.json file) until leave drops come in with botany. Added the following:
{
"fluid": "minecraft:water",
"input": "minecraft:acacia_sapling",
"result": "minecraft:acacia_leaves"
},
did this for each of the 6 MineCraft saplings to leaves (it will also work any mod).
I agree with ya, the ability to add leave drops with botany is a plus without using additional Zen/json.
Thank you for sharing. That mod sounds like a nice workaround that is more similar to Botany Trees than the one I'm using. I'm currently using the market block from Farming for Blockheads, where I've added a custom trade for a set of each leaf type in exchange for coins (from Coins JE mod). I could easily use saplings for the trade instead, but coins (or even emeralds) feels more fitting for the trading type mod.
I'll consider the Sequential Barrel mod, but to prevent installing additional mods, I'm a bit more inclined to code custom sapling crops with all the outputs I want in Botany Trees (such as leaves, apples, etc.) Hopefully, the creator can share the sapling crop IDs so I can add individual drops instead of recreate entire crops! And hopefully one day, all vanilla tree drops will be added to the mod in the future.
All the CraftTweaker/ZenScript information is documented on this wiki page. In the future I will look into adding this as a config option.
import mods.botanypots.ZenCrop;
import mods.botanypots.Crops;
val crops = <recipetype:botanypots:crop>;
val acacia = crops.getCrop("botanytrees:botanytrees/acacia");
acacia.addDrop(<item:minecraft:acacia_leaves>, 0.05, 1, 1);
val birch = crops.getCrop("botanytrees:botanytrees/birch");
birch.addDrop(<item:minecraft:birch_leaves>, 0.05, 1, 1);
val dark_oak = crops.getCrop("botanytrees:botanytrees/dark_oak");
dark_oak.addDrop(<item:minecraft:dark_oak_leaves>, 0.05, 1, 1);
val jungle = crops.getCrop("botanytrees:botanytrees/jungle");
jungle.addDrop(<item:minecraft:jungle_leaves>, 0.05, 1, 1);
val oak = crops.getCrop("botanytrees:botanytrees/oak");
oak.addDrop(<item:minecraft:oak_leaves>, 0.05, 1, 1);
val spruce = crops.getCrop("botanytrees:botanytrees/spruce");
spruce.addDrop(<item:minecraft:spruce_leaves>, 0.05, 1, 1);