Examples of NBTTagFloat


Examples of net.minecraft.nbt.NBTTagFloat

    float[] afloat = par1ArrayOfFloat;
    int i = par1ArrayOfFloat.length;

    for (int j = 0; j < i; ++j) {
      float f1 = afloat[j];
      nbttaglist.appendTag(new NBTTagFloat(f1));
    }

    return nbttaglist;
  }
View Full Code Here

Examples of net.minecraft.nbt.NBTTagFloat

    float[] afloat = par1ArrayOfFloat;
    int i = par1ArrayOfFloat.length;

    for (int j = 0; j < i; ++j) {
      float f1 = afloat[j];
      nbttaglist.appendTag(new NBTTagFloat(f1));
    }

    return nbttaglist;
  }
View Full Code Here

Examples of net.minecraft.nbt.NBTTagFloat

        {
            NBTTagList list = new NBTTagList();
            float[] array = (float[]) obj;
            for (int i = 0; i < array.length; i++)
            {
                list.appendTag(new NBTTagFloat(array[i]));
            }

            tag.setTag(name, list);
        }
        else if (type.equals(Double.class))
View Full Code Here

Examples of net.minecraft.nbt.NBTTagFloat

        {
            return tag.getFloat(name);
        }
        else if (type.equals(float[].class))
        {
            NBTTagList list = tag.getTagList(name, new NBTTagFloat(0f).getId());
            float[] array = new float[list.tagCount()];
            for (int i = 0; i < array.length; i++)
            {
                array[i] = list.func_150308_e(i);
            }
View Full Code Here

Examples of net.minecraft.nbt.NBTTagFloat

  public static NBTBase createTag(Object value) {
    if (value instanceof Byte)    return new NBTTagByte((Byte)value);
    if (value instanceof Short)   return new NBTTagShort((Short)value);
    if (value instanceof Integer) return new NBTTagInt((Integer)value);
    if (value instanceof Long)    return new NBTTagLong((Long)value);
    if (value instanceof Float)   return new NBTTagFloat((Float)value);
    if (value instanceof Doublereturn new NBTTagDouble((Double)value);
    if (value instanceof Stringreturn new NBTTagString((String)value);
    if (value instanceof byte[])  return new NBTTagByteArray((byte[])value);
    if (value instanceof int[])   return new NBTTagIntArray((int[])value);
    return null;
View Full Code Here

Examples of net.minecraft.nbt.NBTTagFloat

  }

  @Override
  public float getFloat(String tag) {
    try {
      NBTTagFloat nbtTagFloat = (NBTTagFloat) tagMap.get(tag);
      return nbtTagFloat == null ? 0 : nbtTagFloat.data;
    } catch (ClassCastException e) {
      throw new ReportedException(createCrashReport(tag, 5, e));
    }
  }
View Full Code Here

Examples of net.minecraft.nbt.NBTTagFloat

    float[] afloat = par1ArrayOfFloat;
    int i = par1ArrayOfFloat.length;

    for (int j = 0; j < i; ++j) {
      float f1 = afloat[j];
      nbttaglist.appendTag(new NBTTagFloat(f1));
    }

    return nbttaglist;
  }
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.