|
|
|
@ -179,6 +179,7 @@ public enum LootManager {
@@ -179,6 +179,7 @@ public enum LootManager {
|
|
|
|
|
|
|
|
|
|
outItem = new MobLoot(mob, ItemBase.getItemBase(itemUUID), false); |
|
|
|
|
Enum.ItemType outType = outItem.getItemBase().getType(); |
|
|
|
|
|
|
|
|
|
if (outType.ordinal() == Enum.ItemType.WEAPON.ordinal() || outType.ordinal() == Enum.ItemType.ARMOR.ordinal() || outType.ordinal() == Enum.ItemType.JEWELRY.ordinal()) { |
|
|
|
|
if (outItem.getItemBase().isGlass() == false) { |
|
|
|
|
|
|
|
|
@ -195,10 +196,13 @@ public enum LootManager {
@@ -195,10 +196,13 @@ public enum LootManager {
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
if(outItem.getPrefix() != null && outItem.getPrefix().isEmpty() == false) |
|
|
|
|
|
|
|
|
|
if (outItem.getPrefix() != null && outItem.getPrefix().isEmpty() == false) |
|
|
|
|
outItem.setIsID(false); |
|
|
|
|
if(outItem.getSuffix() != null && outItem.getSuffix().isEmpty() == false) |
|
|
|
|
|
|
|
|
|
if (outItem.getSuffix() != null && outItem.getSuffix().isEmpty() == false) |
|
|
|
|
outItem.setIsID(false); |
|
|
|
|
|
|
|
|
|
return outItem; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
@ -267,7 +271,6 @@ public enum LootManager {
@@ -267,7 +271,6 @@ public enum LootManager {
|
|
|
|
|
inItem.addPermanentEnchantment(suffixMod.action, 0, suffixMod.level, false); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
//}
|
|
|
|
|
return inItem; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
@ -326,6 +329,7 @@ public enum LootManager {
@@ -326,6 +329,7 @@ public enum LootManager {
|
|
|
|
|
try { |
|
|
|
|
|
|
|
|
|
MobLoot toAdd = getGenTableItem(tableID, mob, inHotzone); |
|
|
|
|
|
|
|
|
|
if (toAdd != null) |
|
|
|
|
mob.getCharItemManager().addItemToInventory(toAdd); |
|
|
|
|
|
|
|
|
@ -355,7 +359,7 @@ public enum LootManager {
@@ -355,7 +359,7 @@ public enum LootManager {
|
|
|
|
|
|
|
|
|
|
if (ml != null) { |
|
|
|
|
ml.setIsID(true); |
|
|
|
|
ml.setDurabilityCurrent((short)(ml.getDurabilityCurrent() - ThreadLocalRandom.current().nextInt(5) + 1)); |
|
|
|
|
ml.setDurabilityCurrent((short) (ml.getDurabilityCurrent() - ThreadLocalRandom.current().nextInt(5) + 1)); |
|
|
|
|
mob.getCharItemManager().addItemToInventory(ml); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|