From e77f503336a420dcb8340dc5f2f6c76fa0b54ad6 Mon Sep 17 00:00:00 2001 From: jackpoz Date: Mon, 22 Sep 2014 20:25:11 +0200 Subject: Scripts/Examples: Remove some more code related to example scripts --- src/server/game/Scripting/ScriptMgr.cpp | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) (limited to 'src/server/game/Scripting/ScriptMgr.cpp') diff --git a/src/server/game/Scripting/ScriptMgr.cpp b/src/server/game/Scripting/ScriptMgr.cpp index 51100accf77..48981fde70b 100644 --- a/src/server/game/Scripting/ScriptMgr.cpp +++ b/src/server/game/Scripting/ScriptMgr.cpp @@ -34,12 +34,6 @@ #include "WorldPacket.h" #include "WorldSession.h" -namespace -{ - typedef std::set ExampleScriptContainer; - ExampleScriptContainer ExampleScripts; -} - // This is the global static registry of scripts. template class ScriptRegistry @@ -108,12 +102,9 @@ class ScriptRegistry else { // The script uses a script name from database, but isn't assigned to anything. - if (script->GetName().find("example") == std::string::npos && script->GetName().find("Smart") == std::string::npos) + if (script->GetName().find("Smart") == std::string::npos) TC_LOG_ERROR("sql.sql", "Script named '%s' does not have a script name assigned in database.", script->GetName().c_str()); - - // These scripts don't get stored anywhere so throw them into this to avoid leaking memory - ExampleScripts.insert(script); } } else @@ -234,10 +225,6 @@ void ScriptMgr::Unload() #undef SCR_CLEAR - for (ExampleScriptContainer::iterator itr = ExampleScripts.begin(); itr != ExampleScripts.end(); ++itr) - delete *itr; - ExampleScripts.clear(); - delete[] SpellSummary; delete[] UnitAI::AISpellInfo; } -- cgit v1.2.3