I'm trying to make it so that when a player strips a log, a "Bark" item is placed in their inventory (or, preferably, dropped on the ground). I know mods exist for this, but they add bark of every type, and often lack compatibility.
Here's what I'm trying to make work:
if (event.player.getMainHandItem.hasTag("forge:tools/axes))
event.player.give('kubejs:tree_bark')
else
return
})```
I made one iteration work where I had to explicitly specific acacia log and stone axe, and then foolishly didn't save it, so I don't even know how to make *that* work again.