[unity] Fixed Inspector ArgumentOutOfRangeException at searching propertyPath. Closes #2746.

This commit is contained in:
Harald Csaszar 2025-02-10 18:19:46 +01:00
parent eca4b9e4c1
commit 1121e88422
2 changed files with 9 additions and 7 deletions

View File

@ -155,6 +155,7 @@ namespace Spine.Unity.Editor {
// If this fails as well, try at any base property up the hierarchy
if (relativeProperty == null) {
int dotIndex = propertyPath.Length - property.name.Length - 1;
if (dotIndex > 0) {
while (relativeProperty == null) {
dotIndex = propertyPath.LastIndexOf('.', dotIndex - 1);
if (dotIndex < 0)
@ -164,6 +165,7 @@ namespace Spine.Unity.Editor {
}
}
}
}
return relativeProperty;
}

View File

@ -2,7 +2,7 @@
"name": "com.esotericsoftware.spine.spine-unity",
"displayName": "spine-unity Runtime",
"description": "This plugin provides the spine-unity runtime core.",
"version": "4.2.95",
"version": "4.2.96",
"unity": "2018.3",
"author": {
"name": "Esoteric Software",