Skip to content

Commit ec2c60d

Browse files
committed
Set default scene index to active scene
1 parent 0bd1001 commit ec2c60d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Runtime/Tween.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
using UnityEngine.SceneManagement;
2+
13
namespace Zigurous.Tweening
24
{
35
/// <summary>
@@ -443,7 +445,7 @@ public void Restart()
443445
internal void Reset()
444446
{
445447
this.id = -1;
446-
this.sceneIndex = -1;
448+
this.sceneIndex = SceneManager.GetActiveScene().buildIndex;
447449

448450
this.state = TweenState.Ready;
449451
this.internalState = InternalTweenState.Queued;

0 commit comments

Comments
 (0)