Package com.badlogic.gdx.utils

Examples of com.badlogic.gdx.utils.DataInput.readString()


        if (skeletonData.imagesPath.isEmpty()) skeletonData.imagesPath = null;
      }

      // Bones.
      for (int i = 0, n = input.readInt(true); i < n; i++) {
        String name = input.readString();
        BoneData parent = null;
        int parentIndex = input.readInt(true) - 1;
        if (parentIndex != -1) parent = skeletonData.bones.get(parentIndex);
        BoneData boneData = new BoneData(name, parent);
        boneData.x = input.readFloat() * scale;
 
View Full Code Here


        skeletonData.bones.add(boneData);
      }

      // IK constraints.
      for (int i = 0, n = input.readInt(true); i < n; i++) {
        IkConstraintData ikConstraintData = new IkConstraintData(input.readString());
        for (int ii = 0, nn = input.readInt(true); ii < nn; ii++)
          ikConstraintData.bones.add(skeletonData.bones.get(input.readInt(true)));
        ikConstraintData.target = skeletonData.bones.get(input.readInt(true));
        ikConstraintData.mix = input.readFloat();
        ikConstraintData.bendDirection = input.readByte();
View Full Code Here

        skeletonData.ikConstraints.add(ikConstraintData);
      }

      // Slots.
      for (int i = 0, n = input.readInt(true); i < n; i++) {
        String slotName = input.readString();
        BoneData boneData = skeletonData.bones.get(input.readInt(true));
        SlotData slotData = new SlotData(slotName, boneData);
        Color.rgba8888ToColor(slotData.color, input.readInt());
        slotData.attachmentName = input.readString();
        slotData.additiveBlending = input.readBoolean();
View Full Code Here

      for (int i = 0, n = input.readInt(true); i < n; i++) {
        String slotName = input.readString();
        BoneData boneData = skeletonData.bones.get(input.readInt(true));
        SlotData slotData = new SlotData(slotName, boneData);
        Color.rgba8888ToColor(slotData.color, input.readInt());
        slotData.attachmentName = input.readString();
        slotData.additiveBlending = input.readBoolean();
        skeletonData.slots.add(slotData);
      }

      // Default skin.
View Full Code Here

        skeletonData.skins.add(defaultSkin);
      }

      // Skins.
      for (int i = 0, n = input.readInt(true); i < n; i++)
        skeletonData.skins.add(readSkin(input, input.readString(), nonessential));

      // Events.
      for (int i = 0, n = input.readInt(true); i < n; i++) {
        EventData eventData = new EventData(input.readString());
        eventData.intValue = input.readInt(false);
View Full Code Here

      for (int i = 0, n = input.readInt(true); i < n; i++)
        skeletonData.skins.add(readSkin(input, input.readString(), nonessential));

      // Events.
      for (int i = 0, n = input.readInt(true); i < n; i++) {
        EventData eventData = new EventData(input.readString());
        eventData.intValue = input.readInt(false);
        eventData.floatValue = input.readFloat();
        eventData.stringValue = input.readString();
        skeletonData.events.add(eventData);
      }
View Full Code Here

      // Events.
      for (int i = 0, n = input.readInt(true); i < n; i++) {
        EventData eventData = new EventData(input.readString());
        eventData.intValue = input.readInt(false);
        eventData.floatValue = input.readFloat();
        eventData.stringValue = input.readString();
        skeletonData.events.add(eventData);
      }

      // Animations.
      for (int i = 0, n = input.readInt(true); i < n; i++)
View Full Code Here

        skeletonData.events.add(eventData);
      }

      // Animations.
      for (int i = 0, n = input.readInt(true); i < n; i++)
        readAnimation(input.readString(), input, skeletonData);

    } catch (IOException ex) {
      throw new SerializationException("Error reading skeleton file.", ex);
    } finally {
      try {
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.