Class: Game_Message

Game_Message

new Game_Message()

The game object class for the state of the message window that displays text or selections, etc.

Methods

Adds the given text to the message
NameTypeDescription
textstringThe text to add

allText()string

Gets all of the text
Returns:
TypeDescription
stringAll of the text

background()number

Get the background type
Returns:
TypeDescription
numberThe background type

choiceBackground()number

Get the choice background type
Returns:
TypeDescription
numberThe choice background type

choiceCancelType()number

Get the choice cancel type
Returns:
TypeDescription
numberThe choice cancel type

choiceDefaultType()number

Get the default choice type
Returns:
TypeDescription
numberThe default choice type

choicePositionType()number

Get the choice position type
Returns:
TypeDescription
numberThe choice position type

choices()Array

Get the choice array
Returns:
TypeDescription
ArrayThe choice array
Clear message variables

faceIndex()number

Get the face index (for face image file)
Returns:
TypeDescription
numberThe face index

faceName()string

Get the face name (for face image file)
Returns:
TypeDescription
stringThe face name

hasText()boolean

Check if there is text in the message
Returns:
TypeDescription
booleanTrue if there is text

initialize()

Initialize the class

isBusy()boolean

Check if the message is busy
Returns:
TypeDescription
booleanTrue if busy

isChoice()boolean

Check if there are choices
Returns:
TypeDescription
booleanTrue if there are choices

isItemChoice()boolean

Check if there is an item choice
Returns:
TypeDescription
booleanTrue if there is an item choice

isNumberInput()boolean

Check if there is number input
Returns:
TypeDescription
booleanTrue if there is number input

isRTL()boolean

Check if the text is right to left
Returns:
TypeDescription
booleanTrue if RTL

itemChoiceItypeId()number

Get the item choice item type id
Returns:
TypeDescription
numberThe item type id

itemChoiceVariableId()number

Get the item choice variable id
Returns:
TypeDescription
numberThe variable id
Creates a new page

numInputMaxDigits()number

Get the number input maximum allowed digits
Returns:
TypeDescription
numberThe max allowed digits

numInputVariableId()number

Get the number input variable id
Returns:
TypeDescription
numberThe variable id
Handling when a choice is made
NameTypeDescription
nnumberThe choice made

positionType()number

Get the position type
Returns:
TypeDescription
numberThe position type

scrollMode()boolean

Check if scroll mode
Returns:
TypeDescription
booleanTrue if scroll mode

scrollNoFast()boolean

Check if scroll no fast
Returns:
TypeDescription
booleanTrue if scroll no fast

scrollSpeed()number

Get the scroll speed
Returns:
TypeDescription
numberThe scroll speed

setBackground(background)

Sets the background type
NameTypeDescription
backgroundnumberThe new background type

setChoiceBackground(background)

Sets the choice background type
NameTypeDescription
backgroundnumberThe new choice background type

setChoiceCallback(callback)

Sets the choice callback function
NameTypeDescription
callbackfunction|nullThe callback, null if none

setChoicePositionType(positionType)

Sets the choice position type
NameTypeDescription
positionTypenumberThe new choice position type

setChoices(choices, defaultType, cancelType)

Sets the choice settings
NameTypeDescription
choicesArrayThe array of choices
defaultTypenumberThe choice default type
cancelTypenumberThe choice cancel type

setFaceImage(faceName, faceIndex)

Sets the face image settings
NameTypeDescription
faceNamestringThe face image file name
faceIndexnumberThe index of the face to use on the face sheet

setItemChoice(variableId, itemType)

Sets the item choice settings
NameTypeDescription
variableIdnumberThe item choice variable id to use
itemTypenumberThe item type to use

setNumberInput(variableId, maxDigits)

Sets the number input settings
NameTypeDescription
variableIdnumberThe number input variable id to use
maxDigitsnumberThe number input max digits to use

setPositionType(positionType)

Sets the position type
NameTypeDescription
positionTypenumberThe new position type

setScroll(speed, noFast)

Sets the scroll settings
NameTypeDescription
speednumberThe scroll speed
noFastbooleanIf no fast mode scrolling

setSpeakerName(speakerName)

Sets the speaker name
NameTypeDescription
speakerNamestringThe new speaker name

speakerName()string

Get the speaker name
Returns:
TypeDescription
stringThe speaker name