Class StatisticsMock

java.lang.Object
be.seeseemelk.mockbukkit.statistic.StatisticsMock

public class StatisticsMock extends Object
An implementation of player statistics, similar to CraftStatistic
  • Constructor Details

    • StatisticsMock

      public StatisticsMock()
  • Method Details

    • setStatistic

      public void setStatistic(@NotNull @NotNull Statistic statistic, int value)
      Sets the given statistic for this player.
      Parameters:
      statistic - Statistic to set
      value - The value to set this statistic to
      See Also:
    • setStatistic

      public void setStatistic(@NotNull @NotNull Statistic statistic, @NotNull @NotNull Material material, int value)
      Sets the given statistic for this player for the given material.
      Parameters:
      statistic - Statistic to set
      material - Material to offset the statistic with
      value - The value to set this statistic to
      See Also:
    • setStatistic

      public void setStatistic(@NotNull @NotNull Statistic statistic, @NotNull @NotNull EntityType entityType, int value)
      Sets the given statistic for this player for the given entity.
      Parameters:
      statistic - Statistic to set
      entityType - EntityType to offset the statistic with
      value - The value to set this statistic to
      See Also:
    • incrementStatistic

      public void incrementStatistic(@NotNull @NotNull Statistic statistic, int value)
      Increments the given statistic for this player.
      Parameters:
      statistic - Statistic to increment
      value - Amount to increment this statistic by
      See Also:
    • incrementStatistic

      public void incrementStatistic(@NotNull @NotNull Statistic statistic, @NotNull @NotNull Material material, int value)
      Increments the given statistic for this player for the given material.
      Parameters:
      statistic - Statistic to increment
      material - Material to offset the statistic with
      value - Amount to increment this statistic by
      See Also:
    • incrementStatistic

      public void incrementStatistic(@NotNull @NotNull Statistic statistic, @NotNull @NotNull EntityType entityType, int value)
      Increments the given statistic for this player for the given entity.
      Parameters:
      statistic - Statistic to increment
      entityType - EntityType to offset the statistic with
      value - Amount to increment this statistic by
      See Also:
    • decrementStatistic

      public void decrementStatistic(@NotNull @NotNull Statistic statistic, int value)
      Decrements the given statistic for this player.
      Parameters:
      statistic - Statistic to decrement
      value - Amount to decrement this statistic by
      See Also:
    • decrementStatistic

      public void decrementStatistic(@NotNull @NotNull Statistic statistic, @NotNull @NotNull Material material, int value)
      Decrements the given statistic for this player for the given material.
      Parameters:
      statistic - Statistic to decrement
      material - Material to offset the statistic with
      value - Amount to decrement this statistic by
      See Also:
    • decrementStatistic

      public void decrementStatistic(@NotNull @NotNull Statistic statistic, @NotNull @NotNull EntityType entityType, int value)
      Decrements the given statistic for this player for the given entity.
      Parameters:
      statistic - Statistic to decrement
      entityType - EntityType to offset the statistic with
      value - Amount to decrement this statistic by for the statistic
      See Also:
    • getStatistic

      public int getStatistic(@NotNull @NotNull Statistic statistic)
      Gets the value of the given statistic for this player.
      Parameters:
      statistic - Statistic to check
      Returns:
      the value of the given statistic
      See Also:
    • getStatistic

      public int getStatistic(@NotNull @NotNull Statistic statistic, @NotNull @NotNull Material material)
      Gets the value of the given statistic for this player.
      Parameters:
      statistic - Statistic to check
      material - Material offset of the statistic
      Returns:
      the value of the given statistic
      See Also:
    • getStatistic

      public int getStatistic(@NotNull @NotNull Statistic statistic, @NotNull @NotNull EntityType entityType)
      Gets the value of the given statistic for this player.
      Parameters:
      statistic - Statistic to check
      entityType - EntityType offset of the statistic
      Returns:
      the value of the given statistic for the statistic
      See Also: