瀏覽代碼

Merge pull request #46576 from BastiaanOlij/fix_fbx_unique_bone_names

Fix duplicate check for bone names in FBX import
Rémi Verschelde 4 年之前
父節點
當前提交
2d0dcd2e6c
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      modules/fbx/data/fbx_skeleton.cpp

+ 1 - 1
modules/fbx/data/fbx_skeleton.cpp

@@ -69,7 +69,7 @@ void FBXSkeleton::init_skeleton(const ImportState &state) {
 			// Make sure the bone name is unique.
 			const String bone_name = bone->bone_name;
 			int same_name_count = 0;
-			for (int y = x; y < skeleton_bone_count; y++) {
+			for (int y = x + 1; y < skeleton_bone_count; y++) {
 				Ref<FBXBone> other_bone = skeleton_bones[y];
 				if (other_bone.is_valid()) {
 					if (other_bone->bone_name == bone_name) {