diff --git a/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween.dll b/UnityCompatibilityTests.Unity35/Assets/Demigiant/DOTween/DOTween.dll
index f1b6731..e3cc9db 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 d0e63d1..2e70876 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/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween.dll b/UnityTests.Unity4/Assets/Demigiant/DOTween/DOTween.dll
index f1b6731..e3cc9db 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 d0e63d1..2e70876 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.Unity5/Assets/Demigiant/DOTween/DOTween.dll b/UnityTests.Unity5/Assets/Demigiant/DOTween/DOTween.dll
index f1b6731..e3cc9db 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 d0e63d1..2e70876 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/_Tests/BlendableTweens.cs b/UnityTests.Unity5/Assets/_Tests/BlendableTweens.cs
new file mode 100644
index 0000000..6eb6a0c
--- /dev/null
+++ b/UnityTests.Unity5/Assets/_Tests/BlendableTweens.cs
@@ -0,0 +1,39 @@
+using UnityEngine;
+using System.Collections;
+using DG.Tweening;
+
+public class BlendableTweens : BrainBase
+{
+ public Transform[] targets;
+
+ Vector3[] startPositions;
+
+ IEnumerator Start()
+ {
+ startPositions = new Vector3[targets.Length];
+ startPositions[0] = targets[0].position;
+ startPositions[1] = targets[1].position + new Vector3(3, 3, 0);
+
+ yield return new WaitForSeconds(0.6f);
+
+ targets[0].DOBlendableMoveBy(new Vector3(3, 3, 0), 3).SetAutoKill(false).Pause();
+ targets[0].DOBlendableMoveBy(new Vector3(-3, 0, 0), 1f).SetLoops(3, LoopType.Yoyo).SetAutoKill(false).Pause();
+ // Same as above but using From
+ targets[1].DOBlendableMoveBy(new Vector3(3, 3, 0), 3).From().SetAutoKill(false).Pause();
+ targets[1].DOBlendableMoveBy(new Vector3(-3, 0, 0), 1f).SetLoops(3, LoopType.Yoyo).SetAutoKill(false).Pause();
+ }
+
+ void OnGUI()
+ {
+ if (GUILayout.Button("Toggle Pause")) DOTween.TogglePauseAll();
+ if (GUILayout.Button("Restart")) DOTween.RestartAll();
+ if (GUILayout.Button("Flip")) DOTween.FlipAll();
+ }
+
+ void OnDrawGizmos()
+ {
+ if (!Application.isPlaying) return;
+
+ foreach (Vector3 pos in startPositions) Gizmos.DrawSphere(pos, 0.2f);
+ }
+}
\ No newline at end of file
diff --git a/UnityTests.Unity5/Assets/_Tests/MixedTweens.cs.meta b/UnityTests.Unity5/Assets/_Tests/BlendableTweens.cs.meta
similarity index 100%
rename from UnityTests.Unity5/Assets/_Tests/MixedTweens.cs.meta
rename to UnityTests.Unity5/Assets/_Tests/BlendableTweens.cs.meta
diff --git a/UnityTests.Unity5/Assets/_Tests/MixedTweens.unity b/UnityTests.Unity5/Assets/_Tests/BlendableTweens.unity
similarity index 67%
rename from UnityTests.Unity5/Assets/_Tests/MixedTweens.unity
rename to UnityTests.Unity5/Assets/_Tests/BlendableTweens.unity
index be728ce..2846201 100644
Binary files a/UnityTests.Unity5/Assets/_Tests/MixedTweens.unity and b/UnityTests.Unity5/Assets/_Tests/BlendableTweens.unity differ
diff --git a/UnityTests.Unity5/Assets/_Tests/MixedTweens.unity.meta b/UnityTests.Unity5/Assets/_Tests/BlendableTweens.unity.meta
similarity index 100%
rename from UnityTests.Unity5/Assets/_Tests/MixedTweens.unity.meta
rename to UnityTests.Unity5/Assets/_Tests/BlendableTweens.unity.meta
diff --git a/UnityTests.Unity5/Assets/_Tests/Bugs/SequenceKillAndComplete.cs b/UnityTests.Unity5/Assets/_Tests/Bugs/SequenceKillAndComplete.cs
index dc25694..ae70113 100644
--- a/UnityTests.Unity5/Assets/_Tests/Bugs/SequenceKillAndComplete.cs
+++ b/UnityTests.Unity5/Assets/_Tests/Bugs/SequenceKillAndComplete.cs
@@ -10,12 +10,13 @@ public class SequenceKillAndComplete : BrainBase
IEnumerator Start()
{
- sequence = DOTween.Sequence();
- sequence.Append(target.DOMoveX(3, 3).SetRelative());
- sequence.Join(target.DOMoveY(3, 3).SetRelative());
+ sequence = DOTween.Sequence().OnComplete(()=> Debug.Log("SEQUENCE COMPLETE"));
+ sequence.Append(target.DOMoveX(3, 3).SetRelative().OnComplete(()=> Debug.Log("Tween A Complete")));
+ sequence.Join(target.DOMoveY(3, 3).SetRelative().OnComplete(()=> Debug.Log("Tween B Complete")));
- yield return new WaitForSeconds(1.5f);
+ yield return new WaitForSeconds(1f);
+ Debug.Log("COMPLETE");
sequence.Kill(true);
}
}
\ No newline at end of file
diff --git a/UnityTests.Unity5/Assets/_Tests/MixedTweens.cs b/UnityTests.Unity5/Assets/_Tests/MixedTweens.cs
deleted file mode 100644
index 9705a9f..0000000
--- a/UnityTests.Unity5/Assets/_Tests/MixedTweens.cs
+++ /dev/null
@@ -1,23 +0,0 @@
-using UnityEngine;
-using System.Collections;
-using DG.Tweening;
-
-public class MixedTweens : BrainBase
-{
- public Transform target;
-
- IEnumerator Start()
- {
- yield return new WaitForSeconds(0.6f);
-
- target.DOBlendableMoveBy(new Vector3(3, 3, 0), 3).SetAutoKill(false);
- target.DOBlendableMoveBy(new Vector3(-3, 0, 0), 1f).SetLoops(3, LoopType.Yoyo).SetAutoKill(false);
- }
-
- void OnGUI()
- {
- if (GUILayout.Button("Toggle Pause")) DOTween.TogglePauseAll();
- if (GUILayout.Button("Restart")) DOTween.RestartAll();
- if (GUILayout.Button("Flip")) DOTween.FlipAll();
- }
-}
\ No newline at end of file
diff --git a/UnityTests.Unity5/Assets/_Tests/TempTests.unity b/UnityTests.Unity5/Assets/_Tests/TempTests.unity
index 723dbd4..a451720 100644
Binary files a/UnityTests.Unity5/Assets/_Tests/TempTests.unity and b/UnityTests.Unity5/Assets/_Tests/TempTests.unity differ
diff --git a/UnityTests.Unity5/Assets/_Tests/_Shared Prefabs/- Environment.prefab b/UnityTests.Unity5/Assets/_Tests/_Shared Prefabs/- Environment.prefab
index 224558e..567c8e9 100644
Binary files a/UnityTests.Unity5/Assets/_Tests/_Shared Prefabs/- Environment.prefab and b/UnityTests.Unity5/Assets/_Tests/_Shared Prefabs/- Environment.prefab differ
diff --git a/_DOTween.Assembly/DOTween/DOTween.cs b/_DOTween.Assembly/DOTween/DOTween.cs
index b17ae36..46d73c3 100644
--- a/_DOTween.Assembly/DOTween/DOTween.cs
+++ b/_DOTween.Assembly/DOTween/DOTween.cs
@@ -21,7 +21,7 @@ namespace DG.Tweening
public class DOTween
{
/// DOTween's version
- public static readonly string Version = "1.0.346";
+ public static readonly string Version = "1.0.350";
///////////////////////////////////////////////
// Options ////////////////////////////////////
diff --git a/_DOTween.Assembly/DOTween/Sequence.cs b/_DOTween.Assembly/DOTween/Sequence.cs
index ee8b0d6..431a19a 100644
--- a/_DOTween.Assembly/DOTween/Sequence.cs
+++ b/_DOTween.Assembly/DOTween/Sequence.cs
@@ -205,6 +205,8 @@ namespace DG.Tweening
cyclesDone++;
if (s.loopType == LoopType.Yoyo) prevPosIsInverse = !prevPosIsInverse;
}
+ // If completedLoops or position were changed by some callback, exit here
+ if (expectedCompletedLoops != s.completedLoops || Math.Abs(expectedPosition - s.position) > Single.Epsilon) return !s.active;
} else {
// Simply determine correct prevPosition after steps
if (s.loopType == LoopType.Yoyo && newCompletedSteps % 2 != 0) {
@@ -213,8 +215,6 @@ namespace DG.Tweening
}
newCompletedSteps = 0;
}
- // If completedLoops or position were changed by some callback, exit here
- if (expectedCompletedLoops != s.completedLoops || Math.Abs(expectedPosition - s.position) > Single.Epsilon) return !s.active;
}
// Run current cycle
if (newCompletedSteps == 1 && s.isComplete) return false; // Skip update if complete because multicycle took care of it
diff --git a/_DOTween.Assembly/bin/DOTween.dll b/_DOTween.Assembly/bin/DOTween.dll
index f1b6731..e3cc9db 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 d0e63d1..2e70876 100644
Binary files a/_DOTween.Assembly/bin/DOTween.dll.mdb and b/_DOTween.Assembly/bin/DOTween.dll.mdb differ