EarthBlast Fix

- Earthblast fix
- Fix for ExtraAbility
This commit is contained in:
runefist 2014-11-05 01:28:59 +01:00
parent 0b37626399
commit 54e066d780
2 changed files with 6 additions and 2 deletions

View file

@ -153,11 +153,14 @@ public class AbilityModuleManager {
} }
for (AbilityModule ab: ability) { for (AbilityModule ab: ability) {
//To check if EarthBlast == Earthblast or for example, EarthBlast == EARTHBLAST //To check if EarthBlast == Earthblast or for example, EarthBlast == EARTHBLAST
boolean succes = true;
for(String enabledAbility : abilities){ for(String enabledAbility : abilities){
if(enabledAbility.equalsIgnoreCase(ab.getName())){ if(enabledAbility.equalsIgnoreCase(ab.getName())){
continue; succes = false;
} }
} }
if (!succes)
continue;
ab.onThisLoad(); ab.onThisLoad();
abilities.add(ab.getName()); abilities.add(ab.getName());
for (StockAbilities a: StockAbilities.values()) { for (StockAbilities a: StockAbilities.values()) {

View file

@ -310,8 +310,9 @@ public class EarthBlast {
Location location = player.getEyeLocation(); Location location = player.getEyeLocation();
Vector vector = location.getDirection(); Vector vector = location.getDirection();
entity.setVelocity(vector.normalize().multiply(pushfactor)); entity.setVelocity(vector.normalize().multiply(pushfactor));
double damage = this.damage;
if (Methods.isMetal(sourceblock) && Methods.canMetalbend(player)) { if (Methods.isMetal(sourceblock) && Methods.canMetalbend(player)) {
damage = Methods.getMetalAugment(damage); damage = Methods.getMetalAugment(this.damage);
} }
Methods.damageEntity(player, entity, damage); Methods.damageEntity(player, entity, damage);
progressing = false; progressing = false;