AnvilGUI
AnvilGUI copied to clipboard
builder.onClose get reason.
I need to find out why the player closed the inventory, but there is no corresponding method, as in the InventoryCloseEvent event::getReason
As for now, this is not possible. To make this work, I think we need to pass the underlying InventoryCloseEvent to the onClose method, either in the stateSnapshot or as a new, optional parameter. We can't work with the Reason (as in just passing the Reason instead of the Event) since it seems to be a Paper only method.