diff --git a/Switch_Toolbox_Library/Forms/Editors/AssimpMeshSelector.cs b/Switch_Toolbox_Library/Forms/Editors/AssimpMeshSelector.cs index f1b3d386..1baac71c 100644 --- a/Switch_Toolbox_Library/Forms/Editors/AssimpMeshSelector.cs +++ b/Switch_Toolbox_Library/Forms/Editors/AssimpMeshSelector.cs @@ -28,8 +28,8 @@ namespace Toolbox.Library foreach (Mesh msh in assimp.scene.Meshes) { - if (msh.MaterialIndex != -1 && assimp.materials.Count > msh.MaterialIndex) - listView1.Items.Add($"{msh.Name}_{assimp.materials[msh.MaterialIndex].Name}"); + if (msh.MaterialIndex != -1 && assimp.scene.MaterialCount > msh.MaterialIndex) + listView1.Items.Add($"{msh.Name}_{assimp.scene.Materials[msh.MaterialIndex].Name}"); else listView1.Items.Add(msh.Name); }