本文整理汇总了C#中UMAData.ChangeBoneScale方法的典型用法代码示例。如果您正苦于以下问题:C# UMAData.ChangeBoneScale方法的具体用法?C# UMAData.ChangeBoneScale怎么用?C# UMAData.ChangeBoneScale使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类UMAData
的用法示例。
在下文中一共展示了UMAData.ChangeBoneScale方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: UpdateUMAFemaleDNABones
//.........这里部分代码省略.........
umaData.boneList["LipsInferiorAdjust"].boneTransform.localPosition = umaData.boneList["LipsInferiorAdjust"].actualBonePosition + new Vector3(
Mathf.Clamp(0, -0.05f, 0.05f),
Mathf.Clamp(0, -0.05f, 0.05f),
Mathf.Clamp(0 + (umaDna.lipsSize - 0.5f) * -0.008f, -0.1f, 0.1f));
umaData.boneList["LeftLipsAdjust"].boneTransform.localPosition = umaData.boneList["LeftLipsAdjust"].actualBonePosition + new Vector3(
Mathf.Clamp(0, -0.05f, 0.05f),
Mathf.Clamp(0 + (umaDna.mouthSize - 0.5f) * 0.03f, -0.02f, 0.005f),
Mathf.Clamp(0, -0.05f, 0.05f));
umaData.boneList["RightLipsAdjust"].boneTransform.localPosition = umaData.boneList["RightLipsAdjust"].actualBonePosition + new Vector3(
Mathf.Clamp(0, -0.05f, 0.05f),
Mathf.Clamp(0 + (umaDna.mouthSize - 0.5f) * -0.03f, -0.005f, 0.02f),
Mathf.Clamp(0, -0.05f, 0.05f));
umaData.boneList["LeftLipsSuperiorMiddleAdjust"].boneTransform.localPosition = umaData.boneList["LeftLipsSuperiorMiddleAdjust"].actualBonePosition + new Vector3(
Mathf.Clamp(0, -0.05f, 0.05f),
Mathf.Clamp(0 + (umaDna.mouthSize - 0.5f) * 0.007f, -0.02f, 0.005f),
Mathf.Clamp(0, -0.05f, 0.05f));
umaData.boneList["RightLipsSuperiorMiddleAdjust"].boneTransform.localPosition = umaData.boneList["RightLipsSuperiorMiddleAdjust"].actualBonePosition + new Vector3(
Mathf.Clamp(0, -0.05f, 0.05f),
Mathf.Clamp(0 + (umaDna.mouthSize - 0.5f) * -0.007f, -0.005f, 0.02f),
Mathf.Clamp(0, -0.05f, 0.05f));
umaData.boneList["LeftLipsInferiorAdjust"].boneTransform.localPosition = umaData.boneList["LeftLipsInferiorAdjust"].actualBonePosition + new Vector3(
Mathf.Clamp(0, -0.05f, 0.05f),
Mathf.Clamp(0 + (umaDna.mouthSize - 0.5f) * 0.007f, -0.02f, 0.005f),
Mathf.Clamp(0 + (umaDna.lipsSize - 0.5f) * -0.008f, -0.1f, 0.1f));
umaData.boneList["RightLipsInferiorAdjust"].boneTransform.localPosition = umaData.boneList["RightLipsInferiorAdjust"].actualBonePosition + new Vector3(
Mathf.Clamp(0, -0.05f, 0.05f),
Mathf.Clamp(0 + (umaDna.mouthSize - 0.5f) * -0.007f, -0.005f, 0.02f),
Mathf.Clamp(0 + (umaDna.lipsSize - 0.5f) * -0.008f, -0.1f, 0.1f));
//Bone structure change
umaData.ChangeBoneScale("Global",
new Vector3(
Mathf.Clamp(1 + (umaDna.height - 0.5f) * 1.0f + (umaDna.legsSize - 0.5f) * 1.0f, 0.5f, 3.0f),
Mathf.Clamp(1 + (umaDna.height - 0.5f) * 1.0f + (umaDna.legsSize - 0.5f) * 1.0f, 0.5f, 3.0f),
Mathf.Clamp(1 + (umaDna.height - 0.5f) * 1.0f + (umaDna.legsSize - 0.5f) * 1.0f, 0.5f, 3.0f)));
umaData.ChangeBoneMoveRelative("Position", new Vector3(
Mathf.Clamp((umaDna.feetSize - 0.5f) * -0.27f, -0.15f, 0.0675f),
Mathf.Clamp(0, -10, 10),
Mathf.Clamp(0, -10, 10)));
umaData.ChangeBoneScale("LowerBack",
new Vector3(
Mathf.Clamp(1 - (umaDna.legsSize - 0.5f) * 1.0f, 0.5f, 3.0f),
Mathf.Clamp(1 - (umaDna.legsSize - 0.5f) * 1.0f, 0.5f, 3.0f),
Mathf.Clamp(1 - (umaDna.legsSize - 0.5f) * 1.0f, 0.5f, 3.0f)));
umaData.ChangeBoneScale("Head",
new Vector3(
Mathf.Clamp(1 + (umaDna.headSize - 0.5f) * 2.0f, 0.5f, 2),
Mathf.Clamp(1 + (umaDna.headSize - 0.5f) * 2.0f, 0.5f, 2),
Mathf.Clamp(1 + (umaDna.headSize - 0.5f) * 2.0f, 0.5f, 2)));
umaData.ChangeBoneScale("LeftArm",
new Vector3(
Mathf.Clamp(1 + (umaDna.armLength - 0.5f) * 2.0f, 0.5f, 2.0f),
Mathf.Clamp(1 + (umaDna.armLength - 0.5f) * 2.0f, 0.5f, 2.0f),
Mathf.Clamp(1 + (umaDna.armLength - 0.5f) * 2.0f, 0.5f, 2.0f)));
umaData.ChangeBoneScale("RightArm",
new Vector3(
Mathf.Clamp(1 + (umaDna.armLength - 0.5f) * 2.0f, 0.5f, 2.0f),
Mathf.Clamp(1 + (umaDna.armLength - 0.5f) * 2.0f, 0.5f, 2.0f),
Mathf.Clamp(1 + (umaDna.armLength - 0.5f) * 2.0f, 0.5f, 2.0f)));