| 3382 | } |
| 3383 | // |
| 3384 | Error ResourceFormatSaverCompatBinaryInstance::write_v2_import_metadata(Ref<FileAccess> f, Ref<ResourceImportMetadatav2> p_imd, HashMap<Ref<Resource>, int> &p_resource_map) { |
| 3385 | uint64_t md_pos = f->get_position(); |
| 3386 | save_unicode_string(f, p_imd->get_editor()); |
| 3387 | f->store_32(p_imd->get_source_count()); |
| 3388 | for (int i = 0; i < p_imd->get_source_count(); i++) { |
| 3389 | save_unicode_string(f, p_imd->get_source_path(i)); |
| 3390 | save_unicode_string(f, p_imd->get_source_md5(i)); |
| 3391 | } |
| 3392 | List<String> options; |
| 3393 | p_imd->get_options(&options); |
| 3394 | f->store_32(options.size()); |
| 3395 | for (List<String>::Element *E = options.front(); E; E = E->next()) { |
| 3396 | save_unicode_string(f, E->get()); |
| 3397 | write_variant(f, p_imd->get_option(E->get()), p_resource_map, external_resources, string_map); |
| 3398 | } |
| 3399 | |
| 3400 | f->seek(md_at); |
| 3401 | f->store_64(md_pos); |
| 3402 | f->seek_end(); |
| 3403 | return OK; |
| 3404 | } |
| 3405 | |
| 3406 | void ResourceLoaderCompatBinary::check_suspect_version() { |
| 3407 | // Redot switched to using the year as the major version |
no test coverage detected