1
0
mirror of https://github.com/Cardidi/dotween-upm-fork.git synced 2025-12-20 17:26:03 +08:00
2015-03-18 19:30:48 +01:00

34 lines
621 B
C#

using DG.Tweening;
using UnityEngine;
using UnityEngine.UI;
using System.Collections;
public class Temp : BrainBase
{
public Image img;
Sequence _seq;
void Start()
{
Debug.Log("START");
_seq = DOTween.Sequence().SetId("SEQ");
_seq.Append(img.DOFade(1, 0.5f));
_seq.AppendInterval(3f);
_seq.Append(img.DOFade(0, 0.5f));
_seq.AppendCallback(BalloonComplete);
// _seq.OnComplete(BalloonComplete);
}
void BalloonComplete()
{
Debug.Log("Complete");
_seq.Rewind();
Debug.Log("Rewind called");
}
public void Goforit()
{
Debug.Log("GO");
_seq.Restart();
}
}