UI (functions)
UI:WaitInput
Waits for the player to press a button before continuing.
UI:WaitShowDialogue
Displays a dialogue box with text, waiting until the player completes it. Takes a string as an argument.
Arguments
text: The text to display.callbacks: The Lua table of callbacks for the textbox to call.
Example
UI:WaitShowDialogue("Hello World!")
UI:WaitShowTimedDialogue
Displays a dialogue box with text, waiting until the specified time has expired.
Arguments
text: The text to display.waitTime: The time for the textbox to remain on screen. Pass -1 to wait for layer input.callbacks: The Lua table of callbacks for the textbox to call.
Example
UI:WaitShowTimedDialogue("Hello World!", 120)
UI:TextDialogue(System.String,System.Int32,NLua.LuaTable)
Sets the current dialogue text to be shown. Requires WaitDialog to actually display.
Arguments
text: The text to display.waitTime: The time for the textbox to remain on screen. Pass -1 to wait for layer input.callbacks: The Lua table of callbacks for the textbox to call.
UI:WaitShowVoiceOver
Displays a voice over, waiting until the player completes it.
Arguments
text: The text to display.expireTime: The time for the textbox to remain on screen. Pass -1 to wait for layer input.x: The X position of the boxy: The Y position of the boxwidth: Width of the boxheight: Height of the boxcallbacks: The Lua table of callbacks for the textbox to call.
Example
UI:WaitShowVoiceOver("Hello World!", 120)
UI:TextVoiceOver(System.String,System.Int32,System.Int32,System.Int32,System.Int32,System.Int32,NLua.LuaTable)
Sets the current voice-over text to be shown. Requires WaitDialog to actually display.
Arguments
text: The text to display.expireTime: The time for the textbox to remain on screen. Pass -1 to wait for layer input.x: The X position of the boxy: The Y position of the boxwidth: Width of the boxheight: Height of the boxcallbacks: The Lua table of callbacks for the textbox to call.
UI:TextPopUp(System.String,System.Int32,System.Int32,System.Int32,System.Int32,System.Int32,System.Boolean,System.Boolean)
Makes text pop up in the bottom-left corner by default. Displays concurrently with any other process.
Arguments
text: The text to display.expireTime: The time for the textbox to remain on screen.x: The X position of the boxy: The Y position of the boxwidth: Width of the boxheight: Height of the boxcenterH: Horizontal centeringcenterV: Vertical centering
UI:WaitShowTitle
Fades in a title text, waiting until the fade-in is complete.
Arguments
text: The text to display.time: The time for the text to fade in.
Example
UI:WaitShowTitle("Hello World!", 60)
UI:TextShowTitle(System.String,System.Int32)
Shows text in the format of a title drop. Requires WaitDialog to actually display.
Arguments
text: The text to display.time: The time for the text to fade in.
UI:WaitHideTitle
Fades out the currently displayed title, waiting until the fade-out is complete.
Arguments
time: The time for the text to fade in.
Example
UI:WaitHideTitle(60)
UI:TextFadeTitle(System.Int32)
Fades out the text set in a title drop. Requires WaitDialog to actually fade.
Arguments
time: The time for the text to fade in.
UI:WaitShowBG
Fades in a chosen background image, with a chosen framerate, at a certain fade time, waiting until the fade-in is complete.
Arguments
bg: The background to show, from the list of BG textures.frameTime: Framerate of the image animation.fadeInTime: Time taken to fade in the image.
Example
UI:WaitShowBG("TestBG", 3, 60)
UI:ShowBG(System.String,System.Int32,System.Int32)
Sets an image to display. Requires WaitDialog to actually display.
Arguments
bg: The background to show, from the list of BG textures.frameTime: Framerate of the image animation.fadeInTime: Time taken to fade in the image.
UI:WaitHideBG
Fades out the current background image, waiting until the fade-out is complete.
Arguments
time: Time taken to fade out the image.
Example
UI:WaitHideBG(60)
UI:FadeBG(System.Int32)
Prepares a fade-out of the current image. Requires WaitDialog to actually display.
Arguments
time: Time taken to fade out the image.
UI:ResetSpeaker(System.Boolean)
Clears the current speaker, so none is displayed the next time TextDialogue is called. This also resets any custom dialogue box positions, portrait positions, and choice positions.
Arguments
keysound: If turned on, the text from the dialogue boxes make sounds. Default is on.
UI:SetSpeaker(System.String,System.Boolean,System.String,System.Int32,System.String,RogueEssence.Data.Gender)
Sets the speaker to be displayed during the following calls to the TextDialogue functions. It resets speaker emotion.
Arguments
name: Speaker name.keysound: Plays sounds when text appears.specie: Species of the speakerform: Form of the speakerskin: Skin of the speakergender: Gender of the speaker
UI:SetSpeaker(RogueEssence.Ground.GroundChar,System.Boolean)
Sets the speaker to be displayed during the following calls to the TextDialogue functions. It resets speaker emotion.
Arguments
chara: Character to set as speaker. This is a character in a ground map.keysound: Plays sounds when text appears.
UI:SetSpeaker(RogueEssence.Dungeon.Character,System.Boolean)
Sets the speaker to be displayed during the following calls to the TextDialogue functions. It resets speaker emotion.
Arguments
chara: Character to set as speaker. This is a character in a dungeon map.keysound: Plays sounds when text appears.
UI:SetSpeakerReverse(System.Boolean)
Reverses the speaker orientation to face left instead of right. This depends on the boolean passed in.
Arguments
reverse: Faces right if false, left if true.
UI:SetChoiceLoc(System.Int32,System.Int32)
Sets the position of the choices for a question dialog.
Arguments
x: The X positiony: The Y position
UI:ResetChoiceLoc
Sets the position of the choices for a question dialog back to default.
UI:SetBounds(System.Int32,System.Int32,System.Int32,System.Int32)
Sets the position and size of the dialogue box.
Arguments
x: The X position of the boxy: The Y position of the boxwidth: Width of the boxheight: Height of the box
UI:SetSe(System.String,System.Int32)
Sets the speaker sound effect and speak frames played in the TextDialogue functions.
Arguments
newSe: The sound effect of the boxspeakTime: The amount of frames to wait between each sound effect
Example
UI:SetSe("Battle/_UNK_DUN_Water_Drop", 3)
UI:SetSe(System.String)
Sets the speaker sound effect played in the TextDialogue functions.
Arguments
newSe: The sound effect of the box
Example
UI:SetSe("Menu/Unknown-3")
UI:SetSpeakTime(System.Int32)
Sets the speak frames played in the TextDialogue functions.
Arguments
speakTime: The amount of frames to wait between each sound effect
Example
UI:SetSpeakTime(10)
UI:ResetSe
Resets to the default speaker sound effect and speaker frames.
UI:ResetBounds
Resets the position and size of the dialogue box.
UI:SetSpeakerLoc(System.Int32,System.Int32)
Sets the position of the speaker in a dialogue box.
Arguments
x: The X positiony: The Y position
UI:ResetSpeakerLoc
Resets the position of the speaker in a dialogue box.
UI:SetSpeakerEmotion(System.String,System.Boolean)
Sets the emotion of the speaker in the dialogue box.
Arguments
emo: Emotion to displayreverse: Faces right if false, left if true.
UI:SetCenter(System.Boolean,System.Boolean)
Sets the centering of the text in the textbox.
Arguments
centerH: Horizontal centeringcenterV: Vertical centering
UI:SetAutoFinish(System.Boolean)
Makes the text automatically finish when it shows up.
Arguments
autoFinish: Auto-finishes text if true.
UI:WaitDialog
Displays the currently set dialogue box and waits for the player to complete it.
Example
UI:WaitDialog()
UI:_DummyWait
Instantly break. Used as default/invalid value when returning a yieldable value.
UI:ChoiceMenuYesNo(System.String,System.Boolean,NLua.LuaTable)
Ask a question answered by yes or no via character dialogue to the player. UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the integer value indicating the result of the menu, UI:ChoiceResult() must be called.
The Yes/No menu returns 1 for yes, and 0 for no.
Arguments
message: Question to be asked to the user.bdefaultstono: Whether the cursor starts on no by defaultcallbacks: The Lua table of callbacks for the textbox to call.
UI:NameMenu(System.String,System.String,System.Int32,System.String)
Displays the name input box.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the string value indicating the result of the menu, UI:ChoiceResult() must be called.
Arguments
title: The text to show above the input line.desc: The text to show below the input line.maxLength: The length of the text in pixels.defaultName: Name to start the textbox with.
UI:AssemblyMenu
Displays a menu for replacing party members with the assembly.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the boolean value indicating whether the team composition was changed or not, UI:ChoiceResult() must be called.
UI:ShopMenu(NLua.LuaTable)
Displays the Shop menu.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the table indicating the indices of items chosen, UI:ChoiceResult() must be called.
Arguments
goods: A table of items to be sold. The format is { Item=InvItem, Price=int } for each item.
UI:SellMenu
Displays the Sell menu.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the table indicating the indices of items to sell, UI:ChoiceResult() must be called.
UI:StorageMenu
Displays the Storage menu for which to exchange items in the inventory with.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the menu is exited.
UI:WithdrawMenu
Displays the Storage menu for which to withdraw from.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the menu is exited.
UI:BankMenu
Displays the Bank menu.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the menu is exited.
UI:SpoilsMenu(NLua.LuaTable)
Displays the Spoils menu.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the menu is exited.
Arguments
appraisalMap: A table of mappings from containers to items, in the format of { Box=InvItem , Item=InvItem }
UI:AppraiseMenu
Displays the Appraisal menu.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the table indicating the indices of items chosen, UI:ChoiceResult() must be called.
UI:TutorTeamMenu(NLua.LuaFunction)
Displays the Tutor Team menu.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the integer representing the chosen team member, UI:ChoiceResult() must be called.
UI:RelearnMenu(RogueEssence.Dungeon.Character)
Displays the Relearn menu for a character.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the integer representing the chosen skill, UI:ChoiceResult() must be called.
Arguments
chara: The character to relearn skills
UI:LearnMenu(RogueEssence.Dungeon.Character,System.String)
Displays the Learn menu for a character to replace an existing skill with a new one.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the integer representing the chosen skill, UI:ChoiceResult() must be called.
Arguments
chara: The character to relearn skillsskillNum: The new skill
UI:ForgetMenu(RogueEssence.Dungeon.Character)
Displays the Forget menu for a character to forget a skill.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the integer representing the chosen skill, UI:ChoiceResult() must be called.
Arguments
chara: The character to relearn skills
UI:ShowPromoteMenu
Displays the Promote menu to choose a team member to promote.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the integer representing the chosen team slot, UI:ChoiceResult() must be called.
UI:CanSwapMenu(NLua.LuaTable)
TODO
UI:SwapMenu(NLua.LuaTable,NLua.LuaTable)
TODO
UI:TributeMenu(System.Int32)
TODO
UI:ShowMusicMenu(NLua.LuaTable)
Displays the Music menu to browse music for the game.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the string representing the chosen song, UI:ChoiceResult() must be called.
Arguments
spoilerUnlocks: A lua table of strings representing progression flags that have been completed.
Any ogg file that uses this tag as a spoiler tag will display in the menu only if the flag has been passed.
UI:DungeonChoice(System.String,RogueEssence.Dungeon.ZoneLoc)
Ask to enter a destintion via character dialogue to the player. UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the integer value indicating the result of the menu, UI:ChoiceResult() must be called.
The Yes/No menu returns 1 for yes, and 0 for no.
Arguments
name: Name of the destinationdest: The ZoneLoc location of the destination.
UI:DestinationMenu(NLua.LuaTable,System.Object)
Marks the start of a choice menu for choosing destinations, showing a preview of restrictions and requirements for dungeons. UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the ZoneLoc indicating the chosen destination, UI:ChoiceResult() must be called.
Arguments
destinations: A lua table representing the list of destinations with each element in the format of { Name=string, Dest=ZoneLoc }
UI:ServersMenu
TODO
UI:ContactsMenu
TODO
UI:SOSMenu
TODO
UI:AOKMenu
TODO
UI:PeersMenu
TODO
UI:ShowConnectMenu
TODO
UI:CurrentActivityMenu
TODO
UI:ChooseMonsterMenu(System.String,NLua.LuaTable,System.Boolean,System.Boolean,System.Int32)
Marks the start of a choice menu for choosing monsters, showing a preview of their appearances via portrait. UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the string indicating the chosen species, UI:ChoiceResult() must be called.
Arguments
title: The title of the menuchoices: A lua table of choices with each element being a MonsterID.canMenu: If set to true, the Menu Button exits the menu if pressed.canCancel: If set to true, the Cancel Button exits the menu if pressed.slotsPerPage: Slots to display per page
UI:SetCustomMenu(RogueEssence.Menu.InteractableMenu)
Displays a custom menu of the caller's choice.
UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the menu is exited.
UI:BeginChoiceMenu(System.String,NLua.LuaTable,System.Object,System.Object,NLua.LuaTable)
Marks the start of a multi-choice menu. UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the integer value indicating the result of the menu, UI:ChoiceResult() must be called.
Arguments
message: The question to ask the user.choicesPairs: A table of choices. Each choice can be either a string, or { string, bool } representing the text and enabled status.defaultChoice: The cursor starts on this choice.cancelChoice: This choice is chosen if the player presses the cancel button.callbacks: The Lua table of callbacks for the textbox to call.
UI:BeginMultiPageMenu(System.Int32,System.Int32,System.Int32,System.String,NLua.LuaTable,System.Int32,System.Object,System.Object)
Marks the start of a multi-paged choice menu. UI:WaitForChoice() must be called afterwards for the menu to be actually displayed, and for execution to suspend until the choice is returned. Then to recover the integer value indicating the result of the menu, UI:ChoiceResult() must be called.
Arguments
x: X position of the menuy: Y position of the menuwidth: Width of the menutitle: Height of the menuchoicesPairs: A table of choices. Each choice can be either a string, or { string, bool } representing the text and enabled status.linesPerPage: Number of choices per pagedefaultChoice: The cursor starts on this choice.cancelChoice: This choice is chosen if the player presses the cancel button.
UI:ChoiceResult
Get the result of the last choice menu
Returns
The result of the choice
UI:GetChoiceAction(System.Object)
It's complicated.
Arguments
obj: None
UI:WaitForChoice
Displays the currently set choice menu and waits for the player's selection to complete.
Example
UI:WaitForChoice()
UI:__WaitForChoice
Wait for choice and then CLEAN UP m_curchoice
