DarkPacks / SevTech-Ages

SevTech: Ages is a massive Minecraft modpack packed with content and progression.
https://minecraft.curseforge.com/projects/sevtech-ages
GNU General Public License v3.0
229 stars 79 forks source link

Galacticraft Slimeling eats wooden hoes #4851

Open AdamkiX opened 9 months ago

AdamkiX commented 9 months ago

I've decompiled GC slimeling .class file and editted code in such way that it removes wooden hoe from feed item pool. Idk if it is allowed to post edited version of mod here, so I am just informing you about fix. Afterwards I can eventually post EntitySlimeling.class file where mentioned changes were made.

github-actions[bot] commented 9 months ago

@AdamkiX: hello! :wave:

This issue is being automatically closed because it does not follow the issue template.

sam-kirby commented 9 months ago

I don't follow; what is the issue with slimelings? I don't recall one being posted previously.

It's unlikely we can use an edited mod, but it's possible to modify Java bytecode at runtime; the mod https://github.com/DarkPacks/SevPatches is our collection of fixes for other people's mods. You could make a PR there to incorporate your change or you could describe what you've changed in more detail and I'll write the patch.

AdamkiX commented 8 months ago

SevTech disables wooden hoes and because of that you can't feed slimelings (when wooden hoe rolls from feed item pool). I found one report from years ago, but it was closed and never fixed: https://github.com/DarkPacks/SevTech-Ages/issues/2066 About fix: I've decompiled EntitySlimeling.class file with dirtyJOE program. Afterwards I edited method setRandomFavFood in such way that switch case is limited to 9 possible cases then switched wooden hoe (field_151017_I ) with boat (field_151124_az). I will post screenshot of commited changes so you could get some feedback. obraz code

Also I've tested random function in test world and it never rolled hoe (everything else was), so I assume that my fix works.

sam-kirby commented 8 months ago

I've released a new version of SevPatches that will resolve this issue at runtime; if you add this to your modpack with an unpatched version of GC the slimelings will have prismarine shards added to their diet instead of wooden hoes.

https://github.com/DarkPacks/SevPatches/releases/tag/1.12.0

AdamkiX commented 8 months ago

Ok. I'll try it out. Thanks :)