Better way to check for RandomProperty == -1, assign 0 to it for now.

--HG--
branch : trunk
This commit is contained in:
Machiavelli
2010-06-27 19:46:25 +02:00
parent cd47c87a7c
commit 0b063e189b
2 changed files with 13 additions and 11 deletions
@@ -91,15 +91,10 @@ uint32 GetItemEnchantMod(int32 entry)
if (!entry)
return 0;
EnchantmentStore::const_iterator tab;
if (entry == -1)
{
/* To do: Find randomproperty/suffix based on item level. */
}
else
tab = RandomItemEnch.find(entry);
return 0;
EnchantmentStore::const_iterator tab = RandomItemEnch.find(entry);
if (tab == RandomItemEnch.end())
{
sLog.outErrorDb("Item RandomProperty / RandomSuffix id #%u used in `item_template` but it does not have records in `item_enchantment_template` table.",entry);