[LayaAirIDE 2.0]播放多个模型动作,FPS一直在持续减少.
在Animator的__proto.updatePlayer方法中,
if (elapsedPlaybackTime >=clipDuration){
do {
elapsedPlaybackTime-=clipDuration;
playState._playEventIndex=0;
animatorState._resetFrameIndices();
}while (elapsedPlaybackTime >=clipDuration)
这里导致的问题.
应该修改为:
if (elapsedPlaybackTime >=clipDuration){
do {
elapsedPlaybackTime-=clipDuration;
}while (elapsedPlaybackTime >=clipDuration)
playState._elapsedTime = elapsedPlaybackTime;
playState._playEventIndex=0;
animatorState._resetFrameIndices();
}
if (elapsedPlaybackTime >=clipDuration){
do {
elapsedPlaybackTime-=clipDuration;
playState._playEventIndex=0;
animatorState._resetFrameIndices();
}while (elapsedPlaybackTime >=clipDuration)
这里导致的问题.
应该修改为:
if (elapsedPlaybackTime >=clipDuration){
do {
elapsedPlaybackTime-=clipDuration;
}while (elapsedPlaybackTime >=clipDuration)
playState._elapsedTime = elapsedPlaybackTime;
playState._playEventIndex=0;
animatorState._resetFrameIndices();
}
没有找到相关结果
已邀请:
要回复问题请先登录
1 个回复
Aar0n
赞同来自: