Skip to content

Commit

Permalink
Don't allow transferring bound items to other players
Browse files Browse the repository at this point in the history
Yay for functional bound. Sorta.
  • Loading branch information
mcmonkey4eva committed Jan 11, 2015
1 parent 8382ed8 commit ce2eaf0
Showing 1 changed file with 5 additions and 0 deletions.
Expand Up @@ -347,6 +347,11 @@ public void boundInventoryClickEvent(InventoryClickEvent event) {
event.setCancelled(true);
return;
}

if (!((Player)event.getInventory().getHolder()).getName().equalsIgnoreCase(event.getWhoClicked().getName())) {
event.setCancelled(true);
return;
}
}

@EventHandler
Expand Down

0 comments on commit ce2eaf0

Please sign in to comment.