Hi all,
I am having trouble using “AssetDatabase.LoadAssetAtPath” and even using “Resources.Load” to load a .mesh file in the editor hierarchy and assign it to a prefab’s MeshFilter.
I am doing this as an editor function, not application runtime. I am trying to use the following code:
Mesh referenceMesh = (Mesh)AssetDatabase.LoadAssetAtPath(newMeshRefPath, typeof(Mesh)) as Mesh;
The path is correct, I have triple checked it in debug and it is returning null. Can .mesh files be loaded like this? Does anyone have an alternative if not?
Thanks!