Rewrite Binding system to be fully automated

No more manual handling of binding items to players. Retains all previous functionality.

I have tested on both the Client and Server and it seems to work just fine. If any issues arise from this, do not hesitate to yell at me.

The deprecated methods will be removed after beta.
This commit is contained in:
Nick 2016-02-03 23:14:26 -08:00
parent e219b50589
commit 8c1eaddb97
14 changed files with 152 additions and 165 deletions

View file

@ -110,8 +110,6 @@ public class ItemBoundTool extends ItemBindable
@Override
public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player)
{
BindableHelper.checkAndSetItemOwner(stack, player);
// if (!world.isRemote)
{
if (player.isSneaking())
@ -136,15 +134,6 @@ public class ItemBoundTool extends ItemBindable
return stack;
}
@Override
public boolean onItemUseFirst(ItemStack stack, EntityPlayer player, World world, BlockPos blockPos, EnumFacing side, float hitX, float hitY, float hitZ)
{
if (BindableHelper.checkAndSetItemOwner(stack, player) && ItemBindable.syphonNetwork(stack, player, getLPUsed()))
return false;
return false;
}
@Override
public boolean onItemUse(ItemStack stack, EntityPlayer player, World world, BlockPos pos, EnumFacing side, float hitX, float hitY, float hitZ)
{