/// <summary> /// 卷动特效 /// </summary> /// <param name="spriteName">新图</param> /// <param name="direction">方向(默认:左)</param> /// <param name="isBoth">是否两图同时卷动</param> /// <param name="time">持续时长s(默认0.5s)</param> public EffectPiece Scroll(string spriteName, string direction = "left", bool isBoth = false, float time = 0.5f) { Queue <NewImageEffect> effects = new Queue <NewImageEffect>(); if (isBoth) { effects.Enqueue(NewEffectBuilder.ScrollBoth(spriteName, direction, time)); } else { effects.Enqueue(NewEffectBuilder.Scroll(spriteName, direction, time)); } effects.Enqueue(NewEffectBuilder.SetSpriteByDepth(-1, spriteName)); return(new EffectPiece(id++, effects)); }