aboutsummaryrefslogtreecommitdiff
path: root/src/game/SkillDiscovery.cpp
diff options
context:
space:
mode:
authorn0n4m3 <none@none>2010-01-16 19:18:53 +0300
committern0n4m3 <none@none>2010-01-16 19:18:53 +0300
commit9be16cf605d1b565ad4e84badbb61c1b121fee1f (patch)
treec4ea4911517b73a49f006bb7b9f70aa84f8916ef /src/game/SkillDiscovery.cpp
parent706718b28c8f028d39ec3ca7d3bfefb9f9a62add (diff)
Some replacements .count to .find for better performance - original patch by zhenya.
--HG-- branch : trunk
Diffstat (limited to 'src/game/SkillDiscovery.cpp')
-rw-r--r--src/game/SkillDiscovery.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/game/SkillDiscovery.cpp b/src/game/SkillDiscovery.cpp
index ed6041f216d..3741e1720a4 100644
--- a/src/game/SkillDiscovery.cpp
+++ b/src/game/SkillDiscovery.cpp
@@ -91,7 +91,7 @@ void LoadSkillDiscoveryTable()
SpellEntry const* reqSpellEntry = sSpellStore.LookupEntry(reqSkillOrSpell);
if (!reqSpellEntry)
{
- if(reportedReqSpells.count(reqSkillOrSpell)==0)
+ if (reportedReqSpells.find(reqSkillOrSpell) == reportedReqSpells.end())
{
sLog.outErrorDb("Spell (ID: %u) have not existed spell (ID: %i) in `reqSpell` field in `skill_discovery_template` table",spellId,reqSkillOrSpell);
reportedReqSpells.insert(reqSkillOrSpell);
@@ -104,7 +104,7 @@ void LoadSkillDiscoveryTable()
// explicit discovery ability
!IsExplicitDiscoverySpell(reqSpellEntry))
{
- if (reportedReqSpells.count(reqSkillOrSpell)==0)
+ if (reportedReqSpells.find(reqSkillOrSpell) == reportedReqSpells.end())
{
sLog.outErrorDb("Spell (ID: %u) not have MECHANIC_DISCOVERY (28) value in Mechanic field in spell.dbc"
" and not 100%% chance random discovery ability but listed for spellId %u (and maybe more) in `skill_discovery_template` table",