mirror of
https://github.com/Minestom/Minestom.git
synced 2024-12-30 13:08:19 +01:00
InventoryItemChangeEvent is now recursive and not it's PlayerInventory-based child
This commit is contained in:
parent
8f277cdb17
commit
2634042f7d
@ -1,6 +1,7 @@
|
||||
package net.minestom.server.event.inventory;
|
||||
|
||||
import net.minestom.server.event.trait.InventoryEvent;
|
||||
import net.minestom.server.event.trait.RecursiveEvent;
|
||||
import net.minestom.server.inventory.AbstractInventory;
|
||||
import net.minestom.server.inventory.Inventory;
|
||||
import net.minestom.server.item.ItemStack;
|
||||
@ -14,7 +15,7 @@ import org.jetbrains.annotations.Nullable;
|
||||
* @see PlayerInventoryItemChangeEvent
|
||||
*/
|
||||
@SuppressWarnings("JavadocReference")
|
||||
public class InventoryItemChangeEvent implements InventoryEvent {
|
||||
public class InventoryItemChangeEvent implements InventoryEvent, RecursiveEvent {
|
||||
|
||||
private final Inventory inventory;
|
||||
private final int slot;
|
||||
|
@ -2,7 +2,6 @@ package net.minestom.server.event.inventory;
|
||||
|
||||
import net.minestom.server.entity.Player;
|
||||
import net.minestom.server.event.trait.PlayerEvent;
|
||||
import net.minestom.server.event.trait.RecursiveEvent;
|
||||
import net.minestom.server.inventory.AbstractInventory;
|
||||
import net.minestom.server.inventory.PlayerInventory;
|
||||
import net.minestom.server.item.ItemStack;
|
||||
@ -16,7 +15,7 @@ import org.jetbrains.annotations.NotNull;
|
||||
* listen only for an ancestor event and check whether it is an instance of that class.
|
||||
*/
|
||||
@SuppressWarnings("JavadocReference")
|
||||
public class PlayerInventoryItemChangeEvent extends InventoryItemChangeEvent implements PlayerEvent, RecursiveEvent {
|
||||
public class PlayerInventoryItemChangeEvent extends InventoryItemChangeEvent implements PlayerEvent {
|
||||
|
||||
private final Player player;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user