How to reset the state of affected object upon tween ending? #153
-
|
Hi, I've had this issue like 6 separate times already in my project. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 4 replies
-
|
Hi, OnComplete() seems like a perfect match for your use case. Doesn't it work for you? Something like this: const float startValue = 5;
Tween.PositionX(transform, startValue, 10, 1f).OnComplete(() => transform.position = new Vector3(startValue, 0)); |
Beta Was this translation helpful? Give feedback.
-
|
@octia I added an experimental To enable experimental features, please add the PRIME_TWEEN_EXPERIMENTAL define to the 'Project Settings / Player / Other Settings / Scripting Define Symbols'. |
Beta Was this translation helpful? Give feedback.
@octia I added an experimental
Tween/Sequence.ResetBeforeComplete()method in version 1.3.1. Please update and tell me this works for you.To enable experimental features, please add the PRIME_TWEEN_EXPERIMENTAL define to the 'Project Settings / Player / Other Settings / Scripting Define Symbols'.