Improve format version mismatch error in binary loader
(cherry picked from commit e35bb04c53
)
This commit is contained in:
parent
9529ce41eb
commit
6c03ac6625
1 changed files with 5 additions and 2 deletions
|
@ -876,7 +876,8 @@ void ResourceInteractiveLoaderBinary::open(FileAccess *p_f) {
|
|||
if (ver_format > FORMAT_VERSION || ver_major > VERSION_MAJOR) {
|
||||
|
||||
f->close();
|
||||
ERR_FAIL_MSG("File format '" + itos(FORMAT_VERSION) + "." + itos(ver_major) + "." + itos(ver_minor) + "' is too new! Please upgrade to a new engine version: " + local_path + ".");
|
||||
ERR_FAIL_MSG(vformat("File '%s' can't be loaded, as it uses a format version (%d) or engine version (%d.%d) which are not supported by your engine version (%s).",
|
||||
local_path, ver_format, ver_major, ver_minor, VERSION_BRANCH));
|
||||
}
|
||||
|
||||
type = get_unicode_string();
|
||||
|
@ -1159,7 +1160,9 @@ Error ResourceFormatLoaderBinary::rename_dependencies(const String &p_path, cons
|
|||
|
||||
memdelete(f);
|
||||
memdelete(fw);
|
||||
ERR_FAIL_V_MSG(ERR_FILE_UNRECOGNIZED, "File format '" + itos(FORMAT_VERSION) + "." + itos(ver_major) + "." + itos(ver_minor) + "' is too new! Please upgrade to a new engine version: " + local_path + ".");
|
||||
ERR_FAIL_V_MSG(ERR_FILE_UNRECOGNIZED,
|
||||
vformat("File '%s' can't be loaded, as it uses a format version (%d) or engine version (%d.%d) which are not supported by your engine version (%s).",
|
||||
local_path, ver_format, ver_major, ver_minor, VERSION_BRANCH));
|
||||
}
|
||||
|
||||
// Since we're not actually converting the file contents, leave the version
|
||||
|
|
Loading…
Reference in a new issue