Changes to Item Binding

Allows event to cancel the binding (rather than set key to "" which had
the same effect but was messy)

Prevents binding by Fake Players
This commit is contained in:
hilburn 2015-01-31 23:37:17 +00:00
parent aa33b6b8ff
commit 976599afe0
50 changed files with 152 additions and 268 deletions

View file

@ -184,9 +184,10 @@ public class EnergyItems extends Item implements IBindable
}
//Global static methods
public static void checkAndSetItemOwner(ItemStack item, EntityPlayer player)
public static boolean checkAndSetItemOwner(ItemStack item, EntityPlayer player)
{
SoulNetworkHandler.checkAndSetItemOwner(item, player);
if (SpellHelper.isFakePlayer(player)) return false;
return SoulNetworkHandler.checkAndSetItemOwner(item, player);
}
public static void setItemOwner(ItemStack item, String ownerName)