maruohon / itemscroller

A client-side Minecraft mod that adds various convenient ways of moving items within inventory GUIs, such as scrolling over stacks to move single items to or from it
GNU Lesser General Public License v3.0
147 stars 68 forks source link

[Request] New toggle option enableScrollingShulkerBoxes #106

Open AstudilloMarillo opened 3 months ago

AstudilloMarillo commented 3 months ago

There's a conflict between this mod and the Easy Shulker Boxes mod. In the other mod, it's possible to scroll through and access the items inside of a Shulker Box by hovering over it in the inventory, through a tooltip pop-up. Right now, Itemscroller makes it so the Shulker Box gets moved instead when scrolling over it.

If there was an option to disable scrolling specifically for Shulker Boxes, this would be fixed. It could be named something like enableScrollingShulkerBoxes and be 'true' by default, so only people who really need it can put it to 'false'. I wouldn't mind not being able to use the scrolling feature of ItemScroller on Shulker Boxes as I don't really use it on non-stackable items anyway.

A different method would be to be able to make a custom item blacklist. I've seen other issues (from 2017) suggesting that it's possible to add items to a blacklist? I've been unable to replicate this.

maruohon commented 3 months ago

The entire mod is supposed to get a complete (code) rewrite going forward. As part of that I will probably add various white-/blacklist options for some features. This could be part of that, so a white-/blacklist for any item scrolling based on the item type.

AstudilloMarillo commented 3 months ago

The entire mod is supposed to get a complete (code) rewrite going forward. As part of that I will probably add various white-/blacklist options for some features. This could be part of that, so a white-/blacklist for any item scrolling based on the item type.

That would definitely be a solution for this situation. If I may ask, will it be in the next update? Or will it be a while?

maruohon commented 3 months ago

Unfortunately I can't give any kind of ETA. But if it happens as part of the mod rewrite, then it won't be in the next updates yet, but at some point later, when the actual big updates of all my client mods would happen. And the big problem for those actually happening at some point at all is that I've put very little if any time into modding lately...

So it's possible I might just add the black-/whitelist option to the current old code base for one of the next updates, as otherwise it could be from several months to several years before the bigger updates happen, if ever. But at this point I can't really say one way or the other. Basically just don't hold your breath, unfortunately.

AstudilloMarillo commented 3 months ago

In that case, I'll take my chance and ask if you're willing to make a temporary solution by adding the option like I originally suggested to the toggle menu, as enableScrollingShulkerBoxes (true/false)? If not, that's perfectly fine, just thought I'd ask :).

I appreciate all the time you already put into this great mod and sharing it with us all.

Fuzss commented 3 months ago

@maruohon It would already be enough for Easy Shulker Boxes to work properly if you could use the screen events provided by Fabric Api for things like detecting mouse scrolling. Easy Shulker Boxes uses those events with a high priority, so the shulker box scrolling behavior would take precedence.

maruohon commented 3 months ago

@Fuzss Okay, I'll have to take a look at maybe changing my input hooks to use the Fabric API then, at least partially.

Fuzss commented 3 months ago

Specifically ScreenMouseEvents::allowMouseScroll is the one I use, I already made a test mod with the item scrolling behavior, running at the default Fabric event phase and it allows Easy Shulker Boxes to work as expected.