mirror of
https://github.com/YouHaveTrouble/PreventStabby.git
synced 2026-05-11 21:06:55 +00:00
some docs to explain things
This commit is contained in:
@@ -9,6 +9,10 @@ import org.bukkit.event.Listener;
|
||||
|
||||
public class WolfAttackPlayerListener implements Listener {
|
||||
|
||||
/**
|
||||
* Wolves stop following player with pvp off after trying to hit them
|
||||
* This is to fix any inconsistancy with wolf behaviour
|
||||
*/
|
||||
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)
|
||||
public void onWolfAttack(org.bukkit.event.entity.EntityDamageByEntityEvent event) {
|
||||
if (event.getDamager() instanceof Wolf) {
|
||||
|
||||
@@ -10,6 +10,9 @@ import org.bukkit.event.Listener;
|
||||
|
||||
public class WolfTargettingListener implements Listener {
|
||||
|
||||
/**
|
||||
* Stops wolves with owners targetting players with pvp off
|
||||
*/
|
||||
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)
|
||||
public void onWolfTarget(org.bukkit.event.entity.EntityTargetEvent event) {
|
||||
if (event.getEntity() instanceof Wolf) {
|
||||
|
||||
Reference in New Issue
Block a user