Class ScreenManager

ScreenManager singleton

Methods

ScreenManager:AddNewScreenToTop (string, sScreenName, string, sMessage) Adds a screen at the top of the screen stack.
ScreenManager:GetTopScreen () Gets the screen at the top of the screen stack.
ScreenManager:get_input_redirected (PlayerNumber, pn) Returns whether the input for the player has been redirected away from the normal screen input function.
ScreenManager:PlayInvalidSound () Plays the invalid sound.
ScreenManager:PlayStartSound () Plays the start sound.
ScreenManager:PlayCoinSound () Plays the coin sound.
ScreenManager:PlayCancelSound () Plays the cancel sound.
ScreenManager:PlayScreenshotSound () Plays the screenshot sound.
ScreenManager:ReloadOverlayScreens () Reloads any loaded overlay screens.
ScreenManager:ScreenClassExists (string, s) Returns true if screen class s exists.
ScreenManager:ScreenIsPrepped (string, s) Returns true if screen s is prepared.
ScreenManager:SetNewScreen (string, s) Sets the next screen to s.
ScreenManager:set_input_redirected (PlayerNumber, pn, bool, redir) Sets whether the input for the player has been redirected away from the normal screen input function.
ScreenManager:SystemMessage (string, s) Broadcasts a system message.


Methods

ScreenManager:AddNewScreenToTop (string, sScreenName, string, sMessage)
Adds a screen at the top of the screen stack. (sMessage is an optional ScreenMessage posted once the new screen is finished.)

Parameters:

  • string
  • sScreenName
  • string
  • sMessage

Returns:

    void
ScreenManager:GetTopScreen ()
Gets the screen at the top of the screen stack.

Returns:

    Screen
ScreenManager:get_input_redirected (PlayerNumber, pn)
Returns whether the input for the player has been redirected away from the normal screen input function. Input that has been redirected is only sent to lua input callbacks.

Parameters:

  • PlayerNumber
  • pn

Returns:

    bool
ScreenManager:PlayInvalidSound ()
Plays the invalid sound.

Returns:

ScreenManager:PlayStartSound ()
Plays the start sound.

Returns:

ScreenManager:PlayCoinSound ()
Plays the coin sound.

Returns:

ScreenManager:PlayCancelSound ()
Plays the cancel sound.

Returns:

ScreenManager:PlayScreenshotSound ()
Plays the screenshot sound.

Returns:

ScreenManager:ReloadOverlayScreens ()
Reloads any loaded overlay screens.

Returns:

    void
ScreenManager:ScreenClassExists (string, s)
Returns true if screen class s exists.

Parameters:

  • string
  • s

Returns:

    bool
ScreenManager:ScreenIsPrepped (string, s)
Returns true if screen s is prepared.

Parameters:

  • string
  • s

Returns:

    bool
ScreenManager:SetNewScreen (string, s)
Sets the next screen to s.

Parameters:

  • string
  • s

Returns:

    void
ScreenManager:set_input_redirected (PlayerNumber, pn, bool, redir)

Sets whether the input for the player has been redirected away from the normal screen input function. Input that has been redirected is only sent to lua input callbacks.

    This can be useful when putting a custom menu on a screen, and you want to disable the built in actors while the menu is open.  Then you handle input through an input callback until the player closes the menu.

Parameters:

  • PlayerNumber
  • pn
  • bool
  • redir

Returns:

    bool
ScreenManager:SystemMessage (string, s)
Broadcasts a system message.

Parameters:

  • string
  • s

Returns:

    void
generated by LDoc 1.4.6 Last updated 2023-01-15 03:25:11