Constructor


Textbox(x: any, y: any, width: any, height: any, default_font: any, default_font_size: any, battle_box: any)

Arguments:

x: any
y: any
width: any
height: any
default_font: any
default_font_size: any
battle_box: any




Methods


Textbox:addFunction(id: any, func: any)

Arguments:

id: any
func: any


Textbox:addReaction(id: any, text: any, x: number, y: number, face: any, actor: any)

Arguments:

id: any
text: any
x: number
y: number
face: any
actor: any










Textbox:isDone()

Returns:

1: boolean








Textbox:setActor(actor: any)

Arguments:

actor: any


Textbox:setAdvance(advance: any)

Arguments:

advance: any


Textbox:setAlign(align: any)

Arguments:

align: any


Textbox:setAuto(auto: any)

Arguments:

auto: any


Textbox:setCallback(callback: any)

Arguments:

callback: any


Textbox:setFace(face: any, ox: any, oy: any)

Arguments:

face: any
ox: any
oy: any


Textbox:setFont(font: any, size: any)

Arguments:

font: any
size: any


Textbox:setSize(w: any, h: any)

Arguments:

w: any
h: any


Textbox:setSkippable(skippable: any)

Arguments:

skippable: any


Textbox:setText(text: string|string[], callback: any)

Arguments:

text: string|string[]
callback: any







Fields



Undocumented











Textbox.actor: nil

Actors are a type of data class that represent the visuals of a character - anything that is some type of character, be it the player, an NPC, or an enemy in battle, it will require an actor.
As a data class, actors are stored in scripts/data/actors/, and extend this class. Their filepath starting from here becomes their id, unless an id is specified as an argument to Class().



Textbox.actor: any

Actors are a type of data class that represent the visuals of a character - anything that is some type of character, be it the player, an NPC, or an enemy in battle, it will require an actor.
As a data class, actors are stored in scripts/data/actors/, and extend this class. Their filepath starting from here becomes their id, unless an id is specified as an argument to Class().















Textbox.face: Sprite

A simple object that renders a texture.
This texture must be placed inside assets/sprites/.





























































Textbox.text_y: integer

TODO: This was changed 2px lower with the new font, but it was 4px offset. Why? (Used to be 0)





Textbox.text_y: integer

TODO: This was changed with the new font but it's accurate anyways





Textbox.wrap_add_w: integer

Added text width for autowrapping