mirror of
https://github.com/vrm-c/UniVRM.git
synced 2026-09-12 13:59:21 -05:00
fix binds KeyNotFoundException in migration.
This commit is contained in:
@@ -239,8 +239,10 @@ namespace UniVRM10
|
||||
MaterialColorBinds = new List<UniGLTF.Extensions.VRMC_vrm.MaterialColorBind>(),
|
||||
TextureTransformBinds = new List<UniGLTF.Extensions.VRMC_vrm.TextureTransformBind>(),
|
||||
};
|
||||
expression.MorphTargetBinds = ToMorphTargetBinds(blendShapeClip["binds"], meshToNode).ToList();
|
||||
|
||||
if (blendShapeClip.TryGet("binds", out JsonNode binds))
|
||||
{
|
||||
expression.MorphTargetBinds = ToMorphTargetBinds(binds, meshToNode).ToList();
|
||||
}
|
||||
if (blendShapeClip.TryGet("materialValues", out JsonNode materialValues))
|
||||
{
|
||||
ToMaterialColorBinds(gltf, materialValues, expression);
|
||||
|
||||
Reference in New Issue
Block a user