Skip to content

Commit

Permalink
Updated mob head drops to respect the antideathchest option
Browse files Browse the repository at this point in the history
  • Loading branch information
meiskam committed Aug 27, 2013
1 parent 6d91ce6 commit 5a3b5fe
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -180,8 +180,13 @@ public void EntityDeathHelper(EntityDeathEvent event, Enum<?> type, Double dropr
if (dropHeadEvent.isCancelled()) {
return;
}

event.getDrops().add(drop);

if (plugin.configFile.getBoolean("antideathchest")) {
Location location = event.getEntity().getLocation();
location.getWorld().dropItemNaturally(location, drop);
} else {
event.getDrops().add(drop);
}
}

@EventHandler(priority = EventPriority.MONITOR)
Expand Down

0 comments on commit 5a3b5fe

Please sign in to comment.