Eluna remove crash possibility of using ReloadEluna global function on returning hooks, restrict the use of the reload command

This commit is contained in:
Rochet2
2014-06-10 23:31:57 +03:00
committed by Foereaper
parent 37a0161f29
commit 45c5c876dd
5 changed files with 30 additions and 14 deletions

View File

@@ -12,6 +12,7 @@
Eluna::ScriptPaths Eluna::scripts;
Eluna* Eluna::GEluna = NULL;
bool Eluna::reload = false;
extern void RegisterFunctions(lua_State* L);
@@ -45,8 +46,11 @@ void Eluna::Uninitialize()
void Eluna::ReloadEluna()
{
eWorld->SendServerMessage(SERVER_MSG_STRING, "Reloading Eluna...");
Uninitialize();
Initialize();
reload = false;
}
Eluna::Eluna():