Example #1
0
  public ACHR(Record recordData) {

    super(recordData);
    ArrayList<Subrecord> subrecords = recordData.getSubrecords();
    for (int i = 0; i < subrecords.size(); i++) {
      Subrecord sr = subrecords.get(i);
      byte[] bs = sr.getData();

      if (sr.getType().equals("EDID")) {
        EDID = new ZString(bs);
      } else if (sr.getType().equals("NAME")) {
        NAME = new FormID(bs);
      } else if (sr.getType().equals("XESP")) {
        xesp = new XESP(bs);
      } else if (sr.getType().equals("XHRS")) {
        XHRS = new FormID(bs);
      } else if (sr.getType().equals("XMRC")) {
        XMRC = new FormID(bs);
      } else if (sr.getType().equals("XRGD")) {
        XRGD = new XRGD(bs);
      } else if (sr.getType().equals("XSCL")) {
        scale = ESMByteConvert.extractFloat(bs, 0);
      } else if (sr.getType().equals("DATA")) {
        this.extractInstData(bs);
      } else if (sr.getType().equals("XLCM")) {
      } else if (sr.getType().equals("XLKR")) {

      } else if (sr.getType().equals("XLCN")) {

      } else if (sr.getType().equals("XLRT")) {

      } else if (sr.getType().equals("VMAD")) {
      } else if (sr.getType().equals("XAPD")) {
      } else if (sr.getType().equals("XAPR")) {
      } else if (sr.getType().equals("XRGB")) {
      } else if (sr.getType().equals("XEZN")) {
      } else if (sr.getType().equals("XOWN")) {
      } else if (sr.getType().equals("XHOR")) {
      } else if (sr.getType().equals("XLYR")) {
        // new
      } else if (sr.getType().equals("XIS2")) {
        // new
      } else if (sr.getType().equals("XLKT")) {
        // new
      } else {
        System.out.println(
            "unhandled : " + sr.getType() + " in record " + recordData + " in " + this);
      }
    }
  }
Example #2
0
  public LIGH(Record recordData) {
    super(recordData);
    ArrayList<Subrecord> subrecords = recordData.getSubrecords();
    for (int i = 0; i < subrecords.size(); i++) {
      Subrecord sr = subrecords.get(i);
      byte[] bs = sr.getData();

      if (sr.getType().equals("NAME")) {
        EDID = new ZString(bs);
      } else if (sr.getType().equals("FNAM")) {
        FULL = new LString(bs);
      } else if (sr.getType().equals("LHDT")) {
        // System.out.println("" + ESMByteConvert.extractFloat(bs, 0)); weight
        fade = ESMByteConvert.extractInt(bs, 4); // value fade?
        // System.out.println("" + ESMByteConvert.extractInt(bs, 8)); time

        radius = ESMByteConvert.extractInt(bs, 12);
        color.x = ESMByteConvert.extractUnsignedByte(bs, 16);
        color.y = ESMByteConvert.extractUnsignedByte(bs, 17);
        color.z = ESMByteConvert.extractUnsignedByte(bs, 18);
      } else if (sr.getType().equals("SCPT")) {

      } else if (sr.getType().equals("ITEX")) {
        ICON = new ZString(bs);
      } else if (sr.getType().equals("MODL")) {
        MODL = new MODL(bs);
      } else if (sr.getType().equals("SNAM")) {

      } else if (sr.getType().equals("SCRI")) {

      } else {
        System.out.println(
            "unhandled : " + sr.getType() + " in record " + recordData + " in " + this);
      }
    }
  }
Example #3
0
 public HCLR(byte[] bytes) {
   red = ESMByteConvert.extractByte(bytes, 0);
   green = ESMByteConvert.extractByte(bytes, 0);
   blue = ESMByteConvert.extractByte(bytes, 0);
   custom = ESMByteConvert.extractByte(bytes, 0);
 }