mirror of
https://github.com/Zrips/Jobs.git
synced 2024-11-26 04:25:15 +01:00
Check for player instance on armorstand break
This commit is contained in:
parent
a88e733851
commit
6817ea0287
@ -1045,9 +1045,11 @@ public class JobsPaymentListener implements Listener {
|
||||
EntityDamageByEntityEvent e = (EntityDamageByEntityEvent) event.getEntity().getLastDamageCause();
|
||||
|
||||
//extra check for Citizens 2 sentry kills
|
||||
if (e.getDamager() instanceof Player)
|
||||
if (e.getDamager().hasMetadata("NPC"))
|
||||
return;
|
||||
if (!(e.getDamager() instanceof Player))
|
||||
return;
|
||||
|
||||
if (e.getDamager().hasMetadata("NPC"))
|
||||
return;
|
||||
|
||||
Player pDamager = (Player) e.getDamager();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user