File tree Expand file tree Collapse file tree
Sources/OvEditor/src/OvEditor/Core Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -147,7 +147,22 @@ void OvEditor::Core::Editor::SetupUI()
147147 OvCore::Helpers::GUIHelpers::SetAssetExistsChecker (
148148 [this ](const std::string& p_path)
149149 {
150- return std::filesystem::exists (m_editorActions.GetRealPath (p_path));
150+ const std::string path = OvTools::Utils::PathParser::MakeNonWindowsStyle (p_path);
151+
152+ if (const auto embeddedAssetPath = ParseEmbeddedAssetPath (path); embeddedAssetPath)
153+ {
154+ const bool isEmbeddedMaterial = ParseEmbeddedMaterialIndex (embeddedAssetPath->assetName ).has_value ();
155+ const bool isEmbeddedTexture = ParseEmbeddedTextureIndex (embeddedAssetPath->assetName ).has_value ();
156+
157+ if (isEmbeddedMaterial || isEmbeddedTexture)
158+ {
159+ return std::filesystem::exists (m_editorActions.GetRealPath (embeddedAssetPath->modelPath ));
160+ }
161+
162+ return false ;
163+ }
164+
165+ return std::filesystem::exists (m_editorActions.GetRealPath (path));
151166 }
152167 );
153168
You can’t perform that action at this time.
0 commit comments