More universe disabled checks.

This commit is contained in:
Olof Larsson
2013-04-25 13:25:15 +02:00
parent ac2c7c705c
commit 5047439756
58 changed files with 325 additions and 82 deletions

View File

@@ -3,6 +3,7 @@ package com.massivecraft.factions.task;
import com.massivecraft.factions.entity.FactionColl;
import com.massivecraft.factions.entity.FactionColls;
import com.massivecraft.factions.entity.MConf;
import com.massivecraft.factions.entity.UConf;
import com.massivecraft.mcore.ModuloRepeatTask;
import com.massivecraft.mcore.util.TimeUnit;
@@ -36,6 +37,9 @@ public class TaskEconLandReward extends ModuloRepeatTask
{
for (FactionColl coll : FactionColls.get().getColls())
{
// Check disabled
if (UConf.isDisabled(coll)) continue;
coll.econLandRewardRoutine();
}
}

View File

@@ -1,6 +1,7 @@
package com.massivecraft.factions.task;
import com.massivecraft.factions.entity.MConf;
import com.massivecraft.factions.entity.UConf;
import com.massivecraft.factions.entity.UPlayerColl;
import com.massivecraft.factions.entity.UPlayerColls;
import com.massivecraft.mcore.ModuloRepeatTask;
@@ -36,6 +37,9 @@ public class TaskPlayerDataRemove extends ModuloRepeatTask
{
for (UPlayerColl coll : UPlayerColls.get().getColls())
{
// Check disabled
if (UConf.isDisabled(coll)) continue;
coll.removePlayerDataAfterInactiveDaysRoutine();
}
}

View File

@@ -4,6 +4,7 @@ import org.bukkit.Bukkit;
import org.bukkit.entity.Player;
import com.massivecraft.factions.entity.MConf;
import com.massivecraft.factions.entity.UConf;
import com.massivecraft.factions.entity.UPlayer;
import com.massivecraft.factions.event.FactionsEventPowerChange;
import com.massivecraft.factions.event.FactionsEventPowerChange.PowerChangeReason;
@@ -42,6 +43,9 @@ public class TaskPlayerPowerUpdate extends ModuloRepeatTask
for (Player player : Bukkit.getOnlinePlayers())
{
// Check disabled
if (UConf.isDisabled(player)) continue;
if (player.isDead()) continue;
UPlayer uplayer = UPlayer.get(player);