public void subtractLearningPoints(int subtract, boolean display) { this.LP -= subtract; if (display) { Utils.sendPrivateMessage( CommandLevel.WARNING, "You have lost " + subtract + " learning points.", Bukkit.getServer().getPlayer(this.name)); this.updateLearningPoints(); } }
public void addLearningPoints(int newAmount, boolean display) { this.LP += newAmount; if (display) { Utils.sendPrivateMessage( CommandLevel.REWARD, "You have gained " + newAmount + " learning points.", Bukkit.getServer().getPlayer(this.name)); this.updateLearningPoints(); } }
// Sends the player the amount of learn points he has. public void updateLearningPoints() { Utils.sendPrivateMessage( CommandLevel.NOTIFICATION, "You currently have " + this.getLearningPoints() + " learning points.", Bukkit.getServer().getPlayer(this.name)); }