Class MazePlayerScoreDisplay

All Implemented Interfaces:
com.badlogic.gdx.utils.Disposable, Renderable, Comparable<Renderable>

public class MazePlayerScoreDisplay extends UIComponent
Class to show the score and medal thresholds on the game screen
  • Constructor Details

    • MazePlayerScoreDisplay

      public MazePlayerScoreDisplay()
  • Method Details

    • create

      public void create()
      Adds actors to the stage.
      Overrides:
      create in class UIComponent
    • draw

      public void draw(com.badlogic.gdx.graphics.g2d.SpriteBatch batch)
      Draw is handles by the stage
      Specified by:
      draw in class RenderComponent
      Parameters:
      batch - Batch to render to.
    • updatePlayerScoreUI

      public void updatePlayerScoreUI(int score)
      Updates the player's score on the ui.
      Parameters:
      score - the players score
    • dispose

      public void dispose()
      Disposes of heart image and label
      Specified by:
      dispose in interface com.badlogic.gdx.utils.Disposable
      Overrides:
      dispose in class RenderComponent