Core/Skinning: Update correct skinning skill according to creature expansion
Port From (https://github.com/TrinityCore/TrinityCore/commit/229a7ac79d38b9db76387f92e846c04c151ad3aa)
This commit is contained in:
@@ -5180,14 +5180,6 @@ namespace Game.Spells
|
||||
if (loot != null && (!loot.IsLooted() || loot.loot_type == LootType.Skinning))
|
||||
return SpellCastResult.TargetNotLooted;
|
||||
|
||||
SkillType skill = creature.GetCreatureTemplate().GetRequiredLootSkill();
|
||||
|
||||
ushort skillValue = m_caster.ToPlayer().GetSkillValue(skill);
|
||||
uint TargetLevel = m_targets.GetUnitTarget().GetLevelForTarget(m_caster);
|
||||
int ReqValue = (int)(skillValue < 100 ? (TargetLevel - 10) * 10 : TargetLevel * 5);
|
||||
if (ReqValue > skillValue)
|
||||
return SpellCastResult.LowCastlevel;
|
||||
|
||||
break;
|
||||
}
|
||||
case SpellEffectName.OpenLock:
|
||||
|
||||
Reference in New Issue
Block a user