mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Fix object reference pushing functions when called from coroutines
This commit is contained in:
parent
28438bba27
commit
741df993ff
10 changed files with 42 additions and 45 deletions
|
@ -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);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue