Skip to content

Commit

Permalink
TFunction support on set(?)
Browse files Browse the repository at this point in the history
  • Loading branch information
mcagabe19 authored Aug 19, 2024
1 parent 1f15374 commit c9f841f
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion source/psychlua/FunkinLua.hx
Original file line number Diff line number Diff line change
Expand Up @@ -1637,6 +1637,11 @@ class FunkinLua {
return;
}

if (Type.typeof(data) == TFunction) {
Lua_helper.add_callback(lua, variable, data);
return;
}

Convert.toLua(lua, data);
Lua.setglobal(lua, variable);
}
Expand Down Expand Up @@ -1839,4 +1844,4 @@ class FunkinLua {
return false;
}
}
#end
#end

0 comments on commit c9f841f

Please sign in to comment.