diff --git a/Assets/Scripts/UI/UITimeTip.cs b/Assets/Scripts/UI/UITimeTip.cs index 5cb20689..8952af93 100644 --- a/Assets/Scripts/UI/UITimeTip.cs +++ b/Assets/Scripts/UI/UITimeTip.cs @@ -85,8 +85,15 @@ namespace QFramework.Example imgTwen = DOTween.To(() => index, v => { index = v; - Img.sprite = sprites[index]; - Img.SetNativeSize(); + if (index>=0&&index < sprites.Count) + { + Img.sprite = sprites[index]; + Img.SetNativeSize(); + } + else + { + Debug.Log("UITimeTipChao suo Yin"); + } }, endIndex, mData.time);