Merge pull request #14008 from vnen/export-icon-splash
Export icon and splash images directly to final package
This commit is contained in:
commit
c11ea8a2d0
1 changed files with 12 additions and 0 deletions
|
@ -743,6 +743,18 @@ Error EditorExportPlatform::export_project_files(const Ref<EditorExportPreset> &
|
||||||
custom_map["path_remap/remapped_paths"] = path_remaps;
|
custom_map["path_remap/remapped_paths"] = path_remaps;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Store icon and splash images directly, they need to bypass the import system and be loaded as images
|
||||||
|
String icon = ProjectSettings::get_singleton()->get("application/config/icon");
|
||||||
|
String splash = ProjectSettings::get_singleton()->get("application/boot_splash/image");
|
||||||
|
if (icon != String() && FileAccess::exists(icon)) {
|
||||||
|
Vector<uint8_t> array = FileAccess::get_file_as_array(icon);
|
||||||
|
p_func(p_udata, icon, array, idx, total);
|
||||||
|
}
|
||||||
|
if (splash != String() && FileAccess::exists(splash)) {
|
||||||
|
Vector<uint8_t> array = FileAccess::get_file_as_array(splash);
|
||||||
|
p_func(p_udata, splash, array, idx, total);
|
||||||
|
}
|
||||||
|
|
||||||
String config_file = "project.binary";
|
String config_file = "project.binary";
|
||||||
String engine_cfb = EditorSettings::get_singleton()->get_cache_dir().plus_file("tmp" + config_file);
|
String engine_cfb = EditorSettings::get_singleton()->get_cache_dir().plus_file("tmp" + config_file);
|
||||||
ProjectSettings::get_singleton()->save_custom(engine_cfb, custom_map, custom_list);
|
ProjectSettings::get_singleton()->save_custom(engine_cfb, custom_map, custom_list);
|
||||||
|
|
Loading…
Reference in a new issue