SkeletonJson

SkeletonLoaderspine.SkeletonJson (Class)

Loads skeleton data in the Spine JSON format.

JSON is human readable but the binary format is much smaller on disk and faster to load. See {@link SkeletonBinary}.

See Spine JSON format and JSON and binary data in the Spine Runtimes Guide.

Static Members

spine
setBezier(timeline: CurveTimeline, frame: Int, value: Int, bezier: Int, time1: Float, value1: Float, cx1: Float, cy1: Float, cx2: Float, cy2: Float, time2: Float, value2: Float): Void
Name Type
timeline CurveTimeline
frame Int
value Int
bezier Int
time1 Float
value1 Float
cx1 Float
cy1 Float
cx2 Float
cy2 Float
time2 Float
value2 Float

Instance Members

spine
readSkeletonData(root: spine.support.utils.JsonValue): SkeletonData
Name Type
root spine.support.utils.JsonValue
Returns
SkeletonData

spine
readCurve(curve: spine.support.utils.JsonValue, timeline: CurveTimeline, bezier: Int, frame: Int, value: Int, time1: Float, time2: Float, value1: Float, value2: Float, scale: Float): Int
Name Type
curve spine.support.utils.JsonValue
timeline CurveTimeline
bezier Int
frame Int
value Int
time1 Float
time2 Float
value1 Float
value2 Float
scale Float
Returns
Int

spine
new(attachmentLoader: spine.attachments.AttachmentLoader): Void
Name Type
attachmentLoader spine.attachments.AttachmentLoader

Private Members

spine
readAttachment(map: spine.support.utils.JsonValue, skin: Skin, slotIndex: Int, name: String, skeletonData: SkeletonData): spine.attachments.Attachment
Name Type
map spine.support.utils.JsonValue
skin Skin
slotIndex Int
name String
skeletonData SkeletonData
Returns
spine.attachments.Attachment

spine
readVertices(map: spine.support.utils.JsonValue, attachment: spine.attachments.VertexAttachment, verticesLength: Int): Void
Name Type
map spine.support.utils.JsonValue
attachment spine.attachments.VertexAttachment
verticesLength Int

spine
readAnimation(map: spine.support.utils.JsonValue, name: String, skeletonData: SkeletonData): Void
Name Type
map spine.support.utils.JsonValue
name String
skeletonData SkeletonData

spine
readTimeline(keyMap: spine.support.utils.JsonValue, timeline: CurveTimeline1, defaultValue: Float, scale: Float): Timeline
Name Type
keyMap spine.support.utils.JsonValue
timeline CurveTimeline1
defaultValue Float
scale Float
Returns
Timeline

spine
readTimeline2(keyMap: spine.support.utils.JsonValue, timeline: CurveTimeline2, name1: String, name2: String, defaultValue: Float, scale: Float): Timeline
Name Type
keyMap spine.support.utils.JsonValue
timeline CurveTimeline2
name1 String
name2 String
defaultValue Float
scale Float
Returns
Timeline