The JSON data schema used to define a character.

Fields

version:String

* The sematic version number of the character data JSON format.

startingAnimation:Null<String>

* If animations are used, this is the name of the animation to play first. * @default idle

singTime:Null<Float>

* The minimum duration that a character will play a note animation for, in beats. * If this number is too low, you may see the character start playing the idle animation between notes. * If this number is too high, you may see the the character play the sing animation for too long after the notes are gone. * * Examples: * - Daddy Dearest uses a value of `1.525`. * @default 1.0

scale:Null<Float>

* The scale of the graphic as a float. * Pro tip: On pixel-art levels, save the sprites small and set this value to 6 or so to save memory. * @default 1

renderType:CharacterRenderType

* The type of rendering system to use for the character. * @default sparrow

offsets:Null<Array<Float>>

* The global offset to the character's position, in pixels. * @default [0, 0]

name:String

* The readable name of the character.

isPixel:Null<Bool>

* Setting this to true disables anti-aliasing for the character. * @default false

healthIcon:Null<HealthIconData>

* Optional data about the health icon for the character.

flipX:Null<Bool>

* Whether or not the whole ass sprite is flipped by default. * Useful for characters that could also be played (Pico) * * @default false

death:Null<DeathData>

* Optional data about the death animation for the character.

@:optional@:default(1.0)optionaldanceEvery:Null<Float>

* The frequency at which the character will play its idle animation, in beats. * Increasing this number will make the character dance less often. * Supports up to `0.25` precision. * @default `1.0` on characters

cameraOffsets:Array<Float>

* The amount to offset the camera by while focusing on this character. * Default value focuses on the character directly. * @default [0, 0]

@:optionaloptionalatlasSettings:Null<TextureAtlasData>

* Various settings for the prop. * Only available for texture atlases.

assetPath:String

* Behavior varies by render type: * - SPARROW: Path to retrieve both the spritesheet and the XML data from. * - PACKER: Path to retrieve both the spritsheet and the TXT data from.

applyStageMatrix:Null<Bool>

* NOTE: This only applies to animate atlas characters. * * Whether to apply the stage matrix, if it was exported from a symbol instance. * Also positions the Texture Atlas as it displays in Animate. * Turning this on is only recommended if you prepositioned the character in Animate. * For other cases, it should be turned off to act similarly to a normal FlxSprite.

animations:Array<AnimationData>

* An optional array of animations which the character can play.