Eluna fix problem with reloading timed events

This commit is contained in:
Rochet2
2015-02-15 02:08:23 +02:00
parent 6a731d24ea
commit e7019de059
5 changed files with 52 additions and 29 deletions

View File

@@ -645,7 +645,7 @@ namespace LuaWorldObject
int RemoveEventById(Eluna* /*E*/, lua_State* L, WorldObject* obj)
{
int eventId = Eluna::CHECKVAL<int>(L, 2);
obj->elunaEvents->RemoveEvent(eventId);
obj->elunaEvents->SetState(eventId, LUAEVENT_STATE_ABORT);
return 0;
}
@@ -655,7 +655,7 @@ namespace LuaWorldObject
*/
int RemoveEvents(Eluna* /*E*/, lua_State* /*L*/, WorldObject* obj)
{
obj->elunaEvents->RemoveEvents();
obj->elunaEvents->SetStates(LUAEVENT_STATE_ABORT);
return 0;
}