Browse Source

remove ItemBase from NPCManager

combat-2
FatBoy-DOTC 8 months ago
parent
commit
7f452d18bc
  1. 5
      src/engine/gameManager/NPCManager.java

5
src/engine/gameManager/NPCManager.java

@ -351,9 +351,9 @@ public enum NPCManager { @@ -351,9 +351,9 @@ public enum NPCManager {
int strength = guard.getStatStrCurrent();
int baseAtr = guard.mobBase.getAttackRating();
if (guard.charItemManager.equipped.get(Enum.EquipSlotType.RHELD) != null)
guard.atrHandOne = baseAtr + (int) ((strength * 0.5f) + (guard.charItemManager.equipped.get(Enum.EquipSlotType.RHELD).getItemBase().getPercentRequired() * 4) + (guard.charItemManager.equipped.get(Enum.EquipSlotType.RHELD).getItemBase().getPercentRequired() * 3));
guard.atrHandOne = baseAtr + (int) ((strength * 0.5f) + ((int)guard.charItemManager.equipped.get(Enum.EquipSlotType.RHELD).template.item_skill_required.values().toArray()[0] * 4) + ((int)guard.charItemManager.equipped.get(Enum.EquipSlotType.RHELD).template.item_skill_required.values().toArray()[0] * 3));
else if (guard.charItemManager.equipped.get(Enum.EquipSlotType.LHELD) != null && !ItemTemplate.isShield(guard.charItemManager.equipped.get(Enum.EquipSlotType.LHELD).template))
guard.atrHandTwo = baseAtr + (int) ((strength * 0.5f) + (guard.charItemManager.equipped.get(Enum.EquipSlotType.LHELD).getItemBase().getPercentRequired() * 4) + (guard.charItemManager.equipped.get(Enum.EquipSlotType.LHELD).getItemBase().getPercentRequired() * 3));
guard.atrHandTwo = baseAtr + (int) ((strength * 0.5f) + ((int)guard.charItemManager.equipped.get(Enum.EquipSlotType.LHELD).template.item_skill_required.values().toArray()[0] * 4) + ((int)guard.charItemManager.equipped.get(Enum.EquipSlotType.LHELD).template.item_skill_required.values().toArray()[0] * 3));
else
guard.atrHandOne = baseAtr;
}
@ -383,6 +383,7 @@ public enum NPCManager { @@ -383,6 +383,7 @@ public enum NPCManager {
guard.healthMax = 5412;
break;
}
guard.setHealth(guard.healthMax);
}
public static void applyMobbaseEffects(Mob mob) {

Loading…
Cancel
Save