From 870f476a17bcd50d09f5884d7e834b82ee9ddfae Mon Sep 17 00:00:00 2001 From: virtualWinter Date: Fri, 21 Jul 2023 06:23:04 +0300 Subject: [PATCH] Riot-style HCF changes for better QOL (EquipmentSetEvent) diff --git a/src/main/java/org/bukkit/event/inventory/EquipmentSetEvent.java b/src/main/java/org/bukkit/event/inventory/EquipmentSetEvent.java new file mode 100644 index 00000000..217f79b2 --- /dev/null +++ b/src/main/java/org/bukkit/event/inventory/EquipmentSetEvent.java @@ -0,0 +1,30 @@ +package org.bukkit.event.inventory; + +import org.bukkit.entity.HumanEntity; +import org.bukkit.event.Event; +import org.bukkit.event.HandlerList; +import org.bukkit.inventory.ItemStack; + +import lombok.AllArgsConstructor; +import lombok.Getter; +import lombok.Setter; + +@Getter @Setter @AllArgsConstructor +public class EquipmentSetEvent extends Event { + + private static final HandlerList handlers = new HandlerList(); + + private final HumanEntity humanEntity; + private final int slot; + private final ItemStack previousItem; + private final ItemStack newItem; + + public static HandlerList getHandlerList() { + return handlers; + } + + @Override + public HandlerList getHandlers() { + return handlers; + } +} \ No newline at end of file -- 2.41.0.windows.1