Browse Source

early exit for attack timer

combat-2
FatBoy-DOTC 6 months ago
parent
commit
69ea460d5e
  1. 4
      src/engine/gameManager/CombatManager.java

4
src/engine/gameManager/CombatManager.java

@ -546,6 +546,10 @@ public enum CombatManager { @@ -546,6 +546,10 @@ public enum CombatManager {
public static void setAutoAttackJob(AbstractCharacter attacker, mbEnums.EquipSlotType slot, long delay) {
//calculate next allowed attack and update the timestamp
if(attacker.getTimestamps().containsKey("Attack" + slot.name()) && attacker.getTimestamps().get("Attack" + slot.name()) > System.currentTimeMillis())
return;
attacker.getTimestamps().put("Attack" + slot.name(), System.currentTimeMillis() + delay);
//handle auto attack job creation

Loading…
Cancel
Save