Package view

Class Gui

java.lang.Object
view.Gui

public class Gui
extends java.lang.Object
  • Constructor Summary

    Constructors 
    Constructor Description
    Gui()
    Constructorclass that creates the startscreen that the user is faced with.
  • Method Summary

    Modifier and Type Method Description
    void aboutButton​(java.awt.event.ActionListener action)  
    void buildAboutUsScreen()
    Builds the screen that is shown when the player wants to read "about us".
    void buildHighscoreScreen​(java.util.ArrayList highscoreList)  
    void buildLoserScreen()
    builds the screen that is shown when the user fails a level.
    void buildPauseScreen()
    Builds the screen that is shown wile the game is in pausemode.
    void buildPlayScreen()
    Builds the full screen that is shown wile the user is playing the game.
    void buildVictoryScreen()
    Builds the screen that is shown when the user finishes a level.
    void buyPlainButton​(java.awt.event.ActionListener action)  
    void buySoldierButton​(java.awt.event.ActionListener action)  
    void drawNextFrame​(java.awt.image.BufferedImage nextFrameImage)
    Changes the image in the middle panel when the user is in playmode to make it look like the troops are moving etc.
    void enabledTroopButtons​(java.lang.Boolean b)  
    void enableEnterTPButton​(java.lang.Boolean b)  
    void enableExitTPButton​(java.lang.Boolean b)  
    void enablePlaneButton​(java.lang.Boolean b)  
    void enableSoldierButton​(java.lang.Boolean b)  
    void exitButton​(java.awt.event.ActionListener action)  
    java.lang.String getName()  
    int getPanelHeight()  
    int getPanelWidth()  
    void helpButton​(java.awt.event.ActionListener action)  
    void highscoreButton​(java.awt.event.ActionListener action)  
    void newGameResumeNextLevelButton​(java.awt.event.ActionListener action)  
    void pauseButton​(java.awt.event.ActionListener action)  
    void placeEnterTPButton​(java.awt.event.ActionListener action)  
    void placeExitTPButton​(java.awt.event.ActionListener action)  
    void restartLevelButton​(java.awt.event.ActionListener action)  
    void setMouseListener​(java.awt.event.MouseListener mouse)  
    void show()
    Sets the gui visible
    void showPauseButton​(java.lang.Boolean b)  
    void straightAhead​(java.awt.event.ActionListener action)  
    void turnLeft​(java.awt.event.ActionListener action)  
    void turnRight​(java.awt.event.ActionListener action)  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • Gui

      public Gui()
      Constructorclass that creates the startscreen that the user is faced with.
  • Method Details

    • buildPlayScreen

      public void buildPlayScreen()
      Builds the full screen that is shown wile the user is playing the game.
    • buildPauseScreen

      public void buildPauseScreen()
      Builds the screen that is shown wile the game is in pausemode.
    • buildVictoryScreen

      public void buildVictoryScreen()
      Builds the screen that is shown when the user finishes a level.
    • buildLoserScreen

      public void buildLoserScreen()
      builds the screen that is shown when the user fails a level.
    • buildAboutUsScreen

      public void buildAboutUsScreen()
      Builds the screen that is shown when the player wants to read "about us".
    • buildHighscoreScreen

      public void buildHighscoreScreen​(java.util.ArrayList highscoreList)
    • drawNextFrame

      public void drawNextFrame​(java.awt.image.BufferedImage nextFrameImage)
      Changes the image in the middle panel when the user is in playmode to make it look like the troops are moving etc.
      Parameters:
      nextFrameImage -
    • show

      public void show()
      Sets the gui visible
    • showPauseButton

      public void showPauseButton​(java.lang.Boolean b)
    • enableSoldierButton

      public void enableSoldierButton​(java.lang.Boolean b)
    • enablePlaneButton

      public void enablePlaneButton​(java.lang.Boolean b)
    • enabledTroopButtons

      public void enabledTroopButtons​(java.lang.Boolean b)
    • enableEnterTPButton

      public void enableEnterTPButton​(java.lang.Boolean b)
    • enableExitTPButton

      public void enableExitTPButton​(java.lang.Boolean b)
    • getName

      public java.lang.String getName()
    • getPanelWidth

      public int getPanelWidth()
    • getPanelHeight

      public int getPanelHeight()
    • newGameResumeNextLevelButton

      public void newGameResumeNextLevelButton​(java.awt.event.ActionListener action)
    • pauseButton

      public void pauseButton​(java.awt.event.ActionListener action)
    • restartLevelButton

      public void restartLevelButton​(java.awt.event.ActionListener action)
    • exitButton

      public void exitButton​(java.awt.event.ActionListener action)
    • helpButton

      public void helpButton​(java.awt.event.ActionListener action)
    • aboutButton

      public void aboutButton​(java.awt.event.ActionListener action)
    • highscoreButton

      public void highscoreButton​(java.awt.event.ActionListener action)
    • turnRight

      public void turnRight​(java.awt.event.ActionListener action)
    • turnLeft

      public void turnLeft​(java.awt.event.ActionListener action)
    • straightAhead

      public void straightAhead​(java.awt.event.ActionListener action)
    • buySoldierButton

      public void buySoldierButton​(java.awt.event.ActionListener action)
    • buyPlainButton

      public void buyPlainButton​(java.awt.event.ActionListener action)
    • setMouseListener

      public void setMouseListener​(java.awt.event.MouseListener mouse)
    • placeEnterTPButton

      public void placeEnterTPButton​(java.awt.event.ActionListener action)
    • placeExitTPButton

      public void placeExitTPButton​(java.awt.event.ActionListener action)