Sync fork (#73)
* Improved UI layout and live vocals * New Live Compatibility * Android build support * Update build.yml * Fix issues with the new version of the game * add config button * Improve performance * bug fix, new uma compatibility --------- Co-authored-by: CroakFang <1605296300@qq.com>
This commit is contained in:
@@ -5,7 +5,6 @@ using UnityEngine;
|
||||
using static RootMotion.FinalIK.IKSolverVR;
|
||||
using System.Linq;
|
||||
using System.IO;
|
||||
using static UnityEngine.Rendering.VirtualTexturing.Debugging;
|
||||
using static Gallop.Live.Cutt.LiveTimelineDefine;
|
||||
|
||||
namespace Gallop.Live.Cutt
|
||||
@@ -355,7 +354,7 @@ namespace Gallop.Live.Cutt
|
||||
MulFrame.Add(mulframe);
|
||||
}
|
||||
|
||||
if (currentFrame % 2 == 0) RecordUma?.Invoke();
|
||||
if (currentFrame % 2 == 0) RecordUma?.Invoke(); //Set 30 FPS
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -72,7 +72,10 @@ namespace Gallop.Live.Cutt
|
||||
{
|
||||
foreach (var key in _currentKey.thisList)
|
||||
{
|
||||
_tempAnim.AddClip(key.clip, key.clip.name);
|
||||
if(key.clip != null)
|
||||
{
|
||||
_tempAnim.AddClip(key.clip, key.clip.name);
|
||||
}
|
||||
}
|
||||
}
|
||||
_tempAnim.wrapMode = WrapMode.Clamp;
|
||||
@@ -122,13 +125,15 @@ namespace Gallop.Live.Cutt
|
||||
double interval = (currentTime - arg.FrameSecond) * arg.playSpeed;
|
||||
float currentAnimationTime = (float)(start + interval);
|
||||
|
||||
var state = _tempAnim[anim.name];
|
||||
state.enabled = true;
|
||||
state.weight = 1;
|
||||
state.time = arg.loop ? Mathf.Repeat(currentAnimationTime, state.length) : currentAnimationTime;
|
||||
_tempAnim.Sample();
|
||||
state.enabled = false;
|
||||
|
||||
if (anim)
|
||||
{
|
||||
var state = _tempAnim[anim.name];
|
||||
state.enabled = true;
|
||||
state.weight = 1;
|
||||
state.time = arg.loop ? Mathf.Repeat(currentAnimationTime, state.length) : currentAnimationTime;
|
||||
_tempAnim.Sample();
|
||||
state.enabled = false;
|
||||
}
|
||||
_prevIndex = _curIndex;
|
||||
}
|
||||
_prevFrameAnimationTime = currentTime;
|
||||
|
||||
Reference in New Issue
Block a user