Permission for not losing power while offline.

This commit is contained in:
drtshock 2015-04-22 08:33:43 -05:00
parent 8354c95a14
commit c3ac0cf1ea
2 changed files with 5 additions and 0 deletions

View File

@ -514,6 +514,9 @@ public abstract class MemoryFPlayer implements FPlayer {
}
public void losePowerFromBeingOffline() {
if(P.perms != null && P.perms.playerHas((String) null, getName(), "factions.dontlosepoweroffline")) {
return;
}
if (Conf.powerOfflineLossPerDay > 0.0 && this.power > Conf.powerOfflineLossLimit) {
long now = System.currentTimeMillis();
long millisPassed = now - this.lastPowerUpdateTime;

View File

@ -253,3 +253,5 @@ permissions:
description: sort factions
factions.togglealliancechat:
description: toggle alliance chat on and off
factions.dontlosepoweroffline:
description: Don't lose power for being offline.