1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-16 14:00:40 +00:00

[HTML5] Make GDNative support feature-based.

This is suboptimal as it requires adding an extra flag, but rewriting
how feature tags work is beyond the scope of this work.
This commit is contained in:
Fabio Alessandrelli
2020-12-03 17:15:14 +01:00
parent 2cbfe1afd4
commit 79a1418e7d
4 changed files with 22 additions and 3 deletions

View File

@@ -328,6 +328,12 @@ void EditorExportPlatformJavaScript::get_preset_features(const Ref<EditorExportP
}
}
}
ExportMode mode = (ExportMode)(int)p_preset->get("variant/export_type");
if (mode == EXPORT_MODE_THREADS) {
r_features->push_back("threads");
} else if (mode == EXPORT_MODE_GDNATIVE) {
r_features->push_back("wasm32");
}
}
void EditorExportPlatformJavaScript::get_export_options(List<ExportOption> *r_options) {