Fix messages displaying when swift aegis level is 0.

This commit is contained in:
sigonasr2 2016-09-20 20:10:35 -05:00
parent 7878e7a956
commit bb29d3f165
2 changed files with 5 additions and 3 deletions

Binary file not shown.

View File

@ -3944,10 +3944,12 @@ public class GenericFunctions {
TwosideKeeper.log("New Aegis level: "+pd.swiftaegisamt,5); TwosideKeeper.log("New Aegis level: "+pd.swiftaegisamt,5);
GenericFunctions.sendActionBarMessage(p, ChatColor.GRAY+"Resistance "+WorldShop.toRomanNumeral(GenericFunctions.getPotionEffectLevel(PotionEffectType.DAMAGE_RESISTANCE, p)+1)); GenericFunctions.sendActionBarMessage(p, ChatColor.GRAY+"Resistance "+WorldShop.toRomanNumeral(GenericFunctions.getPotionEffectLevel(PotionEffectType.DAMAGE_RESISTANCE, p)+1));
}*/ }*/
if (swiftaegislv>0) {
pd.swiftaegisamt=Math.min(10,getSwiftAegisAmt(p)+swiftaegislv); pd.swiftaegisamt=Math.min(10,getSwiftAegisAmt(p)+swiftaegislv);
pd.swiftaegistime=TwosideKeeper.getServerTickTime(); pd.swiftaegistime=TwosideKeeper.getServerTickTime();
GenericFunctions.sendActionBarMessage(p, ChatColor.GRAY+"Resist "+WorldShop.toRomanNumeral(pd.swiftaegisamt)); GenericFunctions.sendActionBarMessage(p, ChatColor.GRAY+"Resist "+WorldShop.toRomanNumeral(pd.swiftaegisamt));
} }
}
public static int getSwiftAegisAmt(Player p) { public static int getSwiftAegisAmt(Player p) {
PlayerStructure pd = PlayerStructure.GetPlayerStructure(p); PlayerStructure pd = PlayerStructure.GetPlayerStructure(p);