Fixing an error due to confusingly named check

Refactored healthBarEnabled to healthBarPluginEnabled to avoid this
from happening again.
This commit is contained in:
TfT_02 2013-09-29 23:57:13 +02:00
parent 4c7fb1854d
commit 3a37d0e092
2 changed files with 6 additions and 6 deletions

View File

@ -77,7 +77,7 @@ public class mcMMO extends JavaPlugin {
/* Plugin Checks */ /* Plugin Checks */
private static boolean combatTagEnabled; private static boolean combatTagEnabled;
private static boolean healthBarEnabled; private static boolean healthBarPluginEnabled;
// Config Validation Check // Config Validation Check
public boolean noErrorsInConfigFiles = true; public boolean noErrorsInConfigFiles = true;
@ -118,9 +118,9 @@ public class mcMMO extends JavaPlugin {
} }
combatTagEnabled = getServer().getPluginManager().getPlugin("CombatTag") != null; combatTagEnabled = getServer().getPluginManager().getPlugin("CombatTag") != null;
healthBarEnabled = getServer().getPluginManager().getPlugin("HealthBar") != null; healthBarPluginEnabled = getServer().getPluginManager().getPlugin("HealthBar") != null;
if (healthBarEnabled) { if (healthBarPluginEnabled) {
getLogger().info("HealthBar plugin found, mcMMO's healthbars are automatically disabled."); getLogger().info("HealthBar plugin found, mcMMO's healthbars are automatically disabled.");
} }
@ -266,8 +266,8 @@ public class mcMMO extends JavaPlugin {
return combatTagEnabled; return combatTagEnabled;
} }
public static boolean isHealthBarEnabled() { public static boolean isHealthBarPluginEnabled() {
return healthBarEnabled; return healthBarPluginEnabled;
} }
/** /**

View File

@ -40,7 +40,7 @@ public final class MobHealthbarUtils {
* @param damage damage done by the attack triggering this * @param damage damage done by the attack triggering this
*/ */
public static void handleMobHealthbars(Player player, LivingEntity target, double damage) { public static void handleMobHealthbars(Player player, LivingEntity target, double damage) {
if (!mcMMO.isHealthBarEnabled() || !Permissions.mobHealthDisplay(player)) { if (mcMMO.isHealthBarPluginEnabled() || !Permissions.mobHealthDisplay(player)) {
return; return;
} }