EMI

EMI

1M Downloads

Expose a way to get the modname component for custom EmiStacks

pupnewfster opened this issue · 4 comments

commented

In Mekanism I have chemicals which are relatively similar to fluids, but from what I can tell at least in 1.1.3+1.20.4, there is no way to do the corresponding code for getting the mod name and more importantly a way to check if the Emi config is set to add the mod name. Would it be possible to either expose this functionality and check via EmiTooltipComponents or as part of the super EmiStack#getTooltip?

commented

I'm pretty surprised this functionality does not exist. Though, in general, custom stack types are not the road most traveled...

This should be relatively easy to address, I imagine a method in EmiTooltipComponents that takes a list of components and a namespace and handles the config checking and appending (future proofing for mod name customization options).

commented

That sounds like it would work great! And yeah I can tell custom stack types are likely not that common. I still need to look further into and potentially end up opening another issue for custom types that support tags. As it seems the tag ingredient isn't quite extensible, but I haven't looked enough yet if a custom variant/separate ingredient can recreate all the functionality for it or what would be the best way to extend it.

commented

Yeah, tags are currently quite hardcoded to only fluids and items, but since there are at least 2, there are some expansion routes to allow developers to specify the necessary information EMI needs to handle tags of other types. (This is the first case of a mod actually having a use case for it). You're right that that would be better suited as another issue though.

commented

Implemented in EMI 1.1.4 along with mostly bugfixes, bigger feature additions will be next.