Crops Help

Started by The_Nexus300 on

Topic category: Help with Minecraft modding (Java Edition)

Joined Jul 2016
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Crops Help
Fri, 04/10/2026 - 17:40 (edited)

Hey so im having trouble trying to make crops accurate to the rest of the game. So far its been going pretty well using integer properties and blockstates. My issues start at Harvesting using either a loottable together with a "Harvest condition" procedure, or a "when block is destroyed by player" procedure. Neither option seems to yield the behaviour im looking for. 

 

When using a loot table, it completely seems to ignore the Harvest condition when the crop is destroyed via the environment i.e water, or the block underneath it being broken ect..., leading to it granting the full loot as if it were fully grown, regardless of how old the crop actually was. 

 

When using the "when block is destroyed by player" procedure, it obviously only gets called when destroyed by the player specifically, so your usual vanilla farms that get mass harvested with water systems wouldnt work on my crop at all, destroying them with granting anything.

 

I was wondering if anyone could help me figure out a method to achieve all the behaviours im looking for, either through plugins or whatever :)

Edited by The_Nexus300 on Fri, 04/10/2026 - 17:40
Hmm, you may need to code…
Sat, 04/11/2026 - 15:49

Hmm, you may need to code custom loot table.

I though we had general block broken trigger. Maybe there is a global one?

Joined Jul 2016
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Thanks for the reply :) So i…
Sat, 04/11/2026 - 20:42

Thanks for the reply :) 

So i definitely couldnt find a general block broken trigger. But i did find the global one. It worked when the player breaks the crop, but for whatever reason it also doesnt seem to call the procedure when broken by the environment like, water or invalid placement.

Im willing to code my custom loot table, so im off to youtube to find some tutorials haha