Fix object reference pushing functions when called from coroutines

This commit is contained in:
ShadowNinja
2014-10-02 15:58:13 -04:00
parent 28438bba27
commit 741df993ff
10 changed files with 42 additions and 45 deletions

View File

@@ -70,7 +70,7 @@ void ScriptApiEnv::player_event(ServerActiveObject* player, std::string type)
lua_getfield(L, -1, "registered_playerevents");
// Call callbacks
objectrefGetOrCreate(player); // player
objectrefGetOrCreate(L, player); // player
lua_pushstring(L,type.c_str()); // event type
try {
script_run_callbacks(L, 2, RUN_CALLBACKS_MODE_FIRST);