From 2af2a84a03fd707cfa4c682aff34d722343d8985 Mon Sep 17 00:00:00 2001 From: Juan Linietsky Date: Fri, 27 Jun 2014 23:21:45 -0300 Subject: Misc Fixes ========== -NOTIFICATION_WM_QUIT fixed on android (seems tha way this is reported changed in newer sdk) -WIP implementation of APK Expansion APIs for publishing games larger than 50mb in Play Store -Feaures in the new tutorials are all present in the sourcecode -This (hopefully) should get rid of the animation list order getting corrupted -Improved 3D Scene Importer (Skeletons, Animations and other stuff were not being merged). Anything missing? -In code editor, the automatic syntax checker will only use file_exists() to check preload() else it might freeze the editor too much while typing if the preload is a big resource -Fixed bugs in PolygonPathFinder, stil pending to do a node and a demo --- core/io/resource_format_binary.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'core/io/resource_format_binary.cpp') diff --git a/core/io/resource_format_binary.cpp b/core/io/resource_format_binary.cpp index 33f4cafed..e2371fe24 100644 --- a/core/io/resource_format_binary.cpp +++ b/core/io/resource_format_binary.cpp @@ -1751,7 +1751,10 @@ Error ResourceFormatSaverBinaryInstance::save(const String &p_path,const RES& p_ skip_editor=p_flags&ResourceSaver::FLAG_OMIT_EDITOR_PROPERTIES; bundle_resources=p_flags&ResourceSaver::FLAG_BUNDLE_RESOURCES; big_endian=p_flags&ResourceSaver::FLAG_SAVE_BIG_ENDIAN; + takeover_paths=p_flags&ResourceSaver::FLAG_REPLACE_SUBRESOURCE_PATHS; + if (!p_path.begins_with("res://")) + takeover_paths=false; local_path=p_path.get_base_dir(); //bin_meta_idx = get_string_index("__bin_meta__"); //is often used, so create @@ -1841,9 +1844,12 @@ Error ResourceFormatSaverBinaryInstance::save(const String &p_path,const RES& p_ for(List::Element *E=saved_resources.front();E;E=E->next()) { RES r = E->get(); - if (r->get_path()=="" || r->get_path().find("::")!=-1) + if (r->get_path()=="" || r->get_path().find("::")!=-1) { save_unicode_string("local://"+itos(ofs_pos.size())); - else + if (takeover_paths) { + r->set_path(p_path+"::"+itos(ofs_pos.size()),true); + } + } else save_unicode_string(r->get_path()); //actual external ofs_pos.push_back(f->get_pos()); f->store_64(0); //offset in 64 bits -- cgit v1.2.3-70-g09d2