From d18b2e599d838201ecf14822d5823269859897da Mon Sep 17 00:00:00 2001 From: Marcel Admiraal Date: Mon, 11 Nov 2019 10:24:04 +0100 Subject: Remove all uses of ERR_EXPLAIN macros. --- modules/assimp/editor_scene_importer_assimp.cpp | 5 +++-- modules/assimp/import_utils.h | 3 +-- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'modules/assimp') diff --git a/modules/assimp/editor_scene_importer_assimp.cpp b/modules/assimp/editor_scene_importer_assimp.cpp index 830e6e7e0c..3172d1e592 100644 --- a/modules/assimp/editor_scene_importer_assimp.cpp +++ b/modules/assimp/editor_scene_importer_assimp.cpp @@ -148,8 +148,9 @@ Node *EditorSceneImporterAssimp::import_scene(const String &p_path, uint32_t p_f //aiProcess_SplitByBoneCount | 0; aiScene *scene = (aiScene *)importer.ReadFile(s_path.c_str(), post_process_Steps); - ERR_EXPLAIN(String("Open Asset Import failed to open: ") + String(importer.GetErrorString())); - ERR_FAIL_COND_V(scene == NULL, NULL); + + ERR_FAIL_COND_V_MSG(scene == NULL, NULL, String("Open Asset Import failed to open: ") + String(importer.GetErrorString())); + return _generate_scene(p_path, scene, p_flags, p_bake_fps, max_bone_weights); } diff --git a/modules/assimp/import_utils.h b/modules/assimp/import_utils.h index 4be76ade0f..7b14804ddc 100644 --- a/modules/assimp/import_utils.h +++ b/modules/assimp/import_utils.h @@ -369,8 +369,7 @@ public: state.path_to_image_cache.insert(p_path, img); return img; } else if (tex->CheckFormat("dds")) { - ERR_EXPLAIN("Open Asset Import: Embedded dds not implemented"); - ERR_FAIL_COND_V(true, Ref()); + ERR_FAIL_COND_V_MSG(true, Ref(), "Open Asset Import: Embedded dds not implemented"); } } else { Ref img; -- cgit v1.2.3