Class PointsView

java.lang.Object
view.itemsAndRewards.PointsView

public class PointsView extends Object
The PointsView class represents the view for the PointsModel class. It handles drawing the points with a fading effect.
  • Constructor Details

    • PointsView

      public PointsView(PointsModel pointsModel)
      Constructs a PointsView with the specified PointsModel.
      Parameters:
      pointsModel - the model of the points item
  • Method Details

    • draw

      public void draw(Graphics2D g)
      Draws the points on the screen with a fading effect.
      Parameters:
      g - the Graphics2D object to draw with
    • isActive

      protected boolean isActive()
      Checks if the points item is active.
      Returns:
      true if the points item is active, false otherwise
    • getPointsModel

      protected PointsModel getPointsModel()
      Returns the PointsModel associated with this view.
      Returns:
      the PointsModel