1
0
mirror of https://github.com/Cardidi/dotween-upm-fork.git synced 2025-12-20 01:06:02 +08:00
This commit is contained in:
Demigiant 2016-10-26 11:33:05 +02:00
parent c7d916ef53
commit 85b2efd056
46 changed files with 8 additions and 36 deletions

View File

@ -5,15 +5,15 @@ using DG.Tweening;
public class TempPro : MonoBehaviour
{
public DOTweenPath path;
public Transform target;
void Start ()
{
path.GetTween().OnWaypointChange(OnWaypointChange);
target.DOMoveX(3, 1).OnComplete(TempPro.OnCompleteCallback);
}
void OnWaypointChange (int index)
public static void OnCompleteCallback()
{
Debug.Log(index);
Debug.Log("Hello I'm public! And Static! Love me!");
}
}

View File

@ -11,37 +11,8 @@ using UnityEngine.UI;
public class TempTests : BrainBase
{
public int poolId;
public Transform target;
private Transform myTransform;
private Color baseColor;
void Awake () {
myTransform = transform;
}
public void Show (string txt) {
myTransform.SetAsLastSibling ();
this.StartCoroutine(RemoveIn());
}
IEnumerator RemoveIn () {
yield return new WaitForSeconds(4);
Hide ();
}
private void Hide ()
public void OnComplete()
{
target.DOMoveX(2, 1).OnComplete (Remove);
}
private void Remove ()
{
target.gameObject.SetActive(false);
// Destroy(target.gameObject);
}
void OnDisable ()
{
target.DOKill();
Debug.Log("ON COMPLETE");
}
}

View File

@ -125,7 +125,7 @@ namespace DG.Tweening.Core
}
// _tweenPlugin is not reset since it's useful to keep it as a reference
internal override sealed void Reset()
internal sealed override void Reset()
{
base.Reset();

View File

@ -253,6 +253,7 @@ namespace DG.Tweening
/// <summary>
/// Checks all active tweens to find and remove eventually invalid ones (usually because their targets became NULL)
/// and returns the total number of invalid tweens found and removed.
/// IMPORTANT: this will cause an error on UWP platform, so don't use it there
/// BEWARE: this is a slightly expensive operation so use it with care
/// </summary>
public static int Validate()

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.