aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Spells/Spell.cpp
diff options
context:
space:
mode:
authorQAston <none@none>2010-10-04 17:44:49 +0200
committerQAston <none@none>2010-10-04 17:44:49 +0200
commitcaaa77deb285d65b1bc3a0c6f7b5f88ec3508d0c (patch)
treec4ae1d28125763aff7b4a4adbf2b188c40f7094c /src/server/game/Spells/Spell.cpp
parent5adaf5887ec3bbc5af122966b506d33deccf8814 (diff)
Core/ScriptSystem:
Add basic code for runtime checks of function calls in AuraScripts Make AuraScript::PreventDefaultAction() do not take parameters and add description for the function Remove PreventDefaultEffect() from aura script, use PreventDefaultAction() instead Unload aura scripts memory on aura delete --HG-- branch : trunk
Diffstat (limited to 'src/server/game/Spells/Spell.cpp')
-rw-r--r--src/server/game/Spells/Spell.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/server/game/Spells/Spell.cpp b/src/server/game/Spells/Spell.cpp
index e01aa4f94af..861cc57dc01 100644
--- a/src/server/game/Spells/Spell.cpp
+++ b/src/server/game/Spells/Spell.cpp
@@ -541,10 +541,11 @@ Spell::~Spell()
while(!m_loadedScripts.empty())
{
std::list<SpellScript *>::iterator itr = m_loadedScripts.begin();
- (*itr)->Unload();
+ (*itr)->_Unload();
delete (*itr);
m_loadedScripts.erase(itr);
}
+
if (m_referencedFromCurrentSpell && m_selfContainer && *m_selfContainer == this)
{
// Clean the reference to avoid later crash.