TinkerStages

TinkerStages

7M Downloads

Request JEI Integration

NielsPilgaard opened this issue ยท 6 comments

commented

Hey o/
I'd like to request a feature to hide tool parts made with certain materials, aswell as something to hide tools, until you reach the stage they're in.

I was imagining something like
mods.TinkerStages.addMaterialStage(stage, material, hideInJEI);
mods.TinkerStages.addMaterialStage("stage_one", "endstone", true);

What do you think? :)

commented

Item hiding in JEI is very annoying to code, and actually pretty costly in terms of time it takes to run. I will think about adding this in, however I don't know if I will.

commented

No worries, if it's a pain to make I'll just use a CraftTweaker function.

commented

There is ItemStages which allows you to stage items in JEI. I wrote that mod as well. The big issue with it is that it is a bit laggy to hide lots of items in JEI. I could copy that code over here pretty easily, but I don't know just how big of a performance hit it would have, if the sorting list was being manipulated twice instead of once.

commented

I did end up using ItemStages, thanks - here's the function if you're curious:
https://gist.github.com/NillerMedDild/a1d3d84f190b7334df93bae450f8f46d
I imagine my implementation isn't great performance wise, but I can live with that to be honest :)

I can do some testing to see just how much additional time hiding materials in this way takes, if you'd like?

commented

About 9ms to hide 4 materials and everything made from them, not too bad at all. Meassured with another one of your mods, Caliper.

Thank you for all your contributions to modded Minecraft :)

commented

Your implementation is probably going to be the most performant way to do it. Will probably be under 250ms.