Skip to content

Commit 25206e9

Browse files
committed
Fix exporter for 3.6
1 parent dd65d3d commit 25206e9

1 file changed

Lines changed: 7 additions & 2 deletions

File tree

export/export.cpp

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,7 @@ class EditorExportPlatformSwitch : public EditorExportPlatform {
276276
return OK;
277277
}
278278

279-
virtual bool can_export(const Ref<EditorExportPreset> &p_preset, String &r_error, bool &r_missing_templates) const {
279+
virtual bool has_valid_export_configuration(const Ref<EditorExportPreset> &p_preset, String &r_error, bool &r_missing_templates) const {
280280
String err;
281281
r_missing_templates =
282282
find_export_template(TEMPLATE_RELEASE) == String() ||
@@ -296,6 +296,10 @@ class EditorExportPlatformSwitch : public EditorExportPlatform {
296296
return valid;
297297
}
298298

299+
virtual bool has_valid_project_configuration(const Ref<EditorExportPreset> &p_preset, String &r_error) const {
300+
return true;
301+
}
302+
299303
virtual List<String> get_binary_extensions(const Ref<EditorExportPreset> &p_preset) const {
300304
List<String> list;
301305
list.push_back("nro");
@@ -592,6 +596,7 @@ void register_switch_exporter() {
592596
EDITOR_DEF("export/switch/build_romfs", "");
593597
EditorSettings::get_singleton()->add_property_hint(PropertyInfo(Variant::STRING, "export/switch/build_romfs", PROPERTY_HINT_GLOBAL_FILE, exe_ext));
594598

595-
Ref<EditorExportPlatformSwitch> exporter = Ref<EditorExportPlatformSwitch>(memnew(EditorExportPlatformSwitch));
599+
Ref<EditorExportPlatformSwitch> exporter;
600+
exporter.instance();
596601
EditorExport::get_singleton()->add_export_platform(exporter);
597602
}

0 commit comments

Comments
 (0)