Fixed worldguard problem.

This commit is contained in:
Brianna 2019-12-10 18:57:34 -05:00
parent 30e1ccabb6
commit 61869ed80a
1 changed files with 5 additions and 5 deletions

View File

@ -58,11 +58,11 @@ public class BossLocationManager implements IReloadable {
} }
} }
if (WorldGuardHook.isEnabled()) {
if (WorldGuardHook.getBooleanFlag(location, "boss-blocked-region")) { Boolean flag;
ServerUtils.get().logDebug("Unable to spawn boss due to worldguard region having the 'boss-blocked-region' flag"); if ((flag = WorldGuardHook.getBooleanFlag(location, "boss-blocked-region")) != null && flag) {
return false; ServerUtils.get().logDebug("Unable to spawn boss due to worldguard region having the 'boss-blocked-region' flag");
} return false;
} }
if (this.bossHookManager.isFactionsEnabled() && this.bossHookManager.getFactionHelper() != null) { if (this.bossHookManager.isFactionsEnabled() && this.bossHookManager.getFactionHelper() != null) {