fix: NRE in ProxyManager.MapBone (#801)

This commit is contained in:
bd_ 2024-03-26 14:20:39 +00:00 committed by GitHub
parent 16642454fc
commit 6da55dc08c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -191,7 +191,10 @@ namespace nadena.dev.modular_avatar.core
private static Transform MapBone(Transform srcBone)
{
if (_capturedBones.TryGetValue(srcBone, out var newBone) && newBone != null)
if (srcBone == null)
{
return null;
} else if (_capturedBones.TryGetValue(srcBone, out var newBone) && newBone != null)
{
return newBone;
}