UI (functions)/Fade Effects

From PMDOWiki
More functions: Script Reference

This page documents the ScriptUI class for Lua scripting.

As a singleton class, it can be accessed from Lua with UI.

WaitShowVoiceOver

UI:WaitShowVoiceOver(text, expireTime, x, y, width, height, callbacks)

Displays a voice over, waiting until the player completes it.

Parameters

Name Type Description
System.String System.String The text to display.
System.Int32 System.Int32 The time for the textbox to remain on screen. Pass -1 to wait for player input.
System.Int32 System.Int32 The starting X position of the box
System.Int32 System.Int32 The starting Y position of the box
System.Int32 System.Int32 The width of the box
System.Int32 System.Int32 The height of the box
NLua.LuaTable NLua.LuaTable A Lua table of callbacks that the textbox can call using the [script] tag.

Returns

Type Description
NLua.LuaFunction


TextVoiceOver

UI:TextVoiceOver(text, expireTime, x, y, width, height, callbacks)

[LuaFunction] WaitShowVoiceOver
Sets the current voice-over text to be shown. Requires WaitDialog to actually display.

Parameters

Name Type Description
System.String System.String The text to display.
System.Int32 System.Int32 The time for the textbox to remain on screen. Pass -1 to wait for player input.
System.Int32 System.Int32 The starting X position of the box
System.Int32 System.Int32 The starting Y position of the box
System.Int32 System.Int32 The width of the box
System.Int32 System.Int32 The height of the box
NLua.LuaTable NLua.LuaTable A Lua table of callbacks that the textbox can call using the [script] tag.


TextPopUp

UI:TextPopUp(text, expireTime, x, y, width, height, centerH, centerV)

Makes text pop up in the bottom-left corner by default. Displays concurrently with any other process.

Parameters

Name Type Description
System.String System.String The text to display.
System.Int32 System.Int32 The time for the textbox to remain on screen. Pass -1 to wait for player input.
System.Int32 System.Int32 The starting X position of the box
System.Int32 System.Int32 The starting Y position of the box
System.Int32 System.Int32 The width of the box
System.Int32 System.Int32 The height of the box
System.Boolean System.Boolean If true, centers the text horizontally.
System.Boolean System.Boolean If true, centers the text vertically.


WaitShowTitle

UI:WaitShowTitle(text, time)

Fades in text in the format of a title drop, then waits until the fade-in is complete.

Parameters

Name Type Description
System.String System.String The text to display.
System.Int32 System.Int32 The time it takes for the text to fade in, in frames.

Returns

Type Description
NLua.LuaFunction


TextShowTitle

UI:TextShowTitle(text, time)

[LuaFunction] WaitShowTitle
Fades in text in the format of a title drop. Requires WaitDialog to actually display.

Parameters

Name Type Description
System.String System.String The text to display.
System.Int32 System.Int32 The time it takes for the text to fade in, in frames.


WaitHideTitle

UI:WaitHideTitle(time)

Fades out the text set in a title drop, waiting until the fade-out is complete.

Parameters

Name Type Description
System.Int32 System.Int32 The time it takes for the text to fade out, in frames.

Returns

Type Description
NLua.LuaFunction


TextFadeTitle

UI:TextFadeTitle(time)

[LuaFunction] WaitHideTitle
Fades out the text set in a title drop. Requires WaitDialog to actually fade.

Parameters

Name Type Description
System.Int32 System.Int32 The time it takes for the text to fade out, in frames.


WaitShowBG

UI:WaitShowBG(bg, frameTime, fadeInTime)

Fades in a chosen background image, with a chosen framerate, at a certain fade time, waiting until the fade-in is complete.

Parameters

Name Type Description
System.String System.String The background to show, from the list of BG textures.
System.Int32 System.Int32 Framerate of the image animation.
System.Int32 System.Int32 Time taken to fade in the image.

Returns

Type Description
NLua.LuaFunction


ShowBG

UI:ShowBG(bg, frameTime, fadeInTime)

[LuaFunction] WaitShowBG
Prepares to fade in a chosen background image, with a chosen framerate, at a certain fade time. Requires WaitDialog to actually display.

Parameters

Name Type Description
System.String System.String The background to show, from the list of BG textures.
System.Int32 System.Int32 Framerate of the image animation.
System.Int32 System.Int32 Time taken to fade in the image.


WaitHideBG

UI:WaitHideBG(time)

Fades out the current background image, waiting until the fade-out is complete.

Parameters

Name Type Description
System.Int32 System.Int32 Time taken to fade out the image.

Returns

Type Description
NLua.LuaFunction


FadeBG

UI:FadeBG(time)

[LuaFunction] WaitHideBG
Prepares a fade-out of the current image. Requires WaitDialog to actually display.

Parameters

Name Type Description
System.Int32 System.Int32 Time taken to fade out the image.


References

https://github.com/RogueCollab/RogueEssence/blob/master/RogueEssence/Lua/ScriptUIFadeEffects.cs