Browse Source

added range modification for guards

feature-workorder
FatBoy-DOTC 1 year ago
parent
commit
669ee7215b
  1. 3
      src/engine/gameManager/NPCManager.java
  2. 4
      src/engine/objects/AbstractCharacter.java

3
src/engine/gameManager/NPCManager.java

@ -304,16 +304,19 @@ public enum NPCManager { @@ -304,16 +304,19 @@ public enum NPCManager {
guard.minDamageHandOne = (int)(guard.mobBase.getDamageMin() + weapon.getMinDamage());
guard.maxDamageHandOne = (int)(guard.mobBase.getDamageMax() + weapon.getMaxDamage());
guard.speedHandOne = weapon.getSpeed();
guard.rangeHandOne = weapon.getRange();
} else if(guard.equip.containsKey(2) && !guard.equip.get(2).getItemBase().isShield()){
//has off hand weapon
ItemBase weapon = guard.equip.get(2).getItemBase();
guard.minDamageHandTwo = (int)(guard.mobBase.getDamageMin() + weapon.getMinDamage());
guard.maxDamageHandTwo = (int)(guard.mobBase.getDamageMax() + weapon.getMaxDamage());
guard.speedHandTwo = weapon.getSpeed();
guard.rangeHandTwo = weapon.getRange();
} else {
guard.minDamageHandOne = (int)(guard.mobBase.getDamageMin());
guard.maxDamageHandOne = (int)(guard.mobBase.getDamageMax());
guard.speedHandOne = 30.0f;
guard.rangeHandOne = 3;
}
}
}

4
src/engine/objects/AbstractCharacter.java

@ -98,8 +98,8 @@ public abstract class AbstractCharacter extends AbstractWorldObject { @@ -98,8 +98,8 @@ public abstract class AbstractCharacter extends AbstractWorldObject {
public int maxDamageHandOne;
public int minDamageHandTwo;
public int maxDamageHandTwo;
protected float rangeHandOne;
protected float rangeHandTwo;
public float rangeHandOne;
public float rangeHandTwo;
public float speedHandOne;
public float speedHandTwo;
public int defenseRating;

Loading…
Cancel
Save