diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween.dll b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween.dll
index a9ea535..93940f8 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 80a8b46..9bbb16c 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/Editor/DOTweenEditor.dll b/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll
index 66bc468..ae0f232 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 14b197d..0ba7f6b 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/Demigiant/DOTween/Editor/DOTweenUpgradeManager.dll b/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenUpgradeManager.dll
index ae11da1..ddfe0cd 100644
Binary files a/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenUpgradeManager.dll and b/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenUpgradeManager.dll differ
diff --git a/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenUpgradeManager.dll.mdb b/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenUpgradeManager.dll.mdb
index 9ddf29a..74661e8 100644
Binary files a/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenUpgradeManager.dll.mdb and b/UnityTests.Unity5/Assets/Demigiant/DOTween/Editor/DOTweenUpgradeManager.dll.mdb differ
diff --git a/UnityTests.Unity5/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare.png.meta b/UnityTests.Unity5/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare.png.meta
index 10781ad..72c9688 100644
--- a/UnityTests.Unity5/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare.png.meta
+++ b/UnityTests.Unity5/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare.png.meta
@@ -1,6 +1,6 @@
fileFormatVersion: 2
guid: d3e15b806a8368742ba6f10e794d7b76
-timeCreated: 1571751690
+timeCreated: 1575368396
licenseType: Pro
TextureImporter:
fileIDToRecycleName: {}
diff --git a/UnityTests.Unity5/Assets/_Tests/TempTests.cs b/UnityTests.Unity5/Assets/_Tests/TempTests.cs
index ba6e5f1..965b961 100644
--- a/UnityTests.Unity5/Assets/_Tests/TempTests.cs
+++ b/UnityTests.Unity5/Assets/_Tests/TempTests.cs
@@ -11,17 +11,83 @@ using UnityEngine.UI;
public class TempTests : BrainBase
{
- Tween _tScale, _tMove;
-
- void Start()
+ private Sequence parent;
+ private float duration;
+
+ // Empty Scene with 3 cubes next to each other named Cube1, Cube2, Cube3.
+ // Empty game object with script on it. 2 check boxes in inspector to fire the methods.
+ // Child sequence is a one off. Parent sequence has a restart on complete.
+ // If you fire parent first, and the boxes do not adhere to the time they just fly away.
+ // If you fire child first, then fire parent, and the parent sequence uses times.
+
+ void Update()
{
- _tScale = transform.DOScale(0.5f, 1).SetLoops(999);
- _tMove = transform.DOMoveX(2, 1).SetLoops(999);
+ if (Input.GetKeyUp(KeyCode.F5)) {
+ DOTween.KillAll();
+ SceneManager.LoadScene(SceneManager.GetActiveScene().name);
+ }
+
+ if (Input.GetKeyUp(KeyCode.DownArrow))
+ {
+ Debug.Log("Create child");
+ createChild();
+ }
+
+ if (Input.GetKeyUp(KeyCode.UpArrow))
+ {
+ Debug.Log("Create parent");
+ createParent();
+ }
}
-
- void OnDisable()
+
+ public void createParent()
{
- _tScale.Complete();
- _tMove.Complete();
+ parent = DOTween.Sequence()
+ .SetAutoKill(false)
+ .AppendCallback(() => createChild());
+ Debug.Log("- " + duration);
+ parent.AppendInterval(duration)
+ .OnComplete(() => {
+ Debug.Log("RESTART");
+ parent.Restart();
+ });
+ }
+
+ public void createChild()
+ {
+ var listy = new List
+ {
+ GameObject.Find("Cube1"),
+ GameObject.Find("Cube2"),
+ GameObject.Find("Cube3")
+ };
+
+ var child = DOTween.Sequence();
+ setCallBack(listy, child);
+ duration = child.Duration();
+ Debug.Log(">>> duration: " + duration);
+ }
+
+ private void setCallBack(List listy, Sequence child)
+ {
+ foreach (var thing in listy)
+ {
+ var rand = (float)rando();
+ Debug.Log("Wait " + thing.name + " " + rand.ToString());
+ child.AppendCallback(() => planToMove(thing.transform)).AppendInterval(rand); // move each, append a wait interval
+ }
+ }
+
+ public int rando()
+ {
+ var rnd = new System.Random();
+ return rnd.Next(1, 5);
+ }
+
+ public void planToMove(Transform thing)
+ {
+ var rand = rando();
+ thing.DOMove(new Vector3(thing.position.x, thing.position.y, thing.position.z + rand), .5f); //move the z a random amount beween 1-3.
+ Debug.Log("Move " + thing.name + " " + rand.ToString());
}
}
\ No newline at end of file
diff --git a/UnityTests.Unity5/Assets/_Tests/TempTests.unity b/UnityTests.Unity5/Assets/_Tests/TempTests.unity
index a2c75b0..1040b79 100644
Binary files a/UnityTests.Unity5/Assets/_Tests/TempTests.unity and b/UnityTests.Unity5/Assets/_Tests/TempTests.unity differ
diff --git a/_DOTween.Assembly/DOTween/DOTween.csproj b/_DOTween.Assembly/DOTween/DOTween.csproj
index 910cdd7..eb85cd0 100644
--- a/_DOTween.Assembly/DOTween/DOTween.csproj
+++ b/_DOTween.Assembly/DOTween/DOTween.csproj
@@ -64,7 +64,7 @@
- C:\Program Files (x86)\Unity 46\Editor\Data\Managed\UnityEngine.dll
+ C:\Program Files (x86)\Unity\4.6\Editor\Data\Managed\UnityEngine.dll
False
diff --git a/_DOTween.Assembly/DOTweenEditor/DOTweenEditor.csproj b/_DOTween.Assembly/DOTweenEditor/DOTweenEditor.csproj
index 5c15c9f..5b2904a 100644
--- a/_DOTween.Assembly/DOTweenEditor/DOTweenEditor.csproj
+++ b/_DOTween.Assembly/DOTweenEditor/DOTweenEditor.csproj
@@ -64,11 +64,11 @@
- C:\Program Files (x86)\Unity 46\Editor\Data\Managed\UnityEditor.dll
+ C:\Program Files (x86)\Unity\4.6\Editor\Data\Managed\UnityEditor.dll
False
- C:\Program Files (x86)\Unity 46\Editor\Data\Managed\UnityEngine.dll
+ C:\Program Files (x86)\Unity\4.6\Editor\Data\Managed\UnityEngine.dll
False
diff --git a/_DOTween.Assembly/DOTweenUpgradeManager/DOTweenUpgradeManager.csproj b/_DOTween.Assembly/DOTweenUpgradeManager/DOTweenUpgradeManager.csproj
index ab6466e..f880870 100644
--- a/_DOTween.Assembly/DOTweenUpgradeManager/DOTweenUpgradeManager.csproj
+++ b/_DOTween.Assembly/DOTweenUpgradeManager/DOTweenUpgradeManager.csproj
@@ -41,11 +41,11 @@
- C:\Program Files (x86)\Unity 46\Editor\Data\Managed\UnityEditor.dll
+ C:\Program Files (x86)\Unity\4.6\Editor\Data\Managed\UnityEditor.dll
False
- C:\Program Files (x86)\Unity 46\Editor\Data\Managed\UnityEngine.dll
+ C:\Program Files (x86)\Unity\4.6\Editor\Data\Managed\UnityEngine.dll
False
diff --git a/_DOTween.Assembly/DOTween_LooseScripts/DOTween_LooseScripts.csproj b/_DOTween.Assembly/DOTween_LooseScripts/DOTween_LooseScripts.csproj
index 1258272..ac9aca7 100644
--- a/_DOTween.Assembly/DOTween_LooseScripts/DOTween_LooseScripts.csproj
+++ b/_DOTween.Assembly/DOTween_LooseScripts/DOTween_LooseScripts.csproj
@@ -48,15 +48,15 @@
- C:\Program Files\Unity\Editor\Data\Managed\UnityEditor.dll
+ C:\Program Files (x86)\Unity\4.6\Editor\Data\Managed\UnityEditor.dll
False
- C:\Program Files\Unity\Editor\Data\Managed\UnityEngine.dll
+ C:\Program Files (x86)\Unity\4.6\Editor\Data\Managed\UnityEngine.dll
False
- C:\Program Files\Unity\Editor\Data\UnityExtensions\Unity\GUISystem\UnityEngine.UI.dll
+ C:\Program Files (x86)\Unity\4.6\Editor\Data\UnityExtensions\Unity\GUISystem\4.6.0\UnityEngine.UI.dll
False
diff --git a/_DOTween.Assembly/bin/DOTween.dll b/_DOTween.Assembly/bin/DOTween.dll
index a9ea535..93940f8 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 80a8b46..9bbb16c 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/Editor/DOTweenEditor.dll b/_DOTween.Assembly/bin/Editor/DOTweenEditor.dll
index 66bc468..ae0f232 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 14b197d..0ba7f6b 100644
Binary files a/_DOTween.Assembly/bin/Editor/DOTweenEditor.dll.mdb and b/_DOTween.Assembly/bin/Editor/DOTweenEditor.dll.mdb differ
diff --git a/_DOTween.Assembly/bin/Editor/DOTweenUpgradeManager.dll b/_DOTween.Assembly/bin/Editor/DOTweenUpgradeManager.dll
index ae11da1..ddfe0cd 100644
Binary files a/_DOTween.Assembly/bin/Editor/DOTweenUpgradeManager.dll and b/_DOTween.Assembly/bin/Editor/DOTweenUpgradeManager.dll differ
diff --git a/_DOTween.Assembly/bin/Editor/DOTweenUpgradeManager.dll.mdb b/_DOTween.Assembly/bin/Editor/DOTweenUpgradeManager.dll.mdb
index 9ddf29a..74661e8 100644
Binary files a/_DOTween.Assembly/bin/Editor/DOTweenUpgradeManager.dll.mdb and b/_DOTween.Assembly/bin/Editor/DOTweenUpgradeManager.dll.mdb differ