|
|
|
@ -662,9 +662,8 @@ public enum CombatManager {
@@ -662,9 +662,8 @@ public enum CombatManager {
|
|
|
|
|
|
|
|
|
|
DeferredPowerJob dpj = null; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (LandHit((int)atr,(int)defense)) { |
|
|
|
|
boolean hitLanded = LandHit((int)atr,(int)defense); |
|
|
|
|
if (hitLanded) { |
|
|
|
|
|
|
|
|
|
if (ac.getObjectType().equals(GameObjectType.PlayerCharacter)) |
|
|
|
|
updateAttackTimers((PlayerCharacter) ac, target, true); |
|
|
|
@ -693,7 +692,13 @@ public enum CombatManager {
@@ -693,7 +692,13 @@ public enum CombatManager {
|
|
|
|
|
|
|
|
|
|
PlayerBonuses bonus = ac.getBonuses(); |
|
|
|
|
float attackRange = getWeaponRange(wb, bonus); |
|
|
|
|
if(specialCaseHitRoll(dpj.getPowerToken())) { |
|
|
|
|
if(hitLanded) { |
|
|
|
|
dpj.attack(target, attackRange); |
|
|
|
|
} |
|
|
|
|
}else{ |
|
|
|
|
dpj.attack(target, attackRange); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if (dpj.getPower() != null && (dpj.getPowerToken() == -1851459567 || dpj.getPowerToken() == -1851489518)) |
|
|
|
|
((PlayerCharacter) ac).setWeaponPower(dpj); |
|
|
|
@ -708,9 +713,15 @@ public enum CombatManager {
@@ -708,9 +713,15 @@ public enum CombatManager {
|
|
|
|
|
|
|
|
|
|
if (dpj != null && dpj.getPower() != null && (dpj.getPowerToken() == -1851459567 || dpj.getPowerToken() == -1851489518)) { |
|
|
|
|
float attackRange = getWeaponRange(wb, bonuses); |
|
|
|
|
if(specialCaseHitRoll(dpj.getPowerToken())) { |
|
|
|
|
if(hitLanded) { |
|
|
|
|
dpj.attack(target, attackRange); |
|
|
|
|
} |
|
|
|
|
}else{ |
|
|
|
|
dpj.attack(target, attackRange); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
errorTrack = 7; |
|
|
|
|
|
|
|
|
@ -916,7 +927,13 @@ public enum CombatManager {
@@ -916,7 +927,13 @@ public enum CombatManager {
|
|
|
|
|
if (wp.requiresHitRoll() == false) { |
|
|
|
|
PlayerBonuses bonus = ac.getBonuses(); |
|
|
|
|
float attackRange = getWeaponRange(wb, bonus); |
|
|
|
|
if(specialCaseHitRoll(dpj.getPowerToken())) { |
|
|
|
|
if(hitLanded) { |
|
|
|
|
dpj.attack(target, attackRange); |
|
|
|
|
} |
|
|
|
|
}else{ |
|
|
|
|
dpj.attack(target, attackRange); |
|
|
|
|
} |
|
|
|
|
} else |
|
|
|
|
((PlayerCharacter) ac).setWeaponPower(null); |
|
|
|
|
} |
|
|
|
@ -1466,4 +1483,15 @@ public enum CombatManager {
@@ -1466,4 +1483,15 @@ public enum CombatManager {
|
|
|
|
|
|
|
|
|
|
return roll <= convertedChance; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public static boolean specialCaseHitRoll(int powerID){ |
|
|
|
|
switch(powerID) { |
|
|
|
|
case 563200808: // Naargal's Bite
|
|
|
|
|
case 563205337: // Naargal's Dart
|
|
|
|
|
case 563205930: // Sword of Saint Malorn
|
|
|
|
|
return true; |
|
|
|
|
default: |
|
|
|
|
return false; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|