-
Notifications
You must be signed in to change notification settings - Fork 1
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
[Bug] GUI items Can be Moved and Removed (#2 returns) #8
Comments
In the InventoryGui class we can see the event is cancelled ((here)) I'm really not sure what is causing this. Are the items the user moves ghost items when they exit the gui? If so that is even more strange. |
having looked at the code there i think the cancel click event is being called to early, from my understanding of that code its being called and canceled when the gui is opened. instead it should be called during the onClick() event of an opened gui. example: add the cansel event click at the beginning of this then do ur custom click event code after. this might be where this bug is arising from. |
In the This is only called when a player clicks it. |
Checking over your code the only place that I can see where "i.onClick(this::onClickCancel);" is two functions:
public void open(Player player)
public void openSync(Player player) {
Both of thease only handle the opening of the GUI Interface, and do not conver any GUI interaction events sutch as (onClick) event. |
ServerGUI: 2.0
Protocolize: 2.2.2:374
Velocity: 3.5.1
Using the versions labled above I've noticed bug report #2 has reared its head once again.
Items when clicked in the GUI can be picked up moved around and placed in to the players own inventory.
I beleive this is because the origional inventory "onClick" event is not being canceled.
The text was updated successfully, but these errors were encountered: