コード例 #1
0
        /* TextMeshProUGUI */
#if ENABLE_TMPRO
        public static Tween TwFade(this TextMeshProUGUI p, DOTweenFloat tf, Action complete = null)
        {
            p.SetAlpha(tf.start);
            return(p.DOFade(tf.end, tf.time).SetEase(tf.ease).OnComplete(() => { complete.Call(); }));
        }
コード例 #2
0
 /* Image */
 public static Tween TwFade(this Image p, DOTweenFloat tf, System.Action complete = null)
 {
     p.SetAlpha(tf.start);
     return(p.DOFade(tf.end, tf.time).SetEase(tf.ease).OnComplete(() => { complete.Call(); }));
 }
コード例 #3
0
 public static Tween TwRotateZ <T>(this T p, DOTweenFloat t, RotateMode rt = RotateMode.Fast, Action complete = null) where T : Component
 {
     p.transform.localEulerAngles = v3.v(0, 0, t.start);
     return(p.transform.DOLocalRotate(v3.v(0, 0, t.end), t.time, rt).SetEase(t.ease).OnComplete(() => { complete.Call(); }));
 }
コード例 #4
0
 public static Tween TwScale <T>(this T p, DOTweenFloat tf, Action complete = null) where T : Component
 {
     p.transform.SetLocalScl(tf.start);
     return(p.transform.DOScale(tf.end, tf.time).SetEase(tf.ease).OnComplete(() => { complete.Call(); }));
 }
コード例 #5
0
 public static Tween TwLocalMoveY <T>(this T p, DOTweenFloat tw, Action complete = null) where T : Component
 {
     p.transform.SetLocalPosY(tw.start);
     return(p.transform.DOLocalMoveY(tw.end, tw.time).SetEase(tw.ease).OnComplete(() => { complete.Call(); }));
 }