mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-04 18:41:51 +00:00
fixes
This commit is contained in:
parent
e5a3178969
commit
dbf366eca3
5 changed files with 22 additions and 7 deletions
|
|
@ -302,9 +302,9 @@ void scripting::on_world_quit() {
|
|||
|
||||
void scripting::cleanup() {
|
||||
auto L = lua::get_main_state();
|
||||
lua::getglobal(L, "pack");
|
||||
lua::requireglobal(L, "pack");
|
||||
for (auto& pack : scripting::engine->getAllContentPacks()) {
|
||||
lua::getfield(L, "unload");
|
||||
lua::requirefield(L, "unload");
|
||||
lua::pushstring(L, pack.id);
|
||||
lua::call_nothrow(L, 1);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue