[7284] Avoid 2 times skill value request. Author: VladimirMangos

--HG--
branch : trunk
This commit is contained in:
megamage
2009-02-16 20:10:40 -06:00
parent 319f70fb76
commit 2156fec0d2
2 changed files with 2 additions and 4 deletions

View File

@@ -3137,8 +3137,7 @@ void Spell::EffectOpenLock(uint32 /*i*/)
}
// update skill if really known
uint32 SkillValue = player->GetPureSkillValue(SkillId);
if(SkillValue) // non only item base skill
if(uint32 SkillValue = player->GetPureSkillValue(SkillId))
{
if(gameObjTarget)
{
@@ -3150,7 +3149,6 @@ void Spell::EffectOpenLock(uint32 /*i*/)
else if(itemTarget)
{
// Do one skill-up
uint32 SkillValue = player->GetPureSkillValue(SkillId);
player->UpdateGatherSkill(SkillId, SkillValue, reqSkillValue);
}
}