Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inventory: Quickly picking up item and placing it again no longer works #14233

Closed
Wuzzy2 opened this issue Jan 8, 2024 · 10 comments · Fixed by #14657
Closed

Inventory: Quickly picking up item and placing it again no longer works #14233

Wuzzy2 opened this issue Jan 8, 2024 · 10 comments · Fixed by #14657
Labels
Bug Issues that were confirmed to be a bug @ Client / Controls / Input Regression Something that used to work no longer does.
Milestone

Comments

@Wuzzy2
Copy link
Contributor

Wuzzy2 commented Jan 8, 2024

Minetest version

5.8.0

Active renderer

No response

Irrlicht device

No response

Operating system and version

GNU/Linux

CPU model

No response

GPU model

No response

OpenGL version

No response

Summary

If you click on an item stack in the inventory and click again, sometimes you only pick up the item stack but won't place it back.

This is a regression because previously, this would have placed back the item.

I think this bug might have been caused with the new inventory shortcuts added to 5.8.0. Specifically, there is a new feature that will put all the items of the same kind in the inventory towards your cursor if you doubleclick it. Normally, this is very useful but what if the item you doubleclicked was the only one in the inventory? Then your item stack does not change and you do not put it back as well (which you would expect).

This is very irritating because the player will think that clicking in the inventory is sometimes broken. I think the proper bugfix would be to always put the item back after a double click it this no additional item was added to the cursor.

@OgelGames

Steps to reproduce

  1. Empty the inventory
  2. Put one item inside inventory
  3. Move the cursor over this item and make sure it's over the slot, too
  4. Quickly click two times on the single item, make sure the cursor remains on the slot

Expected behavior: You quickly pick up the item stack with the first click and place it back with the 2nd click.
Actual behavior: You only pick up the item stack, so it appears to the player that clicking in the inventory is sometimes randomly broken.

@Wuzzy2 Wuzzy2 added the Unconfirmed bug Bug report that has not been confirmed to exist/be reproducible label Jan 8, 2024
@sfan5 sfan5 added the Regression Something that used to work no longer does. label Jan 9, 2024
@grorp
Copy link
Member

grorp commented Jan 27, 2024

I can reproduce this bug, and I can confirm that it's indeed a regression from 252c79d / #13146.

I think the proper bugfix would be to always put the item back after a double click it this if no additional item was added to the cursor.

Did you mean this?

@grorp grorp added Bug Issues that were confirmed to be a bug and removed Unconfirmed bug Bug report that has not been confirmed to exist/be reproducible labels Jan 27, 2024
@grorp grorp added this to the 5.9.0 milestone Jan 27, 2024
@Wuzzy2
Copy link
Contributor Author

Wuzzy2 commented Jan 27, 2024

Yes, grorp. Oops.

@sfan5
Copy link
Member

sfan5 commented Feb 16, 2024

@OgelGames any chance you could look at this?

@OgelGames
Copy link
Contributor

OgelGames commented Feb 17, 2024

I don't get what the issue is, clicking twice quickly is double-clicking, so it activates the pick-up-all shortcut. The shortcut behavior shouldn't change depending on how many items there are, that's like expecting Ctrl+A to not select anything when there is only one thing to be selected.

@OgelGames
Copy link
Contributor

OgelGames commented Feb 17, 2024

I just checked and the double-click speed/delay setting in your OS does effect this, reducing the delay should fix it. (note that you need to restart Minetest when you change it)

@Wuzzy2
Copy link
Contributor Author

Wuzzy2 commented Feb 19, 2024

This is a design flaw then. It is extremely irritating to me that if you pick up a single item, and want to put it back immediately again (maybe because of a misclick), it no longer works.

If this is the intended behavior, I argue the intention is flawed. The problem is that sometimes, clicking with a single item on an empty slot will NOT work. The problem that even if this behavior is intentional, it feels like a bug.

Also, why is the OS-level setting relevant at all here? If I just reduce the double-click speed, then I also lose the "pick up all" feature.

@OgelGames
Copy link
Contributor

There is no bug, either you click slow enough for two separate clicks, or you click fast enough for a double-click. The OS setting is relevant because that is what determines the point at which two clicks are counted as a double-click.

See here, it does work:

2024-02-19.23-00-39.mp4

@grorp
Copy link
Member

grorp commented Feb 19, 2024

I think it would make sense to ignore the double-click and just allow putting the item back when the double-click doesn't pick up any additional items.

The problem here (or the bug, whatever) is that the double-click doesn't do anything visible to the user in some cases, but it still prevents putting the item back. While this might make sense if you know why it happens, the unknowing user will think they can't put the item back for no reason at all.

See here, it does work

In your video, you didn't show the described problem case (no items left to pick up by double-click, quickly picking up item and trying to put it back).

@Wuzzy2
Copy link
Contributor Author

Wuzzy2 commented Feb 20, 2024

@OgelGames: You did it wrong. Please follow the exact steps to reproduce. The inventory must be emptied first. Don't add new items.

@OgelGames
Copy link
Contributor

2024-02-20.19-03-26.mp4

Still works fine ¯\_(ツ)_/¯

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Issues that were confirmed to be a bug @ Client / Controls / Input Regression Something that used to work no longer does.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants