Stores the setup pose and all of the stateless data for a skeleton.

See Data objects in the Spine Runtimes Guide.

Constructor

new()

Variables

@:value(new Array())bones:Array<BoneData> = new Array()

@:value(new Array())slots:Array<SlotData> = new Array()

@:value(new Array())skins:Array<Skin> = new Array()

@:value(new Array())events:Array<EventData> = new Array()

@:value(new Array())animations:Array<Animation> = new Array()

@:value(new Array())ikConstraints:Array<IkConstraintData> = new Array()

@:value(new Array())transformConstraints:Array<TransformConstraintData> = new Array()

@:value(new Array())pathConstraints:Array<PathConstraintData> = new Array()

@:value(0)x:Float = 0

@:value(0)y:Float = 0

@:value(0)width:Float = 0

@:value(0)height:Float = 0

@:value(null)hash:String = null

@:value(30)fps:Float = 30

@:value(null)audioPath:String = null

Methods

getBones():Array<BoneData>

The skeleton's bones, sorted parent first. The root bone is always the first bone.

findBone(boneName:String):BoneData

Finds a bone by comparing each bone's name. It is more efficient to cache the results of this method than to call it multiple times.

getSlots():Array<SlotData>

The skeleton's slots.

findSlot(slotName:String):SlotData

Finds a slot by comparing each slot's name. It is more efficient to cache the results of this method than to call it multiple times.

getDefaultSkin():Skin

The skeleton's default skin. By default this skin contains all attachments that were not in a skin in Spine.

See {@link Skeleton#getAttachment(int, String)}.

setDefaultSkin(defaultSkin:Skin):Void

findSkin(skinName:String):Skin

Finds a skin by comparing each skin's name. It is more efficient to cache the results of this method than to call it multiple times.

getSkins():Array<Skin>

All skins, including the default skin.

findEvent(eventDataName:String):EventData

Finds an event by comparing each events's name. It is more efficient to cache the results of this method than to call it multiple times.

getEvents():Array<EventData>

The skeleton's events.

getAnimations():Array<Animation>

The skeleton's animations.

findAnimation(animationName:String):Animation

Finds an animation by comparing each animation's name. It is more efficient to cache the results of this method than to call it multiple times.

getIkConstraints():Array<IkConstraintData>

The skeleton's IK constraints.

findIkConstraint(constraintName:String):IkConstraintData

Finds an IK constraint by comparing each IK constraint's name. It is more efficient to cache the results of this method than to call it multiple times.

getTransformConstraints():Array<TransformConstraintData>

The skeleton's transform constraints.

findTransformConstraint(constraintName:String):TransformConstraintData

Finds a transform constraint by comparing each transform constraint's name. It is more efficient to cache the results of this method than to call it multiple times.

getPathConstraints():Array<PathConstraintData>

The skeleton's path constraints.

findPathConstraint(constraintName:String):PathConstraintData

Finds a path constraint by comparing each path constraint's name. It is more efficient to cache the results of this method than to call it multiple times.

getName():String

The skeleton's name, which by default is the name of the skeleton data file when possible, or null when a name hasn't been set.

getX():Float

The X coordinate of the skeleton's axis aligned bounding box in the setup pose.

getY():Float

The Y coordinate of the skeleton's axis aligned bounding box in the setup pose.

getWidth():Float

The width of the skeleton's axis aligned bounding box in the setup pose.

getHeight():Float

The height of the skeleton's axis aligned bounding box in the setup pose.

getVersion():String

The Spine version used to export the skeleton data, or null.

getHash():String

The skeleton data hash. This value will change if any of the skeleton data has changed.

getImagesPath():String

The path to the images directory as defined in Spine, or null if nonessential data was not exported.

getAudioPath():String

The path to the audio directory as defined in Spine, or null if nonessential data was not exported.

getFps():Float

The dopesheet FPS in Spine, or zero if nonessential data was not exported.