-
Notifications
You must be signed in to change notification settings - Fork 118
Fixed window click logic #484
base: master
Are you sure you want to change the base?
Conversation
|
Initial review (as I can't really test it right now) of the diff indicates a few naming issues and possible organization/approach concerns. I'll look at it in more depth later tonight. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel like this doesn't warrant it's own package, or at least if it does it should have a different name :P
|
< dx> let's start a bounty for the brave soul that fixes window click handling completely |
|
@hkminegod once it's pulled :) |
|
Note: This currently has two issues which I'll fix with others that are probably going to come up.
|
|
This should be ready to be tested now. |
|
@Johni0702 Creative inventories are not correctly handled. |
|
This now calls the CraftItemEvent and the InventoryCreativeEvent as well as handling the later one when it's canceled. |
|
@Johni0702 There is regression from CraftBukkit due to this PR
Please note that many of these regressions may be due to 1.8 and not the code. Please verify that it is a protocol change before saying it's intended. Also I stopped testing after the above list of issues to avoid potentially reporting duplicates. |
Fixed. The Minecraft client sends quite a few redundant updates to the server even if the server already knows of these. Simply comparing the items in the messages with the current known stack and ignoring matches, solves this issue.
Typo :[ Fixed. I'm so sorry. Please tell me I haven't wasted too much of your time.
I did not yet fix this one as it contradicts what is said in #265. If you wish to have it fixed, it should be rather easy to do so.
Fixed. See above
Clicking outside the inventory doesn't call any events afaik. Fixed that. Note that the behavior of the |
26f72f6 to
0be4a18
Compare
|
@Johni0702 Your pull request has not been mergeable for 5 days now. Please resolve the concerns as soon as possible, thanks! |
Adds shift clicking logic Fixed hotbar swapping (number keys) Prevent items from being placed in the wrong slots Fixed double-clicks not taking all items from hotbar Fixed dragging items creating stacks with too many items Handle taking items from crafting result Add creative window clicking
0be4a18 to
8395dc7
Compare
#484 Conflicts: src/main/java/net/glowstone/inventory/GlowInventory.java
|
Wtf lol |
This tries to fix all window click logic.
Related ticket: #1
New features:
GlowCraftingInventory.craft()accordinglyFixes:
Not included in this PR:
CraftingManager.removeItems). Note that this causes your whole inventory to be filled when you shift-click at the output slot of a crafting recipe. This bug will vanish once said method is implemented.itemShiftClickAllowedanditemPlaceAllowedmethods). This PR only implements those for the player inventory (armor slots).Plugin used to test the InventoryClickEvent: WindowClickTest.py (MiniPython)
Edited by turt2live
Related Links: