Examples of readFromNBT()


Examples of buildcraft.transport.TileGenericPipe.SideProperties.readFromNBT()

  @Override
  public void rotateLeft(IBuilderContext context) {
    SideProperties props = new SideProperties ();

    props.readFromNBT(tileNBT);
    props.rotateLeft();
    props.writeToNBT(tileNBT);

    Item pipeItem = Item.getItemById(tileNBT.getInteger("pipeId"));
View Full Code Here

Examples of com.pahimar.ee3.settings.ChalkSettings.readFromNBT()

        if (!world.isRemote && world.getTileEntity(x, y, z) instanceof TileEntityAlchemyArray && entityLiving instanceof EntityPlayer)
        {
            NBTTagCompound customEntityData = EntityHelper.getCustomEntityData(entityLiving);
            ChalkSettings chalkSettings = new ChalkSettings();
            chalkSettings.readFromNBT(customEntityData);

            // Set adjusted rotation
            int facing = MathHelper.floor_double(entityLiving.rotationYaw * 4.0F / 360.0F + 0.5D) & 3;
            ((TileEntityAlchemyArray) world.getTileEntity(x, y, z)).setRotation(chalkSettings.getRotation(), facing);

View Full Code Here

Examples of com.pahimar.ee3.skill.PlayerKnowledge.readFromNBT()

        if (itemStack.getItem() instanceof ItemAlchemicalTome)
        {
            if (itemStack.hasTagCompound() && NBTHelper.hasTag(itemStack, Names.NBT.KNOWLEDGE))
            {
                PlayerKnowledge playerKnowledge = new PlayerKnowledge();
                playerKnowledge.readFromNBT(itemStack.getTagCompound());
                return playerKnowledge;
            }
            else
            {
                PlayerKnowledge playerKnowledge = new PlayerKnowledge();
View Full Code Here

Examples of com.pahimar.ee3.tileentity.TileEntityAlchemyArray.readFromNBT()

    public IMessage onMessage(MessageTileEntityAlchemyArray message, MessageContext ctx)
    {
        if (message.tileEntityAlchemyArrayNBT != null)
        {
            TileEntityAlchemyArray tileEntityAlchemyArray = new TileEntityAlchemyArray();
            tileEntityAlchemyArray.readFromNBT(message.tileEntityAlchemyArrayNBT);

            TileEntity tileEntity = FMLClientHandler.instance().getClient().theWorld.getTileEntity(tileEntityAlchemyArray.xCoord, tileEntityAlchemyArray.yCoord, tileEntityAlchemyArray.zCoord);

            if (tileEntity instanceof TileEntityAlchemyArray)
            {
View Full Code Here

Examples of crazypants.enderio.conduit.gas.IGasConduit.readFromNBT()

    IConduitBundle bundle = (IConduitBundle) tile;
    IGasConduit con = bundle.getConduit(IGasConduit.class);
    if(con == null) {
      return;
    }
    con.readFromNBT(pkt.tc, TileConduitBundle.NBT_VERSION);
  }

  public static void spawnFarmParcticles(Random rand, BlockCoord bc) {
    double xOff = 0.5 + (rand.nextDouble() - 0.5) * 1.1;
    double yOff = 0.5 + (rand.nextDouble() - 0.5) * 0.2;
 
View Full Code Here

Examples of crazypants.enderio.conduit.item.filter.IItemFilter.readFromNBT()

  private static IItemFilter loadFilterFromNbt(String className, NBTTagCompound tag) {
    try {
      Class<?> clz = Class.forName(className);
      IItemFilter filter = (IItemFilter) clz.newInstance();
      filter.readFromNBT(tag);
      return filter;
    } catch (Exception e) {
      Log.error("Could not read item filter with class name: " + className + " from NBT: " + tag + " Error: " + e);
      return null;
    }
View Full Code Here

Examples of crazypants.enderio.conduit.liquid.ILiquidConduit.readFromNBT()

    IConduitBundle bundle = (IConduitBundle) tile;
    ILiquidConduit con = bundle.getConduit(ILiquidConduit.class);
    if(con == null) {
      return;
    }
    con.readFromNBT(pkt.tc, TileConduitBundle.NBT_VERSION);
  }

  public static void doGasLevelUpdate(int x, int y, int z, PacketGasLevel pkt) {
    TileEntity tile = Minecraft.getMinecraft().theWorld.getTileEntity(x, y, z);
    if(pkt.tc == null || !(tile instanceof IConduitBundle)) {
View Full Code Here

Examples of logisticspipes.modules.ModuleApiaristSink.readFromNBT()

  @Override
  public Object getClientGui(EntityPlayer player) {
    ModuleApiaristSink module = this.getLogisticsModule(player.getEntityWorld(), ModuleApiaristSink.class);
    if(module == null) return null;
    module.readFromNBT(getNbt());
    return new GuiApiaristSink(module, player);
  }

  @Override
  public DummyContainer getContainer(EntityPlayer player) {
View Full Code Here

Examples of logisticspipes.modules.ModuleModBasedItemSink.readFromNBT()

  @Override
  public Object getClientGui(EntityPlayer player) {
    ModuleModBasedItemSink module = this.getLogisticsModule(player.getEntityWorld(), ModuleModBasedItemSink.class);
    if(module == null) return null;
    module.readFromNBT(getNbt());
    return new GuiModBasedItemSink(player.inventory, module);
  }

  @Override
  public DummyContainer getContainer(EntityPlayer player) {
View Full Code Here

Examples of logisticspipes.modules.ModuleOreDictItemSink.readFromNBT()

 
  @Override
  public Object getClientGui(EntityPlayer player) {
    ModuleOreDictItemSink module = this.getLogisticsModule(player.getEntityWorld(), ModuleOreDictItemSink.class);
    if(module == null) return null;
    module.readFromNBT(getNbt());
    return new GuiOreDictItemSink(player.inventory, module);
  }

  @Override
  public DummyContainer getContainer(EntityPlayer player) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.