Port to 1.11

This commit is contained in:
yueh
2016-12-08 12:42:00 +01:00
parent 589730bfad
commit ed9e6dd21c
262 changed files with 4027 additions and 3954 deletions
@@ -82,7 +82,7 @@ public class TileCrank extends AEBaseTile implements ICustomCollision, ITickable
}
final EnumFacing grinder = this.getUp().getOpposite();
final TileEntity te = this.worldObj.getTileEntity( this.pos.offset( grinder ) );
final TileEntity te = this.world.getTileEntity( this.pos.offset( grinder ) );
if( te instanceof ICrankable )
{
return (ICrankable) te;
@@ -107,8 +107,8 @@ public class TileCrank extends AEBaseTile implements ICustomCollision, ITickable
public void setOrientation( final EnumFacing inForward, final EnumFacing inUp )
{
super.setOrientation( inForward, inUp );
final IBlockState state = this.worldObj.getBlockState( this.pos );
this.getBlockType().neighborChanged( state, this.worldObj, this.pos, state.getBlock() );
final IBlockState state = this.world.getBlockState( this.pos );
this.getBlockType().neighborChanged( state, this.world, this.pos, state.getBlock(), this.pos );
}
@Override
@@ -144,7 +144,7 @@ public class TileCrank extends AEBaseTile implements ICustomCollision, ITickable
this.hits++;
if( this.hits > 10 )
{
this.worldObj.destroyBlock( this.pos, false );
this.world.destroyBlock( this.pos, false );
}
}
}
@@ -50,8 +50,8 @@ public class TileGrinder extends AEBaseInvTile implements ICrankable
public void setOrientation( final EnumFacing inForward, final EnumFacing inUp )
{
super.setOrientation( inForward, inUp );
final IBlockState state = this.worldObj.getBlockState( this.pos );
this.getBlockType().neighborChanged( state, this.worldObj, this.pos, state.getBlock() );
final IBlockState state = this.world.getBlockState( this.pos );
this.getBlockType().neighborChanged( state, this.world, this.pos, state.getBlock(), this.pos );
}
@Override
@@ -111,13 +111,13 @@ public class TileGrinder extends AEBaseInvTile implements ICrankable
final IGrinderRecipe r = AEApi.instance().registries().grinder().getRecipeForInput( item );
if( r != null )
{
if( item.stackSize >= r.getInput().stackSize )
if( item.getCount() >= r.getInput().getCount() )
{
item.stackSize -= r.getInput().stackSize;
item.grow( -r.getInput().getCount() );
final ItemStack ais = item.copy();
ais.stackSize = r.getInput().stackSize;
ais.setCount( r.getInput().getCount() );
if( item.stackSize <= 0 )
if( item.getCount() <= 0 )
{
item = null;
}
@@ -194,7 +194,7 @@ public class TileGrinder extends AEBaseInvTile implements ICrankable
final List<ItemStack> out = new ArrayList<ItemStack>();
out.add( notAdded );
Platform.spawnDrops( this.worldObj, this.pos.offset( this.getForward() ), out );
Platform.spawnDrops( this.world, this.pos.offset( this.getForward() ), out );
}
}
@@ -203,4 +203,11 @@ public class TileGrinder extends AEBaseInvTile implements ICrankable
{
return this.getUp() == directionToCrank;
}
@Override
public boolean isEmpty()
{
// TODO Auto-generated method stub
return false;
}
}