13
0
geforkt von Mirrors/Paper

SPIGOT-4700: Add PlayerFishEvent.State.REEL_IN

By: md_5 <git@md-5.net>
Dieser Commit ist enthalten in:
CraftBukkit/Spigot 2019-04-15 20:42:51 +10:00
Ursprung f890a5eedc
Commit c6d3a7e5c4

Datei anzeigen

@ -105,7 +105,7 @@
}
+ // CraftBukkit start
+ if (i == 0) {
+ PlayerFishEvent playerFishEvent = new PlayerFishEvent((Player) this.owner.getBukkitEntity(), null, (FishHook) this.getBukkitEntity(), PlayerFishEvent.State.FAILED_ATTEMPT);
+ PlayerFishEvent playerFishEvent = new PlayerFishEvent((Player) this.owner.getBukkitEntity(), null, (FishHook) this.getBukkitEntity(), PlayerFishEvent.State.REEL_IN);
+ this.world.getServer().getPluginManager().callEvent(playerFishEvent);
+ if (playerFishEvent.isCancelled()) {
+ return 0;