Added morph clear button
removed redundant property
This commit is contained in:
@@ -142,17 +142,17 @@ namespace Gallop
|
||||
{
|
||||
foreach (FacialMorph morph in EyeBrowMorphs)
|
||||
{
|
||||
morph._weight = 0;
|
||||
morph.weight = 0;
|
||||
}
|
||||
|
||||
foreach (FacialMorph morph in EyeMorphs)
|
||||
{
|
||||
morph._weight = 0;
|
||||
morph.weight = 0;
|
||||
}
|
||||
|
||||
foreach (FacialMorph morph in MouthMorphs)
|
||||
{
|
||||
morph._weight = 0;
|
||||
morph.weight = 0;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -162,9 +162,9 @@ namespace Gallop
|
||||
{
|
||||
if (trs.transform)
|
||||
{
|
||||
trs.transform.localScale += trs._scale * morph.Weight;
|
||||
trs.transform.localPosition += trs._position * morph.Weight;
|
||||
RotationRecorder[trs.transform] += trs._rotation * morph.Weight;
|
||||
trs.transform.localScale += trs._scale * morph.weight;
|
||||
trs.transform.localPosition += trs._position * morph.weight;
|
||||
RotationRecorder[trs.transform] += trs._rotation * morph.weight;
|
||||
};
|
||||
}
|
||||
}
|
||||
@@ -202,7 +202,7 @@ namespace Gallop
|
||||
|
||||
public void ChangeMorphWeight(FacialMorph morph,float val)
|
||||
{
|
||||
morph.Weight = val;
|
||||
morph.weight = val;
|
||||
ChangeMorph();
|
||||
}
|
||||
|
||||
|
||||
@@ -48,7 +48,7 @@ public class FaceEmotionKeyTarget : ScriptableObject
|
||||
}
|
||||
newValue.weight = Convert.ToInt32(splitArray[1]);
|
||||
faceTypeData.emotionKeys.Add(newValue);
|
||||
Debug.Log(newValue.weight);
|
||||
//Debug.Log(newValue.weight);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -62,7 +62,7 @@ public class FaceEmotionKeyTarget : ScriptableObject
|
||||
}
|
||||
newValue.weight = 100;
|
||||
faceTypeData.emotionKeys.Add(newValue);
|
||||
Debug.Log(morphName);
|
||||
//Debug.Log(morphName);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -78,7 +78,7 @@ public class FaceEmotionKeyTarget : ScriptableObject
|
||||
{
|
||||
foreach (var key in emotion.emotionKeys)
|
||||
{
|
||||
key.morph.Weight += key.weight / 100 * emotion.Weight;
|
||||
key.morph.weight += key.weight / 100 * emotion.Weight;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -14,18 +14,7 @@ namespace Gallop
|
||||
public string tag = "";
|
||||
public bool direction;
|
||||
public FaceDrivenKeyTarget target;
|
||||
public float _weight;
|
||||
public float Weight
|
||||
{
|
||||
get
|
||||
{
|
||||
return _weight;
|
||||
}
|
||||
set
|
||||
{
|
||||
_weight = value;
|
||||
}
|
||||
}
|
||||
public float weight;
|
||||
public List<TrsArray> trsArray;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user