mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-22 21:26:46 +01:00
Apply Perks after cutoff
This commit is contained in:
parent
1444be665c
commit
5029ad9d93
@ -26,6 +26,10 @@ public final class PerksUtils {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static int handleActivationPerks(Player player, int ticks, int maxTicks) {
|
public static int handleActivationPerks(Player player, int ticks, int maxTicks) {
|
||||||
|
if (maxTicks != 0) {
|
||||||
|
ticks = Math.min(ticks, maxTicks);
|
||||||
|
}
|
||||||
|
|
||||||
if (Permissions.twelveSecondActivationBoost(player)) {
|
if (Permissions.twelveSecondActivationBoost(player)) {
|
||||||
ticks += 12;
|
ticks += 12;
|
||||||
}
|
}
|
||||||
@ -36,10 +40,6 @@ public final class PerksUtils {
|
|||||||
ticks += 4;
|
ticks += 4;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (maxTicks != 0) {
|
|
||||||
ticks = Math.min(ticks, maxTicks);
|
|
||||||
}
|
|
||||||
|
|
||||||
return ticks;
|
return ticks;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user