RPGStats icon indicating copy to clipboard operation
RPGStats copied to clipboard

Compat with Harvest with Ease [1.19]

Open KiichigoUsagi opened this issue 3 years ago • 5 comments

Right-click Harvest with Harvest with Ease (https://www.curseforge.com/minecraft/mc-mods/harvest-with-ease) does not grant XP.

i looked into past issues and Simpler Harvest does not exist for 1.19.2 so that's not an option. plus harvest with ease allows for tweaking like fortune effect when harvesting with hoes and dynamic compat with modded crops that may not be immediately compatible via config.

is there any chance for some compatibility to be added for that mod?

KiichigoUsagi avatar Oct 24 '22 19:10 KiichigoUsagi

Simple harvest works fine on modern versions, I can try adding support though

SilverAndro avatar Oct 24 '22 20:10 SilverAndro

Hmm, I wonder if it works with my mod, RightClickHarvest @ https://modrinth.com/mod/rightclickharvest

Jamalam360 avatar Oct 30 '22 13:10 Jamalam360

Looks like no from a quick glance, you set the block state directly

SilverAndro avatar Oct 30 '22 22:10 SilverAndro

Does RPG stats provide an API or anything for other mods 👀

Jamalam360 avatar Oct 31 '22 11:10 Jamalam360

Technically yes https://github.com/SilverAndro/RPGStats/wiki/API

Its being expanded and rewritten partially with the quilt/kotlin rewrite though

SilverAndro avatar Oct 31 '22 15:10 SilverAndro

Yeah the 1.18.2 versions do not have compat when i tested them, hope support comes in soon!

ConqAra avatar Nov 12 '22 04:11 ConqAra

I think it'd be better if you added a mixin to allow compatibility with Harvest with ease.
I suggest to inject at the head or tail of UseBlockHandler#grantExp(PlayerEntity) and there grant the XP for your mod. This method is available for all supported Minecraft versions, gets called server side only and only if a crop is mature, so it should respect your criteria for giving Farming XP.

Btw I noticed that in your code you give Farming XP also for not-mature cocoa beans, is it intended? Also I noticed that no Farming XP is given for nether warts and sugar canes, is this intended too?

Crystal-Spider avatar Nov 12 '22 09:11 Crystal-Spider

I've added compatibility for RightClickHarvest as well now, I used rpgstats own behaviour of not giving xp for sugar cane etc., did think it was weird though

Jamalam360 avatar Nov 12 '22 10:11 Jamalam360

@SilverAndro any update on this?

Crystal-Spider avatar Nov 18 '22 22:11 Crystal-Spider

Yeah uh, I have no laptop atm!

Will tackle this eventually

SilverAndro avatar Nov 18 '22 22:11 SilverAndro

Has this been addressed yet?

TheeMrCheeky avatar Jan 02 '23 00:01 TheeMrCheeky

Was busy with 5.0.0 so no

Ill look into it later

SilverAndro avatar Jan 02 '23 00:01 SilverAndro

all good. was just checking! :) ty

TheeMrCheeky avatar Jan 02 '23 00:01 TheeMrCheeky

added in 5.0.2

SilverAndro avatar Jan 05 '23 19:01 SilverAndro