diff --git a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween.XML b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween.XML index bdbfcd5..3b3232a 100644 --- a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween.XML +++ b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween.XML @@ -734,34 +734,38 @@ A tween is considered as playing even if its delay is actually playing - + Returns a list of all active tweens in a playing state. Returns NULL if there are no active playing tweens. Beware: each time you call this method a new list is generated, so use it for debug only + If NULL creates a new list, otherwise fills this one (and thus saves allocations) - + Returns a list of all active tweens in a paused state. Returns NULL if there are no active paused tweens. Beware: each time you call this method a new list is generated, so use it for debug only + If NULL creates a new list, otherwise fills this one (and thus saves allocations) - + Returns a list of all active tweens with the given id. Returns NULL if there are no active tweens with the given id. Beware: each time you call this method a new list is generated - If TRUE returns only the tweens with the given ID that are currently playing + If TRUE returns only the tweens with the given ID that are currently playing + If NULL creates a new list, otherwise fills this one (and thus saves allocations) - + Returns a list of all active tweens with the given target. Returns NULL if there are no active tweens with the given target. Beware: each time you call this method a new list is generated If TRUE returns only the tweens with the given target that are currently playing + If NULL creates a new list, otherwise fills this one (and thus saves allocations) diff --git a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween.dll b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween.dll index a0c03eb..2f0c0d2 100644 Binary files a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween.dll and b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween.dll differ diff --git a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween.dll.mdb b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween.dll.mdb index 1bd1f02..918d50e 100644 Binary files a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween.dll.mdb and b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween.dll.mdb differ diff --git a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween43.dll b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween43.dll index 0bc4660..4cd3312 100644 Binary files a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween43.dll and b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween43.dll differ diff --git a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween43.dll.mdb b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween43.dll.mdb index 7938c87..c174bb1 100644 Binary files a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween43.dll.mdb and b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween43.dll.mdb differ diff --git a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween46.dll b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween46.dll index 15534c3..2e36d82 100644 Binary files a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween46.dll and b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween46.dll differ diff --git a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween46.dll.mdb b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween46.dll.mdb index e907dcb..3bf6339 100644 Binary files a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween46.dll.mdb and b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween46.dll.mdb differ diff --git a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween50.dll b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween50.dll index 73a85a3..2e1fc1d 100644 Binary files a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween50.dll and b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween50.dll differ diff --git a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween50.dll.mdb b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween50.dll.mdb index c484e51..4b028a1 100644 Binary files a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween50.dll.mdb and b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween50.dll.mdb differ diff --git a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll index 24675e9..7ed9e6f 100644 Binary files a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll and b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll differ diff --git a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb index f12880e..4a3fc2f 100644 Binary files a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb and b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb differ diff --git a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween.XML b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween.XML index bdbfcd5..3b3232a 100644 --- a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween.XML +++ b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween.XML @@ -734,34 +734,38 @@ A tween is considered as playing even if its delay is actually playing - + Returns a list of all active tweens in a playing state. Returns NULL if there are no active playing tweens. Beware: each time you call this method a new list is generated, so use it for debug only + If NULL creates a new list, otherwise fills this one (and thus saves allocations) - + Returns a list of all active tweens in a paused state. Returns NULL if there are no active paused tweens. Beware: each time you call this method a new list is generated, so use it for debug only + If NULL creates a new list, otherwise fills this one (and thus saves allocations) - + Returns a list of all active tweens with the given id. Returns NULL if there are no active tweens with the given id. Beware: each time you call this method a new list is generated - If TRUE returns only the tweens with the given ID that are currently playing + If TRUE returns only the tweens with the given ID that are currently playing + If NULL creates a new list, otherwise fills this one (and thus saves allocations) - + Returns a list of all active tweens with the given target. Returns NULL if there are no active tweens with the given target. Beware: each time you call this method a new list is generated If TRUE returns only the tweens with the given target that are currently playing + If NULL creates a new list, otherwise fills this one (and thus saves allocations) diff --git a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween.dll b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween.dll index a0c03eb..2f0c0d2 100644 Binary files a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween.dll and b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween.dll differ diff --git a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween.dll.mdb b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween.dll.mdb index 1bd1f02..918d50e 100644 Binary files a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween.dll.mdb and b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween.dll.mdb differ diff --git a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween43.dll b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween43.dll index 0bc4660..4cd3312 100644 Binary files a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween43.dll and b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween43.dll differ diff --git a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween43.dll.mdb b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween43.dll.mdb index 7938c87..c174bb1 100644 Binary files a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween43.dll.mdb and b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween43.dll.mdb differ diff --git a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween46.dll b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween46.dll index 15534c3..2e36d82 100644 Binary files a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween46.dll and b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween46.dll differ diff --git a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween46.dll.mdb b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween46.dll.mdb index e907dcb..3bf6339 100644 Binary files a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween46.dll.mdb and b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween46.dll.mdb differ diff --git a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween50.dll b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween50.dll index 73a85a3..2e1fc1d 100644 Binary files a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween50.dll and b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween50.dll differ diff --git a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween50.dll.mdb b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween50.dll.mdb index c484e51..4b028a1 100644 Binary files a/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween50.dll.mdb and b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween50.dll.mdb differ diff --git a/UnityTests.Unity4/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll b/UnityTests.Unity4/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll index 24675e9..7ed9e6f 100644 Binary files a/UnityTests.Unity4/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll and b/UnityTests.Unity4/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll differ diff --git a/UnityTests.Unity4/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb b/UnityTests.Unity4/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb index f12880e..4a3fc2f 100644 Binary files a/UnityTests.Unity4/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb and b/UnityTests.Unity4/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb differ diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween Extras.meta b/UnityTests.Unity5/Assets/Demigiant/DOTween Extras.meta new file mode 100644 index 0000000..e1f1f1e --- /dev/null +++ b/UnityTests.Unity5/Assets/Demigiant/DOTween Extras.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: d032eb15eceb9a1408c8cbdbee442517 +folderAsset: yes +timeCreated: 1509214341 +licenseType: Pro +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween Extras/DOTweenExtras.cs b/UnityTests.Unity5/Assets/Demigiant/DOTween Extras/DOTweenExtras.cs new file mode 100644 index 0000000..2edfb2b --- /dev/null +++ b/UnityTests.Unity5/Assets/Demigiant/DOTween Extras/DOTweenExtras.cs @@ -0,0 +1,102 @@ +// Author: Daniele Giardini - http://www.demigiant.com +// Created: 2017/10/28 20:13 +// License Copyright (c) Daniele Giardini + +using System.Collections.Generic; + +namespace DG.Tweening +{ + /// + /// Extra DOTween methods not included in public engine (for consistency reasons) + /// + public static class DOTweenExtras + { + static readonly List _RecyclableList = new List(); + + #region Public Methods + + /// + /// Returns TRUE if there are tweens with the given id, and they're all currently playing forward + /// + public static bool IsPlayForwardById(object id) + { + List tweens = DOTween.TweensById(id, false, _RecyclableList); + return AreAllPlayingForward(tweens); + } + /// + /// Returns TRUE if there are tweens with the given target, and they're all currently playing forward + /// + public static bool IsPlayForwardByTarget(object target) + { + List tweens = DOTween.TweensByTarget(target, false, _RecyclableList); + return AreAllPlayingForward(tweens); + } + + /// + /// Returns TRUE if there are tweens with the given id, and they're all currently playing backwards + /// + public static bool IsPlayBackwardsById(object id) + { + List tweens = DOTween.TweensById(id, false, _RecyclableList); + return AreAllPlayingBackwards(tweens); + } + /// + /// Returns TRUE if there are tweens with the given target, and they're all currently playing backwards + /// + public static bool IsPlayBackwardsByTarget(object target) + { + List tweens = DOTween.TweensByTarget(target, false, _RecyclableList); + return AreAllPlayingBackwards(tweens); + } + + /// + /// Returns TRUE if there are tweens with the given id, and they're all currently paused + /// + public static bool IsPausedById(object id) + { + List tweens = DOTween.TweensById(id, false, _RecyclableList); + return AreAllPaused(tweens); + } + /// + /// Returns TRUE if there are tweens with the given target, and they're all currently paused + /// + public static bool IsPausedByTarget(object target) + { + List tweens = DOTween.TweensByTarget(target, false, _RecyclableList); + return AreAllPaused(tweens); + } + + #endregion + + #region Methods + + static bool AreAllPlayingForward(List tweens) + { + if (tweens == null) return false; + foreach (Tween t in tweens) { + if (!t.IsPlaying() || t.isBackwards) return false; + } + return true; + } + + static bool AreAllPlayingBackwards(List tweens) + { + if (tweens == null) return false; + foreach (Tween t in tweens) { + if (!t.IsPlaying() || !t.isBackwards) return false; + } + return true; + } + + static bool AreAllPaused(List tweens) + { + if (tweens == null) return false; + foreach (Tween t in tweens) { + if (t.IsPlaying()) return false; + } + return true; + } + + #endregion + } +} \ No newline at end of file diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween Extras/DOTweenExtras.cs.meta b/UnityTests.Unity5/Assets/Demigiant/DOTween Extras/DOTweenExtras.cs.meta new file mode 100644 index 0000000..a1f3b5a --- /dev/null +++ b/UnityTests.Unity5/Assets/Demigiant/DOTween Extras/DOTweenExtras.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 075e72a77e604361b462a0932ffae8ab +timeCreated: 1509214382 \ No newline at end of file diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween.XML b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween.XML index bdbfcd5..3b3232a 100644 --- a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween.XML +++ b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween.XML @@ -734,34 +734,38 @@ A tween is considered as playing even if its delay is actually playing - + Returns a list of all active tweens in a playing state. Returns NULL if there are no active playing tweens. Beware: each time you call this method a new list is generated, so use it for debug only + If NULL creates a new list, otherwise fills this one (and thus saves allocations) - + Returns a list of all active tweens in a paused state. Returns NULL if there are no active paused tweens. Beware: each time you call this method a new list is generated, so use it for debug only + If NULL creates a new list, otherwise fills this one (and thus saves allocations) - + Returns a list of all active tweens with the given id. Returns NULL if there are no active tweens with the given id. Beware: each time you call this method a new list is generated - If TRUE returns only the tweens with the given ID that are currently playing + If TRUE returns only the tweens with the given ID that are currently playing + If NULL creates a new list, otherwise fills this one (and thus saves allocations) - + Returns a list of all active tweens with the given target. Returns NULL if there are no active tweens with the given target. Beware: each time you call this method a new list is generated If TRUE returns only the tweens with the given target that are currently playing + If NULL creates a new list, otherwise fills this one (and thus saves allocations) diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween.dll b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween.dll index a0c03eb..2f0c0d2 100644 Binary files a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween.dll and b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween.dll differ diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween.dll.mdb b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween.dll.mdb index 1bd1f02..918d50e 100644 Binary files a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween.dll.mdb and b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween.dll.mdb differ diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween43.dll b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween43.dll index 0bc4660..4cd3312 100644 Binary files a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween43.dll and b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween43.dll differ diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween43.dll.mdb b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween43.dll.mdb index 7938c87..c174bb1 100644 Binary files a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween43.dll.mdb and b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween43.dll.mdb differ diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween46.dll b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween46.dll index 15534c3..2e36d82 100644 Binary files a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween46.dll and b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween46.dll differ diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween46.dll.mdb b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween46.dll.mdb index e907dcb..3bf6339 100644 Binary files a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween46.dll.mdb and b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween46.dll.mdb differ diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween50.dll b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween50.dll index 73a85a3..2e1fc1d 100644 Binary files a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween50.dll and b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween50.dll differ diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween50.dll.mdb b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween50.dll.mdb index c484e51..4b028a1 100644 Binary files a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween50.dll.mdb and b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween50.dll.mdb differ diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll b/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll index 24675e9..7ed9e6f 100644 Binary files a/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll and b/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll differ diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb b/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb index f12880e..4a3fc2f 100644 Binary files a/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb and b/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb differ diff --git a/UnityTests.Unity5/Assets/_Tests PRO/TempPro.unity b/UnityTests.Unity5/Assets/_Tests PRO/TempPro.unity index 753b2e6..fc02f77 100644 Binary files a/UnityTests.Unity5/Assets/_Tests PRO/TempPro.unity and b/UnityTests.Unity5/Assets/_Tests PRO/TempPro.unity differ diff --git a/UnityTests.Unity5/Assets/_Tests/TempTests_Extras.cs b/UnityTests.Unity5/Assets/_Tests/TempTests_Extras.cs new file mode 100644 index 0000000..85e5bf9 --- /dev/null +++ b/UnityTests.Unity5/Assets/_Tests/TempTests_Extras.cs @@ -0,0 +1,33 @@ +// Author: Daniele Giardini - http://www.demigiant.com +// Created: 2017/10/28 20:39 +// License Copyright (c) Daniele Giardini + +using System.Collections; +using DG.Tweening; +using UnityEngine; + +namespace _Tests +{ + public class TempTests_Extras : MonoBehaviour + { + public Transform target; + + IEnumerator Start() + { + target.DOMoveX(2, 2).SetAutoKill(false); + target.DOMoveY(2, 2).SetAutoKill(false); + + yield return new WaitForSeconds(1); + + Debug.Log("Are all playing forward: " + DOTweenExtras.IsPlayForwardByTarget(target)); + Debug.Log("Are all playing backwards: " + DOTweenExtras.IsPlayBackwardsByTarget(target)); + Debug.Log("Are all paused: " + DOTweenExtras.IsPausedByTarget(target)); + + yield return new WaitForSeconds(1.2f); + + Debug.Log("Are all playing forward: " + DOTweenExtras.IsPlayForwardByTarget(target)); + Debug.Log("Are all playing backwards: " + DOTweenExtras.IsPlayBackwardsByTarget(target)); + Debug.Log("Are all paused: " + DOTweenExtras.IsPausedByTarget(target)); + } + } +} \ No newline at end of file diff --git a/UnityTests.Unity5/Assets/_Tests/TempTests_Extras.cs.meta b/UnityTests.Unity5/Assets/_Tests/TempTests_Extras.cs.meta new file mode 100644 index 0000000..423ad5e --- /dev/null +++ b/UnityTests.Unity5/Assets/_Tests/TempTests_Extras.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 70b65d2ecae848f1b3baf04303b263f6 +timeCreated: 1509215984 \ No newline at end of file diff --git a/UnityTests.Unity5/Assets/_Tests/TempTests_Extras.unity b/UnityTests.Unity5/Assets/_Tests/TempTests_Extras.unity new file mode 100644 index 0000000..86cda6d Binary files /dev/null and b/UnityTests.Unity5/Assets/_Tests/TempTests_Extras.unity differ diff --git a/UnityTests.Unity5/Assets/_Tests/TempTests_Extras.unity.meta b/UnityTests.Unity5/Assets/_Tests/TempTests_Extras.unity.meta new file mode 100644 index 0000000..c814ef1 --- /dev/null +++ b/UnityTests.Unity5/Assets/_Tests/TempTests_Extras.unity.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bb5a9ea469a70c840ab02674a1b31c15 +timeCreated: 1509215967 +licenseType: Pro +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/_DOTween.Assembly/DOTween/Core/TweenManager.cs b/_DOTween.Assembly/DOTween/Core/TweenManager.cs index 0b94432..3430b24 100644 --- a/_DOTween.Assembly/DOTween/Core/TweenManager.cs +++ b/_DOTween.Assembly/DOTween/Core/TweenManager.cs @@ -779,52 +779,52 @@ namespace DG.Tweening.Core } // If playing is FALSE returns active paused tweens, otherwise active playing tweens - internal static List GetActiveTweens(bool playing) + internal static List GetActiveTweens(bool playing, List fillableList = null) { if (_requiresActiveReorganization) ReorganizeActiveTweens(); if (totActiveTweens <= 0) return null; int len = totActiveTweens; - List ts = new List(len); + if (fillableList == null) fillableList = new List(len); for (int i = 0; i < len; ++i) { Tween t = _activeTweens[i]; - if (t.isPlaying == playing) ts.Add(t); + if (t.isPlaying == playing) fillableList.Add(t); } - if (ts.Count > 0) return ts; + if (fillableList.Count > 0) return fillableList; return null; } // Returns all active tweens with the given id - internal static List GetTweensById(object id, bool playingOnly) + internal static List GetTweensById(object id, bool playingOnly, List fillableList = null) { if (_requiresActiveReorganization) ReorganizeActiveTweens(); if (totActiveTweens <= 0) return null; int len = totActiveTweens; - List ts = new List(len); + if (fillableList == null) fillableList = new List(len); for (int i = 0; i < len; ++i) { Tween t = _activeTweens[i]; if (t == null || !Equals(id, t.id)) continue; - if (!playingOnly || t.isPlaying) ts.Add(t); + if (!playingOnly || t.isPlaying) fillableList.Add(t); } - if (ts.Count > 0) return ts; + if (fillableList.Count > 0) return fillableList; return null; } // Returns all active tweens with the given target - internal static List GetTweensByTarget(object target, bool playingOnly) + internal static List GetTweensByTarget(object target, bool playingOnly, List fillableList = null) { if (_requiresActiveReorganization) ReorganizeActiveTweens(); if (totActiveTweens <= 0) return null; int len = totActiveTweens; - List ts = new List(len); + if (fillableList == null) fillableList = new List(len); for (int i = 0; i < len; ++i) { Tween t = _activeTweens[i]; if (t.target != target) continue; - if (!playingOnly || t.isPlaying) ts.Add(t); + if (!playingOnly || t.isPlaying) fillableList.Add(t); } - if (ts.Count > 0) return ts; + if (fillableList.Count > 0) return fillableList; return null; } diff --git a/_DOTween.Assembly/DOTween/DOTween.cs b/_DOTween.Assembly/DOTween/DOTween.cs index 1270887..6af92a3 100644 --- a/_DOTween.Assembly/DOTween/DOTween.cs +++ b/_DOTween.Assembly/DOTween/DOTween.cs @@ -32,7 +32,7 @@ namespace DG.Tweening public class DOTween { /// DOTween's version - public static readonly string Version = "1.1.660"; + public static readonly string Version = "1.1.665"; /////////////////////////////////////////////// // Options //////////////////////////////////// @@ -924,9 +924,10 @@ namespace DG.Tweening /// Returns NULL if there are no active playing tweens. /// Beware: each time you call this method a new list is generated, so use it for debug only /// - public static List PlayingTweens() + /// If NULL creates a new list, otherwise fills this one (and thus saves allocations) + public static List PlayingTweens(List fillableList = null) { - return TweenManager.GetActiveTweens(true); + return TweenManager.GetActiveTweens(true, fillableList); } /// @@ -934,22 +935,24 @@ namespace DG.Tweening /// Returns NULL if there are no active paused tweens. /// Beware: each time you call this method a new list is generated, so use it for debug only /// - public static List PausedTweens() + /// If NULL creates a new list, otherwise fills this one (and thus saves allocations) + public static List PausedTweens(List fillableList = null) { - return TweenManager.GetActiveTweens(false); + return TweenManager.GetActiveTweens(false, fillableList); } /// /// Returns a list of all active tweens with the given id. /// Returns NULL if there are no active tweens with the given id. /// Beware: each time you call this method a new list is generated - /// If TRUE returns only the tweens with the given ID that are currently playing /// - public static List TweensById(object id, bool playingOnly = false) + /// If TRUE returns only the tweens with the given ID that are currently playing + /// If NULL creates a new list, otherwise fills this one (and thus saves allocations) + public static List TweensById(object id, bool playingOnly = false, List fillableList = null) { if (id == null) return null; - return TweenManager.GetTweensById(id, playingOnly); + return TweenManager.GetTweensById(id, playingOnly, fillableList); } /// @@ -957,10 +960,11 @@ namespace DG.Tweening /// Returns NULL if there are no active tweens with the given target. /// Beware: each time you call this method a new list is generated /// If TRUE returns only the tweens with the given target that are currently playing + /// If NULL creates a new list, otherwise fills this one (and thus saves allocations) /// - public static List TweensByTarget(object target, bool playingOnly = false) + public static List TweensByTarget(object target, bool playingOnly = false, List fillableList = null) { - return TweenManager.GetTweensByTarget(target, playingOnly); + return TweenManager.GetTweensByTarget(target, playingOnly, fillableList); } #endregion diff --git a/_DOTween.Assembly/bin/DOTween.XML b/_DOTween.Assembly/bin/DOTween.XML index bdbfcd5..3b3232a 100644 --- a/_DOTween.Assembly/bin/DOTween.XML +++ b/_DOTween.Assembly/bin/DOTween.XML @@ -734,34 +734,38 @@ A tween is considered as playing even if its delay is actually playing - + Returns a list of all active tweens in a playing state. Returns NULL if there are no active playing tweens. Beware: each time you call this method a new list is generated, so use it for debug only + If NULL creates a new list, otherwise fills this one (and thus saves allocations) - + Returns a list of all active tweens in a paused state. Returns NULL if there are no active paused tweens. Beware: each time you call this method a new list is generated, so use it for debug only + If NULL creates a new list, otherwise fills this one (and thus saves allocations) - + Returns a list of all active tweens with the given id. Returns NULL if there are no active tweens with the given id. Beware: each time you call this method a new list is generated - If TRUE returns only the tweens with the given ID that are currently playing + If TRUE returns only the tweens with the given ID that are currently playing + If NULL creates a new list, otherwise fills this one (and thus saves allocations) - + Returns a list of all active tweens with the given target. Returns NULL if there are no active tweens with the given target. Beware: each time you call this method a new list is generated If TRUE returns only the tweens with the given target that are currently playing + If NULL creates a new list, otherwise fills this one (and thus saves allocations) diff --git a/_DOTween.Assembly/bin/DOTween.dll b/_DOTween.Assembly/bin/DOTween.dll index a0c03eb..2f0c0d2 100644 Binary files a/_DOTween.Assembly/bin/DOTween.dll and b/_DOTween.Assembly/bin/DOTween.dll differ diff --git a/_DOTween.Assembly/bin/DOTween.dll.mdb b/_DOTween.Assembly/bin/DOTween.dll.mdb index 1bd1f02..918d50e 100644 Binary files a/_DOTween.Assembly/bin/DOTween.dll.mdb and b/_DOTween.Assembly/bin/DOTween.dll.mdb differ diff --git a/_DOTween.Assembly/bin/DOTween43.dll b/_DOTween.Assembly/bin/DOTween43.dll index 0bc4660..4cd3312 100644 Binary files a/_DOTween.Assembly/bin/DOTween43.dll and b/_DOTween.Assembly/bin/DOTween43.dll differ diff --git a/_DOTween.Assembly/bin/DOTween43.dll.mdb b/_DOTween.Assembly/bin/DOTween43.dll.mdb index 7938c87..c174bb1 100644 Binary files a/_DOTween.Assembly/bin/DOTween43.dll.mdb and b/_DOTween.Assembly/bin/DOTween43.dll.mdb differ diff --git a/_DOTween.Assembly/bin/DOTween46.dll b/_DOTween.Assembly/bin/DOTween46.dll index 15534c3..2e36d82 100644 Binary files a/_DOTween.Assembly/bin/DOTween46.dll and b/_DOTween.Assembly/bin/DOTween46.dll differ diff --git a/_DOTween.Assembly/bin/DOTween46.dll.mdb b/_DOTween.Assembly/bin/DOTween46.dll.mdb index e907dcb..3bf6339 100644 Binary files a/_DOTween.Assembly/bin/DOTween46.dll.mdb and b/_DOTween.Assembly/bin/DOTween46.dll.mdb differ diff --git a/_DOTween.Assembly/bin/DOTween50.dll b/_DOTween.Assembly/bin/DOTween50.dll index 73a85a3..2e1fc1d 100644 Binary files a/_DOTween.Assembly/bin/DOTween50.dll and b/_DOTween.Assembly/bin/DOTween50.dll differ diff --git a/_DOTween.Assembly/bin/DOTween50.dll.mdb b/_DOTween.Assembly/bin/DOTween50.dll.mdb index c484e51..4b028a1 100644 Binary files a/_DOTween.Assembly/bin/DOTween50.dll.mdb and b/_DOTween.Assembly/bin/DOTween50.dll.mdb differ diff --git a/_DOTween.Assembly/bin/Editor/DOTweenEditor.dll b/_DOTween.Assembly/bin/Editor/DOTweenEditor.dll index 24675e9..7ed9e6f 100644 Binary files a/_DOTween.Assembly/bin/Editor/DOTweenEditor.dll and b/_DOTween.Assembly/bin/Editor/DOTweenEditor.dll differ diff --git a/_DOTween.Assembly/bin/Editor/DOTweenEditor.dll.mdb b/_DOTween.Assembly/bin/Editor/DOTweenEditor.dll.mdb index f12880e..4a3fc2f 100644 Binary files a/_DOTween.Assembly/bin/Editor/DOTweenEditor.dll.mdb and b/_DOTween.Assembly/bin/Editor/DOTweenEditor.dll.mdb differ