From 1bb93e3534342054ea74857af8713f8081c09947 Mon Sep 17 00:00:00 2001 From: QAston Date: Fri, 14 Aug 2009 13:33:58 +0200 Subject: [PATCH] Fix Drain Soul chance to obtain soulshard on tick - by Themris. --HG-- branch : trunk --- src/game/SpellAuras.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/game/SpellAuras.cpp b/src/game/SpellAuras.cpp index 49e5c831ac..2335717135 100644 --- a/src/game/SpellAuras.cpp +++ b/src/game/SpellAuras.cpp @@ -5638,6 +5638,12 @@ void AuraEffect::PeriodicTick() pdamage += (pdamage+1)/2; // +1 prevent 0.5 damage possible lost at 1..4 ticks // 5..8 ticks have normal tick damage } + // There is a Chance to make a Soul Shard when Drain soul does damage + if (GetSpellProto()->SpellFamilyName==SPELLFAMILY_WARLOCK && (GetSpellProto()->SpellFamilyFlags[0] & 0x00004000)) + { + if(roll_chance_i(20)) + pCaster->CastSpell(pCaster, 24827, true, 0, this); + } } else pdamage = uint32(m_target->GetMaxHealth()*pdamage/100);