Constructor






Methods


Actor:createSprite()

Misc Functions

Returns:

1: ActorSprite


Actor:getAnimation(anim: any)

Arguments:

anim: any

Returns:

1: unknown










Actor:getFlipDirection(sprite: any)

Arguments:

sprite: any

Returns:

1: unknown








Actor:getName()

Returns:

1: string|nil


Actor:getOffset(sprite: any)

Arguments:

sprite: any

Returns:

1: integer












Actor:getTalkSpeed(sprite: any)

Arguments:

sprite: any

Returns:

1: number


Actor:getVoice()

Returns:

1: unknown


Actor:getWidth()

Returns:

1: integer


Actor:hasOffset(sprite: any)

Arguments:

sprite: any

Returns:

1: boolean


Actor:hasTalkSprite(sprite: any)

Arguments:

sprite: any

Returns:

1: boolean


Actor:onBattleDraw(battler: any)

Arguments:

battler: any


Actor:onBattleUpdate(battler: any)

Arguments:

battler: any


Actor:onResetSprite(sprite: any)

Arguments:

sprite: any


Actor:onSet(sprite: any, name: any, callback: any)

Arguments:

sprite: any
name: any
callback: any


Actor:onSetAnimation(sprite: any, anim: any, callback: any)

Arguments:

sprite: any
anim: any
callback: any


Actor:onSetSprite(sprite: any, texture: any, keep_anim: any)

Arguments:

sprite: any
texture: any
keep_anim: any


Actor:onSpriteDraw(sprite: any)

Arguments:

sprite: any


Actor:onSpriteInit(sprite: any)

Arguments:

sprite: any


Actor:onSpriteUpdate(sprite: any)

Arguments:

sprite: any


Actor:onTalkEnd(text: any, sprite: any)

Arguments:

text: any
sprite: any


Actor:onTalkStart(text: any, sprite: any)

Arguments:

text: any
sprite: any


Actor:onWorldDraw(chara: any)

Arguments:

chara: any


Actor:onWorldUpdate(chara: any)

Arguments:

chara: any


Actor:parseSpriteOptions(full_sprite: any, ignore_frames: any)

horrific

Arguments:

full_sprite: any
ignore_frames: any

Returns:

1: table


Actor:preResetSprite(sprite: any)

Arguments:

sprite: any


Actor:preSet(sprite: any, name: any, callback: any)

Arguments:

sprite: any
name: any
callback: any


Actor:preSetAnimation(sprite: any, anim: any, callback: any)

Arguments:

sprite: any
anim: any
callback: any


Actor:preSetSprite(sprite: any, texture: any, keep_anim: any)

Arguments:

sprite: any
texture: any
keep_anim: any


Actor:preSpriteDraw(sprite: any)

Arguments:

sprite: any


Actor:preSpriteUpdate(sprite: any)

Arguments:

sprite: any



Fields



Undocumented



Actor.animations: table

Table of sprite animations



Actor.can_blush: boolean

Whether this actor as a follower will blush when close to the player



Actor.color: table

Color for this actor used in outline areas (optional, defaults to red)



Actor.default: string

This actor's default sprite or animation, relative to the path (defaults to "")



Actor.flip: nil

Whether this actor flips horizontally (optional, values are "right" or "left", indicating the flip direction)



Actor.flip_sprites: table

Table of sprites that have a unique flip value, if self.flip is not set





Actor.hitbox: nil

Hitbox for this actor in the overworld (optional, uses width and height by default)



Actor.indent_string: nil

Indent style for the actor (optional)



Actor.mirror_sprites: table

Tables of sprites to change into in mirrors



Actor.name: nil

Display name (optional)



Actor.offsets: table

Table of sprite offsets (indexed by sprite name)



Actor.path: string

Path to this actor's sprites (defaults to "")



Actor.portrait_offset: nil

Offset position for this actor's portrait (optional)



Actor.portrait_path: nil

Path to this actor's portrait for dialogue (optional)



Actor.soul_offset: table

A table that defines where the Soul should be placed on this actor if they are a player. First value is x, second value is y.



Actor.talk_sprites: table

Table of talk sprites and their talk speeds (default 0.25)



Actor.voice: nil

Sound to play when this actor speaks (optional)



Actor.width: integer

Width and height for this actor, used to determine its center