Class PauseScreen

  • All Implemented Interfaces:
    com.badlogic.gdx.Screen

    public class PauseScreen
    extends java.lang.Object
    implements com.badlogic.gdx.Screen
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.lang.Runnable[] buttonActions
      Array of function pointers invoked by button presses.
      private Button[] buttons
      Array of buttons.
      private com.badlogic.gdx.graphics.g2d.BitmapFont font  
      private DragonBoatRace game
      The instance of teh game.
      private com.badlogic.gdx.graphics.g2d.GlyphLayout layout  
      private MainGameScreen previousScreen
      The screen which lead to this one.
      private java.lang.String title
      Title of this screen.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void dispose()  
      void hide()  
      void pause()  
      void render​(float delta)
      Renders the screen
      void resize​(int width, int height)  
      void resume()  
      private void save()
      Creating (or updating) the save.
      void show()  
      • Methods inherited from class java.lang.Object

        clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • buttonActions

        private final java.lang.Runnable[] buttonActions
        Array of function pointers invoked by button presses.
      • buttons

        private final Button[] buttons
        Array of buttons.
      • previousScreen

        private final MainGameScreen previousScreen
        The screen which lead to this one.
      • font

        private final com.badlogic.gdx.graphics.g2d.BitmapFont font
      • layout

        private final com.badlogic.gdx.graphics.g2d.GlyphLayout layout
    • Constructor Detail

      • PauseScreen

        public PauseScreen​(MainGameScreen previousScreen,
                           DragonBoatRace game)
        Instance of the pause screen
        Parameters:
        previousScreen - The screen where this screen was created
        game - instance of the game
    • Method Detail

      • save

        private void save()
        Creating (or updating) the save. Notifies the user when this is done.
      • show

        public void show()
        Specified by:
        show in interface com.badlogic.gdx.Screen
      • render

        public void render​(float delta)
        Renders the screen
        Specified by:
        render in interface com.badlogic.gdx.Screen
        Parameters:
        delta - time delta
      • resize

        public void resize​(int width,
                           int height)
        Specified by:
        resize in interface com.badlogic.gdx.Screen
      • pause

        public void pause()
        Specified by:
        pause in interface com.badlogic.gdx.Screen
      • resume

        public void resume()
        Specified by:
        resume in interface com.badlogic.gdx.Screen
      • hide

        public void hide()
        Specified by:
        hide in interface com.badlogic.gdx.Screen
      • dispose

        public void dispose()
        Specified by:
        dispose in interface com.badlogic.gdx.Screen