Farmer's Delight

Farmer's Delight

95M Downloads

[1.16.5] Rich Soil doesn't respect Serene Seasons configuration

Opened this issue ยท 5 comments

commented

If playing with Serene Seasons configured to make crops stop growing entirely when out of season, Rich Soil does not respect this, and will make crops planted on it grow anyway.

commented

Yeah, SS seems to not intercept plant growth every which way you can make them grow. I've asked on their discord to figure out a fix. They might be working on something on their side, or we might have to explicitly check via their API.

EDIT: Well that was quick. Apparently they're not planning on intercepting the specific way Rich Soil is using to enhance crop growth, so it's on us.
As I see it, there's three ways to deal with this:

  • Apply a bone meal effect instead of IGrowable.grow where possible since SS intercepts that
  • Use the SS API to check
  • Disregard SS' restrictions
    I'll leave the decision to vector since this is his mod, and just execute on that.
commented

If I recall correctly, Serene Seasons employs the CropsGrowPre event from Forge, and cancels it if the crop is out of its season. Every CropsBlock and similar make use of that, so Rich Soil could also take it into consideration like a CropsBlock, and it should work.

I'll take a look at it in the future.

commented

You mean fire the event in Rich Soil and grow only if it succeeds? Hadn't considered that, seems the easiest and most compatible way to do it

commented

As it turns out, this really is easy if you're using established mechanisms!

commented

Should be fixed on recent commits, with both Rich Soil blocks respecting crop grow events. Thanks to Foam for being quick on the fix!