[Suggestion] New tweak: Drag item to another slot
AlisonHuang777 opened this issue ยท 8 comments
Suppose I want to move an item from slot A to slot B.
Currently, I can do the following:
- Click the item located in slot A
- Move the cursor to where the slot B is
- Click again to drop the item
And the new tweak works like this:
- Click the item at slot A and then hold the button
- Move the cursor to slot B
- Release button to drop the item
So basically I can drag the item to another slot with this new tweak.
This can be useful when I want to move many items to some specific slots.
I see what you mean. Do any existing mods do this to use as a reference for the button to use? I think it makes sense if this was some modifier (i.e. if you hold Alt then dragging works like this), but not sure.
I think we actually don't need to press any additional keys to activate the dragging behavior. It'll work like this:
Firstly, you press down RMB (or LMB) on an item to pick it up, and then, when you release the button:
- If the cursor is still on the slot where you originally picked up the item, this is identified as a "click" action, and you simply make the item attach to the cursor;
- If, instead, the cursor has moved to a new slot, then this is identified as a "drag" action, putting down the item (which is previously attached to the cursor until the button is released) to that slot.
That is a good idea, however I think there's a conflict with one of the existing LMB drag mechanics where it will add more items into the stack on the mouse when dragging with LMB held.
Maybe we can make this feature to be part of the RMB tweaks instead?
And make the existing tweak for RMB to be activated only if it's a "click" action, e.g. you need to make the item to attach to the cursor first, and then you can do the distribution.
Well, you still want the vanilla "right click to take half" to keep working though.
How about using middle mouse button? Currently there is no behavior for middle clicking a item in survival mode.
And using this tweak won't be a issue in creative mode, as you can use the "click" action to activate the vanilla behavior (which is duping item). Maybe an additional config option can be introduced to decide whether to dupe the item when the dragging behavior is activated. (So if it's activated, you just leave the original item in its slot while dragging a copy of it to a new slot.)
Furthermore, if there are other mod that take use of MMB, (e.g. AE2 autocrafting,) just bind it to "click" action as well.
Possible. If it was a modifier like Alt, then you could use it with both LMB and RMB though (if you need to take a half-stack and drop it somewhere).