From 7848233396f950debf8cbce528b888b186691aa5 Mon Sep 17 00:00:00 2001 From: MagicBot Date: Sat, 16 Mar 2024 18:20:24 -0400 Subject: [PATCH] equip slot usage update --- src/engine/gameManager/NPCManager.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/engine/gameManager/NPCManager.java b/src/engine/gameManager/NPCManager.java index 6aa71ffa..1460287a 100644 --- a/src/engine/gameManager/NPCManager.java +++ b/src/engine/gameManager/NPCManager.java @@ -298,9 +298,9 @@ public enum NPCManager { guard.maxDamageHandOne = (int)((guard.mobBase.getDamageMax()) * rankModifier); guard.speedHandOne = 30.0f; }else{ - if(guard.equip.containsKey(1)){ + if (guard.equip.containsKey(Enum.EquipSlotType.RHELD)) { //has main hand weapon - ItemBase weapon = guard.equip.get(1).getItemBase(); + ItemBase weapon = guard.equip.get(Enum.EquipSlotType.RHELD).getItemBase(); if (weapon.isStrBased()) primaryStat = guard.getStatStrCurrent(); else @@ -309,9 +309,9 @@ public enum NPCManager { guard.maxDamageHandOne = (int) ((guard.mobBase.getDamageMax() + weapon.getMaxDamage()) * rankModifier) + primaryStat; guard.speedHandOne = weapon.getSpeed(); guard.rangeHandOne = weapon.getRange(); - } else if (guard.equip.containsKey(2) && !ItemTemplate.isShield(guard.equip.get(2).template)) { + } else if (guard.equip.containsKey(Enum.EquipSlotType.LHELD) && !ItemTemplate.isShield(guard.equip.get(Enum.EquipSlotType.LHELD).template)) { //has off hand weapon - ItemBase weapon = guard.equip.get(2).getItemBase(); + ItemBase weapon = guard.equip.get(Enum.EquipSlotType.LHELD).getItemBase(); if (weapon.isStrBased()) primaryStat = guard.getStatStrCurrent(); else