mirror of
https://github.com/TotalFreedomMC/TF-ProjectKorra.git
synced 2024-12-22 16:05:01 +00:00
Fixes Immobilize cooldown activating if target = null
This commit is contained in:
parent
45154e7774
commit
0a7981de1e
1 changed files with 5 additions and 1 deletions
|
@ -37,10 +37,13 @@ public class ChiCombo extends ChiAbility implements ComboAbility {
|
|||
if (ability.equalsIgnoreCase("Immobilize")) {
|
||||
this.cooldown = getConfig().getLong("Abilities.Chi.ChiCombo.Immobilize.Cooldown");
|
||||
this.duration = getConfig().getLong("Abilities.Chi.ChiCombo.Immobilize.ParalyzeDuration");
|
||||
target = GeneralMethods.getTargetedEntity(player, 5);
|
||||
if (!bPlayer.canBendIgnoreBinds(this)) {
|
||||
return;
|
||||
} if (target == null){
|
||||
remove();
|
||||
return;
|
||||
} else {
|
||||
target = GeneralMethods.getTargetedEntity(player, 5);
|
||||
paralyze(target, duration);
|
||||
start();
|
||||
bPlayer.addCooldown(this);
|
||||
|
@ -69,6 +72,7 @@ public class ChiCombo extends ChiAbility implements ComboAbility {
|
|||
*/
|
||||
public static boolean isParalyzed(Player player) {
|
||||
return isParalyzed((Entity) player);
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue