diff options
author | Juan Linietsky <reduzio@gmail.com> | 2015-10-21 23:57:43 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2015-10-21 23:57:43 -0300 |
commit | d123c89c5802777e02402108d9271ed2f29368fe (patch) | |
tree | 9a814a9d24278dd25d29f25dfd4ca2d919649d0b /core | |
parent | 6426ea61d7cf9e1bd7ff97831fccae0ebac3225a (diff) |
-fixed a quite serious scene corruption bug when saving that has been around for months.
good thing no one ran into it :P
Diffstat (limited to 'core')
-rw-r--r-- | core/io/resource_format_binary.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/core/io/resource_format_binary.cpp b/core/io/resource_format_binary.cpp index 60bb8b658e..1a0552e8d1 100644 --- a/core/io/resource_format_binary.cpp +++ b/core/io/resource_format_binary.cpp @@ -2172,10 +2172,11 @@ Error ResourceFormatSaverBinaryInstance::save(const String &p_path,const RES& p_ save_unicode_string("local://"+itos(r->get_subindex())); if (takeover_paths) { - r->set_path(p_path+"::"+itos(ofs_pos.size()),true); + r->set_path(p_path+"::"+itos(r->get_subindex()),true); } - } else + } else { save_unicode_string(r->get_path()); //actual external + } ofs_pos.push_back(f->get_pos()); f->store_64(0); //offset in 64 bits } |