Skip to content

Commit

Permalink
Fix preloading a zip in the web editor
Browse files Browse the repository at this point in the history
  • Loading branch information
paulsinnett authored and akien-mga committed Jul 4, 2024
1 parent 4d984b6 commit db97d88
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion platform/web/web_main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
#include "core/config/engine.h"
#include "core/io/resource_loader.h"
#include "main/main.h"
#include "scene/main/scene_tree.h"

#include <emscripten/emscripten.h>
#include <stdlib.h>
Expand Down Expand Up @@ -130,7 +131,7 @@ extern EMSCRIPTEN_KEEPALIVE int godot_web_main(int argc, char *argv[]) {
if (Engine::get_singleton()->is_project_manager_hint() && FileAccess::exists("/tmp/preload.zip")) {
PackedStringArray ps;
ps.push_back("/tmp/preload.zip");
os->get_main_loop()->emit_signal(SNAME("files_dropped"), ps, -1);
SceneTree::get_singleton()->get_root()->emit_signal(SNAME("files_dropped"), ps);
}
#endif
emscripten_set_main_loop(main_loop_callback, -1, false);
Expand Down

0 comments on commit db97d88

Please sign in to comment.