mirror of
https://github.com/AtlasMediaGroup/TotalFreedomMod.git
synced 2024-11-27 01:05:38 +00:00
parent
7940313dd1
commit
56d5a669cf
@ -7,6 +7,7 @@ import org.bukkit.GameMode;
|
|||||||
import org.bukkit.entity.Arrow;
|
import org.bukkit.entity.Arrow;
|
||||||
import org.bukkit.entity.Player;
|
import org.bukkit.entity.Player;
|
||||||
import org.bukkit.entity.Trident;
|
import org.bukkit.entity.Trident;
|
||||||
|
import org.bukkit.entity.FishHook;
|
||||||
import org.bukkit.event.EventHandler;
|
import org.bukkit.event.EventHandler;
|
||||||
import org.bukkit.event.EventPriority;
|
import org.bukkit.event.EventPriority;
|
||||||
import org.bukkit.event.entity.EntityDamageByEntityEvent;
|
import org.bukkit.event.entity.EntityDamageByEntityEvent;
|
||||||
@ -57,6 +58,14 @@ public class PVPBlocker extends FreedomService
|
|||||||
player = (Player)trident.getShooter();
|
player = (Player)trident.getShooter();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if (event.getDamager() instanceof FishHook)
|
||||||
|
{
|
||||||
|
FishHook fishhook = (FishHook)event.getDamager();
|
||||||
|
if (fishhook.getShooter() instanceof Player)
|
||||||
|
{
|
||||||
|
player = (Player)fishhook.getShooter();
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (player != null & !plugin.al.isAdmin(player))
|
if (player != null & !plugin.al.isAdmin(player))
|
||||||
|
Loading…
Reference in New Issue
Block a user