diff options
Diffstat (limited to 'test-plugin')
-rw-r--r-- | test-plugin/src/main/java/io/papermc/paper/testplugin/TestPlugin.java | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test-plugin/src/main/java/io/papermc/paper/testplugin/TestPlugin.java b/test-plugin/src/main/java/io/papermc/paper/testplugin/TestPlugin.java index a0c78b9d68..45279181cc 100644 --- a/test-plugin/src/main/java/io/papermc/paper/testplugin/TestPlugin.java +++ b/test-plugin/src/main/java/io/papermc/paper/testplugin/TestPlugin.java @@ -1,6 +1,8 @@ package io.papermc.paper.testplugin; +import org.bukkit.event.EventHandler; import org.bukkit.event.Listener; +import org.bukkit.event.player.PlayerItemDamageEvent; import org.bukkit.plugin.java.JavaPlugin; public final class TestPlugin extends JavaPlugin implements Listener { @@ -8,4 +10,9 @@ public final class TestPlugin extends JavaPlugin implements Listener { public void onEnable() { this.getServer().getPluginManager().registerEvents(this, this); } + + @EventHandler + public void a(PlayerItemDamageEvent event) { + System.out.println(event.getOriginalDamage() + " to " + event.getDamage()); + } } |