minor bug fix

This commit is contained in:
左右看
2023-07-12 18:27:55 +08:00
parent d1d1a2f771
commit 9bc7e58d50
4 changed files with 23 additions and 5 deletions
@@ -810,11 +810,13 @@ namespace Gallop
{
//|| lockMouth
if (_switch == 0 || lockMouth)
{
return;
}
float weightRatio = CalcMorphWeight(liveTime_, keyData_.time, keyData_.interpolateType, keyData_, null);
@@ -855,7 +857,7 @@ namespace Gallop
{
if (updateInfo_.mouthCur != null)
{
if((int)updateInfo_.mouthCur.attribute == 131072)
if((int)updateInfo_.mouthCur.attribute == 131072 || (int)updateInfo_.mouthCur.attribute == 0)
{
lockMouth = true;
}
@@ -31,6 +31,8 @@ namespace Gallop.Live.Cutt
private AnimationClip _targetAnim = null;
private bool _motionSetup = false;
public void Initialize(Transform target, int targetIndex, int seqDataIndex, LiveTimelineControl timelineControl, List<AnimationClip> animclips = null)
{
if(animclips != null)
@@ -73,10 +75,23 @@ namespace Gallop.Live.Cutt
{
if(Director.instance.liveMode == 0)
{
if(_targetAnim != null)
{
_tempAnim[_targetAnim.name].time = currentTime;
_tempAnim.Play(_targetAnim.name);
//_tempAnim[_targetAnim.name].time = currentTime;
if (Director.instance.sliderControl.is_Touched)
{
_tempAnim[_targetAnim.name].time = currentTime;
_tempAnim.Play(_targetAnim.name);
_motionSetup = false;
}
else if (!_motionSetup)
{
_tempAnim[_targetAnim.name].time = currentTime;
_tempAnim.Play(_targetAnim.name);
_motionSetup = true;
}
}
return;
}
@@ -220,7 +220,7 @@ namespace Gallop.Live.Cutt
public abstract class LiveTimelineKey
{
public int frame;
public LiveTimelineKeyAttribute attribute;
public int attribute;
}
[System.Serializable]
@@ -587,6 +587,7 @@ namespace Gallop.Live
foreach (var song in liveSong)
{
song.time = _liveCurrentTime;
song.Play();
}
}
@@ -624,7 +625,7 @@ namespace Gallop.Live
UI.ProgressBar.value = _liveCurrentTime / totalTime;
//Debug.Log((float)liveMusic.time / 1000);
//Debug.Log(_liveCurrentTime);
Debug.Log(_liveCurrentTime * 60);
OnTimelineUpdate(_liveCurrentTime);
}
}