Diminished instead of Deminished

This commit is contained in:
TfT_02 2013-10-26 23:22:39 +02:00
parent f4d1004d32
commit 2a443cd9db
5 changed files with 7 additions and 7 deletions

View File

@ -180,8 +180,8 @@ public class ExperienceConfig extends AutoUpdateConfigLoader {
public double getCustomXpPerkBoost() { return config.getDouble("Experience_Formula.Custom_XP_Perk.Boost", 1.25); } public double getCustomXpPerkBoost() { return config.getDouble("Experience_Formula.Custom_XP_Perk.Boost", 1.25); }
/* Deminished Returns */ /* Deminished Returns */
public int getDeminishedReturnsThreshold() { return config.getInt("Deminished_Returns.Threshold", 20000); } public int getDiminishedReturnsThreshold() { return config.getInt("Diminished_Returns.Threshold", 20000); }
public int getDeminishedReturnsTimeInterval() { return config.getInt("Deminished_Returns.Time_Interval", 10); } public int getDiminishedReturnsTimeInterval() { return config.getInt("Diminished_Returns.Time_Interval", 10); }
/* Conversion */ /* Conversion */
public double getExpModifier() { return config.getDouble("Conversion.Exp_Modifier", 1); } public double getExpModifier() { return config.getDouble("Conversion.Exp_Modifier", 1); }

View File

@ -44,7 +44,7 @@ public class SelfListener implements Listener {
@EventHandler(priority = EventPriority.NORMAL, ignoreCancelled = true) @EventHandler(priority = EventPriority.NORMAL, ignoreCancelled = true)
public void onPlayerXpGain(McMMOPlayerXpGainEvent event) { public void onPlayerXpGain(McMMOPlayerXpGainEvent event) {
int threshold = ExperienceConfig.getInstance().getDeminishedReturnsThreshold(); int threshold = ExperienceConfig.getInstance().getDiminishedReturnsThreshold();
if (threshold <= 0) { if (threshold <= 0) {
// Diminished returns is turned off // Diminished returns is turned off

View File

@ -496,7 +496,7 @@ public class mcMMO extends JavaPlugin {
} }
// Clear the registered XP data so players can earn XP again // Clear the registered XP data so players can earn XP again
if (ExperienceConfig.getInstance().getDeminishedReturnsThreshold() > 0) { if (ExperienceConfig.getInstance().getDiminishedReturnsThreshold() > 0) {
new ClearRegisteredXPGainTask().runTaskTimer(this, 60 * 20, 60 * 20); new ClearRegisteredXPGainTask().runTaskTimer(this, 60 * 20, 60 * 20);
} }
} }

View File

@ -10,7 +10,7 @@ public class ClearRegisteredXPGainTask extends BukkitRunnable {
@Override @Override
public void run() { public void run() {
for (McMMOPlayer mcMMOPlayer : UserManager.getPlayers()) { for (McMMOPlayer mcMMOPlayer : UserManager.getPlayers()) {
mcMMOPlayer.getProfile().removeXpGainsOlderThan(ExperienceConfig.getInstance().getDeminishedReturnsTimeInterval() * 60 * 1000); mcMMOPlayer.getProfile().removeXpGainsOlderThan(ExperienceConfig.getInstance().getDiminishedReturnsTimeInterval() * 60 * 1000);
} }
} }
} }

View File

@ -60,9 +60,9 @@ Experience_Formula:
Boost: 1.25 Boost: 1.25
# #
# Settings for Deminished Returns # Settings for Diminished Returns
### ###
Deminished_Returns: Diminished_Returns:
# Limit the amount of experience a player can earn: # Limit the amount of experience a player can earn:
# Threshold (amount of experience) per Time_Interval (in minutes) # Threshold (amount of experience) per Time_Interval (in minutes)
Threshold: 20000 Threshold: 20000