Class OfflineFitness

java.lang.Object
nl.minetopiasdb.api.playerdata.fitness.objects.OfflineFitness
All Implemented Interfaces:
Fitness

public class OfflineFitness extends Object implements Fitness
Fitness object for offline players
  • Constructor Summary

    Constructors
    Constructor
    Description
    OfflineFitness​(UUID uuid, int total, int drinkingPoints, int fitGainedByDrinking, int fitGainedByWalking, int fitGainedBySprinting, int fitGainedByClimbing, int fitGainedByFlying, int fitGainedBySwimming, int healthPoints, int fitGainedByHealth, int healthyFood, int unhealthyFood, int fitGainedByFood)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    Get the amount of drinking points this player has
    int
    Get the amount of total fitness gained by climbing
    int
    Get the amount of total fitness gained by drinking
    int
    Get the amount of total fitness gained by flying
    int
    Get the amount of total fitness gained by eating
    int
    Get the amount of total fitness gained by health points.
    int
    Get the amount of total fitness gained by sprinting
    int
    Get the amount of total fitness gained by swimming
    int
    Get the amount of total fitness gained by walking
    int
    Get the amount of health points this player has
    int
    Get the amount of healthy food points this player has
    int
    Get the total fitness (fitness as displayed in scoreboard) for this player
    int
    Get the amount of unhealthy food points this player has
    void
    setDrinkingPoints​(int drinkingPoints)
    Set the amount of drinking points this player has.
    void
    setDrinkingPointsSilent​(int drinkingPoints)
    Set the amount of drinking points this player has without communicating it through message channels.
    void
    setFitGainedByClimbing​(int fitGainedByClimbing)
    Set the amount of fitness gained by climbing
    void
    setFitGainedByClimbingSilent​(int fitGainedByClimbing)
    Set the amount of fitness gained by climbing without communicating it through message channels.
    void
    setFitGainedByDrinking​(int fitGainedByDrinking)
    Set the amount of fitness gained by drinking
    void
    setFitGainedByDrinkingSilent​(int fitGainedByDrinking)
    Set the amount of fitness gained by drinking without communicating it through message channels.
    void
    setFitGainedByFlying​(int fitGainedByFlying)
    Set the amount of fitness gained by flying
    void
    setFitGainedByFlyingSilent​(int fitGainedByFlying)
    Set the amount of fitness gained by flying without communicating it through message channels.
    void
    setFitGainedByFood​(int fitGainedByFood)
    Set the amount of fitness gained by eating
    void
    setFitGainedByFoodSilent​(int fitGainedByFood)
    Set the amount of fitness gained by eating without communicating it through message channels.
    void
    setFitGainedByHealth​(int fitGainedByHealth)
    Set the amount of fitness gained by health points
    void
    setFitGainedByHealthSilent​(int fitGainedByHealth)
    Set the amount of fitness gained by health points without communicating it through message channels.
    void
    setFitGainedBySprinting​(int fitGainedBySprinting)
    Set the amount of fitness gained by sprinting
    void
    setFitGainedBySprintingSilent​(int fitGainedBySprinting)
    Set the amount of fitness gained by sprinting without communicating it through message channels.
    void
    setFitGainedBySwimming​(int fitGainedBySwimming)
    Set the amount of fitness gained by swimming
    void
    setFitGainedBySwimmingSilent​(int fitGainedBySwimming)
    Set the amount of fitness gained by swimming without communicating it through message channels.
    void
    setFitGainedByWalking​(int fitGainedByWalking)
    Set the amount of fitness gained by walking
    void
    setFitGainedByWalkingSilent​(int fitGainedByWalking)
    Set the amount of fitness gained by walking without communicating it through message channels.
    void
    setHealthPoints​(int healthPoints)
    Set the amount of health points this player has.
    void
    setHealthPointsSilent​(int healthPoints)
    Set the amount of health points this player has without communicating it through message channels.
    void
    setHealthyFoodPoints​(int healthyFood)
    Set the amount of healthy food points this player has.
    void
    setHealthyFoodPointsSilent​(int healthyFood)
    Set the amount of healthy food points this player has without communicating it through message channels.
    void
    setTotalFitness​(int total)
    Set the total fitness for this player
    void
    setTotalFitnessSilent​(int total)
    Set the total fitness for this player without communicating it through message channels.
    void
    setUnhealthyFoodPoints​(int unhealthyFood)
    Set the amount of unhealthy food points this player has.
    void
    setUnhealthyFoodPointsSilent​(int unhealthyFood)
    Set the amount of unhealthy food points this player has without communicating it through message channels.

    Methods inherited from class java.lang.Object

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

    • OfflineFitness

      public OfflineFitness(UUID uuid, int total, int drinkingPoints, int fitGainedByDrinking, int fitGainedByWalking, int fitGainedBySprinting, int fitGainedByClimbing, int fitGainedByFlying, int fitGainedBySwimming, int healthPoints, int fitGainedByHealth, int healthyFood, int unhealthyFood, int fitGainedByFood)
  • Method Details

    • getTotalFitness

      public int getTotalFitness()
      Get the total fitness (fitness as displayed in scoreboard) for this player
      Specified by:
      getTotalFitness in interface Fitness
      Returns:
      total fitness
    • setTotalFitness

      public void setTotalFitness(int total)
      Set the total fitness for this player
      Specified by:
      setTotalFitness in interface Fitness
      Parameters:
      total - new total fitness
    • getDrinkingPoints

      public int getDrinkingPoints()
      Get the amount of drinking points this player has
      Specified by:
      getDrinkingPoints in interface Fitness
      Returns:
      drinking points
    • setDrinkingPoints

      public void setDrinkingPoints(int drinkingPoints)
      Set the amount of drinking points this player has. Once a player has 1000 drinking points, he will gain one fitness point.
      Specified by:
      setDrinkingPoints in interface Fitness
      Parameters:
      drinkingPoints - drinking points
    • getFitGainedByDrinking

      public int getFitGainedByDrinking()
      Get the amount of total fitness gained by drinking
      Specified by:
      getFitGainedByDrinking in interface Fitness
      Returns:
      fitness gained by drinking
    • setFitGainedByDrinking

      public void setFitGainedByDrinking(int fitGainedByDrinking)
      Set the amount of fitness gained by drinking
      Specified by:
      setFitGainedByDrinking in interface Fitness
      Parameters:
      fitGainedByDrinking - fitness gained by drinking
    • getFitGainedByWalking

      public int getFitGainedByWalking()
      Get the amount of total fitness gained by walking
      Specified by:
      getFitGainedByWalking in interface Fitness
      Returns:
      fitness gained by walking
    • setFitGainedByWalking

      public void setFitGainedByWalking(int fitGainedByWalking)
      Set the amount of fitness gained by walking
      Specified by:
      setFitGainedByWalking in interface Fitness
      Parameters:
      fitGainedByWalking - fitness gained by walking
    • getFitGainedBySprinting

      public int getFitGainedBySprinting()
      Get the amount of total fitness gained by sprinting
      Specified by:
      getFitGainedBySprinting in interface Fitness
      Returns:
      fitness gained by sprinting
    • setFitGainedBySprinting

      public void setFitGainedBySprinting(int fitGainedBySprinting)
      Set the amount of fitness gained by sprinting
      Specified by:
      setFitGainedBySprinting in interface Fitness
      Parameters:
      fitGainedBySprinting - fitness gained by sprinting
    • getFitGainedByClimbing

      public int getFitGainedByClimbing()
      Get the amount of total fitness gained by climbing
      Specified by:
      getFitGainedByClimbing in interface Fitness
      Returns:
      fitness gained by climbing
    • setFitGainedByClimbing

      public void setFitGainedByClimbing(int fitGainedByClimbing)
      Set the amount of fitness gained by climbing
      Specified by:
      setFitGainedByClimbing in interface Fitness
      Parameters:
      fitGainedByClimbing - fitness gained by climbing
    • getFitGainedBySwimming

      public int getFitGainedBySwimming()
      Get the amount of total fitness gained by swimming
      Specified by:
      getFitGainedBySwimming in interface Fitness
      Returns:
      fitness gained by swimming
    • setFitGainedBySwimming

      public void setFitGainedBySwimming(int fitGainedBySwimming)
      Set the amount of fitness gained by swimming
      Specified by:
      setFitGainedBySwimming in interface Fitness
      Parameters:
      fitGainedBySwimming - fitness gained by swimming
    • getFitGainedByFlying

      public int getFitGainedByFlying()
      Get the amount of total fitness gained by flying
      Specified by:
      getFitGainedByFlying in interface Fitness
      Returns:
      fitness gained by flying
    • setFitGainedByFlying

      public void setFitGainedByFlying(int fitGainedByFlying)
      Set the amount of fitness gained by flying
      Specified by:
      setFitGainedByFlying in interface Fitness
      Parameters:
      fitGainedByFlying - fitness gained by flying
    • getHealthPoints

      public int getHealthPoints()
      Get the amount of health points this player has
      Specified by:
      getHealthPoints in interface Fitness
      Returns:
      health points
    • setHealthPoints

      public void setHealthPoints(int healthPoints)
      Set the amount of health points this player has.
      Specified by:
      setHealthPoints in interface Fitness
      Parameters:
      healthPoints - health points
    • getFitGainedByHealth

      public int getFitGainedByHealth()
      Get the amount of total fitness gained by health points. You can get health points by having at least 9/10 hearts. You can lose them by having less than 5.
      Specified by:
      getFitGainedByHealth in interface Fitness
      Returns:
      fitness gained by health points
    • setFitGainedByHealth

      public void setFitGainedByHealth(int fitGainedByHealth)
      Set the amount of fitness gained by health points
      Specified by:
      setFitGainedByHealth in interface Fitness
      Parameters:
      fitGainedByHealth - fitness gained by health points
    • getHealthyFoodPoints

      public int getHealthyFoodPoints()
      Get the amount of healthy food points this player has
      Specified by:
      getHealthyFoodPoints in interface Fitness
      Returns:
      healthy food points
    • setHealthyFoodPoints

      public void setHealthyFoodPoints(int healthyFood)
      Set the amount of healthy food points this player has.
      Specified by:
      setHealthyFoodPoints in interface Fitness
      Parameters:
      healthyFood - healthy food points
    • getUnhealthyFoodPoints

      public int getUnhealthyFoodPoints()
      Get the amount of unhealthy food points this player has
      Specified by:
      getUnhealthyFoodPoints in interface Fitness
      Returns:
      unhealthy food points
    • setUnhealthyFoodPoints

      public void setUnhealthyFoodPoints(int unhealthyFood)
      Set the amount of unhealthy food points this player has.
      Specified by:
      setUnhealthyFoodPoints in interface Fitness
      Parameters:
      unhealthyFood - unhealthy food points
    • getFitGainedByFood

      public int getFitGainedByFood()
      Get the amount of total fitness gained by eating
      Specified by:
      getFitGainedByFood in interface Fitness
      Returns:
      fitness gained by eating
    • setFitGainedByFood

      public void setFitGainedByFood(int fitGainedByFood)
      Set the amount of fitness gained by eating
      Specified by:
      setFitGainedByFood in interface Fitness
      Parameters:
      fitGainedByFood - fitness gained by health eating
    • setTotalFitnessSilent

      public void setTotalFitnessSilent(int total)
      Set the total fitness for this player without communicating it through message channels. Please use Fitness.setTotalFitness(int) instead.
      Specified by:
      setTotalFitnessSilent in interface Fitness
      Parameters:
      total - new total fitness
    • setDrinkingPointsSilent

      public void setDrinkingPointsSilent(int drinkingPoints)
      Set the amount of drinking points this player has without communicating it through message channels. Please use Fitness.setDrinkingPoints(int) instead.
      Specified by:
      setDrinkingPointsSilent in interface Fitness
      Parameters:
      drinkingPoints - drinking points
    • setFitGainedByDrinkingSilent

      public void setFitGainedByDrinkingSilent(int fitGainedByDrinking)
      Set the amount of fitness gained by drinking without communicating it through message channels. Please use Fitness.setFitGainedByDrinking(int) instead.
      Specified by:
      setFitGainedByDrinkingSilent in interface Fitness
      Parameters:
      fitGainedByDrinking - fitness gained by drinking
    • setFitGainedByWalkingSilent

      public void setFitGainedByWalkingSilent(int fitGainedByWalking)
      Set the amount of fitness gained by walking without communicating it through message channels. Please use Fitness.setFitGainedByWalking(int) instead.
      Specified by:
      setFitGainedByWalkingSilent in interface Fitness
      Parameters:
      fitGainedByWalking - fitness gained by walking
    • setFitGainedBySprintingSilent

      public void setFitGainedBySprintingSilent(int fitGainedBySprinting)
      Set the amount of fitness gained by sprinting without communicating it through message channels. Please use Fitness.setFitGainedBySprinting(int) instead.
      Specified by:
      setFitGainedBySprintingSilent in interface Fitness
      Parameters:
      fitGainedBySprinting - fitness gained by sprinting
    • setFitGainedByClimbingSilent

      public void setFitGainedByClimbingSilent(int fitGainedByClimbing)
      Set the amount of fitness gained by climbing without communicating it through message channels. Please use Fitness.setFitGainedByClimbing(int) instead.
      Specified by:
      setFitGainedByClimbingSilent in interface Fitness
      Parameters:
      fitGainedByClimbing - fitness gained by climbing
    • setFitGainedBySwimmingSilent

      public void setFitGainedBySwimmingSilent(int fitGainedBySwimming)
      Set the amount of fitness gained by swimming without communicating it through message channels. Please use Fitness.setFitGainedBySwimming(int) instead.
      Specified by:
      setFitGainedBySwimmingSilent in interface Fitness
      Parameters:
      fitGainedBySwimming - fitness gained by swimming
    • setFitGainedByFlyingSilent

      public void setFitGainedByFlyingSilent(int fitGainedByFlying)
      Set the amount of fitness gained by flying without communicating it through message channels. Please use Fitness.setFitGainedByFlying(int) instead.
      Specified by:
      setFitGainedByFlyingSilent in interface Fitness
      Parameters:
      fitGainedByFlying - fitness gained by flying
    • setHealthPointsSilent

      public void setHealthPointsSilent(int healthPoints)
      Set the amount of health points this player has without communicating it through message channels. Please use Fitness.setHealthPoints(int) instead.
      Specified by:
      setHealthPointsSilent in interface Fitness
      Parameters:
      healthPoints - health points
    • setFitGainedByHealthSilent

      public void setFitGainedByHealthSilent(int fitGainedByHealth)
      Set the amount of fitness gained by health points without communicating it through message channels. Please use Fitness.setFitGainedByHealth(int) instead.
      Specified by:
      setFitGainedByHealthSilent in interface Fitness
      Parameters:
      fitGainedByHealth - fitness gained by health points
    • setHealthyFoodPointsSilent

      public void setHealthyFoodPointsSilent(int healthyFood)
      Set the amount of healthy food points this player has without communicating it through message channels. Please use Fitness.setHealthyFoodPoints(int)
      Specified by:
      setHealthyFoodPointsSilent in interface Fitness
      Parameters:
      healthyFood - healthy food points
    • setUnhealthyFoodPointsSilent

      public void setUnhealthyFoodPointsSilent(int unhealthyFood)
      Set the amount of unhealthy food points this player has without communicating it through message channels. Please use Fitness.setUnhealthyFoodPoints(int)
      Specified by:
      setUnhealthyFoodPointsSilent in interface Fitness
      Parameters:
      unhealthyFood - unhealthy food points
    • setFitGainedByFoodSilent

      public void setFitGainedByFoodSilent(int fitGainedByFood)
      Set the amount of fitness gained by eating without communicating it through message channels. Please use Fitness.setFitGainedByHealth(int)
      Specified by:
      setFitGainedByFoodSilent in interface Fitness
      Parameters:
      fitGainedByFood - fitness gained by health eating