mirror of
https://github.com/TotalFreedomMC/TF-ProjectKorra.git
synced 2025-02-12 03:59:06 +00:00
commit
5f47ff465b
4 changed files with 22 additions and 4 deletions
|
@ -110,6 +110,9 @@ public class FreezeMelt {
|
|||
public static boolean canThaw(Block block) {
|
||||
if (frozenblocks.containsKey(block)) {
|
||||
for (Player player : block.getWorld().getPlayers()) {
|
||||
if (!player.isOnline()) {
|
||||
return true;
|
||||
}
|
||||
if (GeneralMethods.getBoundAbility(player) == null) {
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -155,9 +155,11 @@ public class IceBlast {
|
|||
source.revertBlock();
|
||||
progressing = false;
|
||||
}
|
||||
BendingPlayer bPlayer = GeneralMethods.getBendingPlayer(player.getName());
|
||||
if (bPlayer != null) {
|
||||
bPlayer.addCooldown("IceBlast", cooldown);
|
||||
if (player.isOnline()) {
|
||||
BendingPlayer bPlayer = GeneralMethods.getBendingPlayer(player.getName());
|
||||
if (bPlayer != null) {
|
||||
bPlayer.addCooldown("IceBlast", cooldown);
|
||||
}
|
||||
}
|
||||
instances.remove(id);
|
||||
}
|
||||
|
@ -228,8 +230,12 @@ public class IceBlast {
|
|||
}
|
||||
|
||||
private void progress() {
|
||||
if (player.isDead() || !player.isOnline()) {
|
||||
cancel();
|
||||
return;
|
||||
}
|
||||
BendingPlayer bPlayer = GeneralMethods.getBendingPlayer(player.getName());
|
||||
if (player.isDead() || !player.isOnline() || !GeneralMethods.canBend(player.getName(), "IceBlast") || bPlayer.isOnCooldown("IceBlast")) {
|
||||
if (!GeneralMethods.canBend(player.getName(), "IceBlast") || bPlayer.isOnCooldown("IceBlast")) {
|
||||
cancel();
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -159,6 +159,11 @@ public class OctopusForm {
|
|||
}
|
||||
|
||||
private void progress() {
|
||||
if (player.isDead() || !player.isOnline()) {
|
||||
remove();
|
||||
return;
|
||||
}
|
||||
|
||||
if (!GeneralMethods.canBend(player.getName(), "OctopusForm")) {
|
||||
remove();
|
||||
returnWater();
|
||||
|
|
|
@ -563,6 +563,10 @@ public class Torrent {
|
|||
frozenblocks.remove(block);
|
||||
continue;
|
||||
}
|
||||
if (!player.isOnline()) {
|
||||
thaw(block);
|
||||
continue;
|
||||
}
|
||||
if (block.getBlock().getWorld() != player.getWorld()) {
|
||||
thaw(block);
|
||||
continue;
|
||||
|
|
Loading…
Reference in a new issue