diff options
Diffstat (limited to 'src/game/ItemEnchantmentMgr.cpp')
-rw-r--r-- | src/game/ItemEnchantmentMgr.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/game/ItemEnchantmentMgr.cpp b/src/game/ItemEnchantmentMgr.cpp index 3326fb56e96..b40a398a782 100644 --- a/src/game/ItemEnchantmentMgr.cpp +++ b/src/game/ItemEnchantmentMgr.cpp @@ -1,7 +1,7 @@ /* - * Copyright (C) 2005-2008 MaNGOS <http://www.mangosproject.org/> + * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * - * Copyright (C) 2008 Trinity <http://www.trinitycore.org/> + * Copyright (C) 2008-2009 Trinity <http://www.trinitycore.org/> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -50,7 +50,7 @@ void LoadRandomEnchantmentsTable() { RandomItemEnch.clear(); // for reload case - EnchantmentStore::iterator tab; + EnchantmentStore::const_iterator tab; uint32 entry, ench; float chance; uint32 count = 0; @@ -92,7 +92,7 @@ uint32 GetItemEnchantMod(uint32 entry) { if (!entry) return 0; - EnchantmentStore::iterator tab = RandomItemEnch.find(entry); + EnchantmentStore::const_iterator tab = RandomItemEnch.find(entry); if (tab == RandomItemEnch.end()) { @@ -103,7 +103,7 @@ uint32 GetItemEnchantMod(uint32 entry) double dRoll = rand_chance(); float fCount = 0; - for(EnchStoreList::iterator ench_iter = tab->second.begin(); ench_iter != tab->second.end(); ++ench_iter) + for(EnchStoreList::const_iterator ench_iter = tab->second.begin(); ench_iter != tab->second.end(); ++ench_iter) { fCount += ench_iter->chance; @@ -114,7 +114,7 @@ uint32 GetItemEnchantMod(uint32 entry) dRoll = (irand(0, (int)floor(fCount * 100) + 1)) / 100; fCount = 0; - for(EnchStoreList::iterator ench_iter = tab->second.begin(); ench_iter != tab->second.end(); ++ench_iter) + for(EnchStoreList::const_iterator ench_iter = tab->second.begin(); ench_iter != tab->second.end(); ++ench_iter) { fCount += ench_iter->chance; |