Package extracells.tileentity

Examples of extracells.tileentity.TileEntityBusFluidImport


  }

  @Override
  public TileEntity createNewTileEntity(World world)
  {
    return new TileEntityBusFluidImport();
  }
View Full Code Here


  @Override
  public void execute(EntityPlayer player, Side side) throws ProtocolException
  {
    if (side.isServer())
    {
      TileEntityBusFluidImport tile = (TileEntityBusFluidImport) world.getBlockTileEntity(x, y, z);
      switch (action)
      {
      case 0:
        if (tile != null)
          PacketDispatcher.sendPacketToAllPlayers(tile.getDescriptionPacket());
        break;
      case 1:
        if (tile.getRedstoneMode().ordinal() >= 3)
        {

          tile.setRedstoneMode(RedstoneModeInput.values()[0]);
        } else
        {
          tile.setRedstoneMode(RedstoneModeInput.values()[tile.getRedstoneMode().ordinal() + 1]);
        }
        if (tile != null)
          PacketDispatcher.sendPacketToAllPlayers(tile.getDescriptionPacket());
        break;
      case 2:
        if (tile.getFluidMode().ordinal() >= 2)
        {

          tile.setFluidMode(FluidMode.values()[0]);
        } else
        {
          tile.setFluidMode(FluidMode.values()[tile.getFluidMode().ordinal() + 1]);
        }
        if (tile != null)
          PacketDispatcher.sendPacketToAllPlayers(tile.getDescriptionPacket());
        break;
      }
    }
  }
View Full Code Here

TOP

Related Classes of extracells.tileentity.TileEntityBusFluidImport

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.