Begin constructor refactor

This commit is contained in:
2024-03-01 21:32:51 -05:00
parent 9ea44d7e1c
commit fa440e2885
20 changed files with 72 additions and 76 deletions
+4 -4
View File
@@ -87,7 +87,7 @@ public enum LootManager {
if (ib == null)
break;
ItemTemplate template = ItemTemplate.itemTemplates.get(it.getItemBaseID());
ItemTemplate template = ItemTemplate.itemTemplates.get(it.getTemplsteID());
if (ib.isDiscRune() || template.item_base_name.toLowerCase().contains("of the gods")) {
ChatSystemMsg chatMsg = new ChatSystemMsg(null, mob.getName() + " in " + mob.getParentZone().zoneName + " has found the " + template.item_base_name + ". Are you tough enough to take it?");
@@ -354,7 +354,7 @@ public enum LootManager {
if (ml != null && dropCount < 1) {
ml.setIsID(true);
ml.setDurabilityCurrent((short) (ml.getDurabilityCurrent() - ThreadLocalRandom.current().nextInt(5) + 1));
ml.setDurabilityCurrent((short) ((short) ml.durabilityCurrent - ThreadLocalRandom.current().nextInt(5) + 1));
mob.getCharItemManager().addItemToInventory(ml);
dropCount = 1;
//break; // Exit on first successful roll.
@@ -383,8 +383,8 @@ public enum LootManager {
int tableID = 0;
if (_bootySetMap.get(gift.getItemBaseID()) != null)
tableID = _bootySetMap.get(gift.getItemBaseID()).get(ThreadLocalRandom.current().nextInt(_bootySetMap.get(gift.getItemBaseID()).size())).genTable;
if (_bootySetMap.get(gift.getTemplsteID()) != null)
tableID = _bootySetMap.get(gift.getTemplsteID()).get(ThreadLocalRandom.current().nextInt(_bootySetMap.get(gift.getTemplsteID()).size())).genTable;
if (tableID == 0)
return;