You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a singleton class that has an Integer. I am incrementing this integer by one when I start a tween and in OnComplete of that tween decreasing it by one. Each tween is created by separate objects.
Issue is if these I create these tweens so fast, in some of the OnCompletes ignores the singleton call but calls other thins with no problem.
transform.DOMove(slot.transform.position, moveTimeToSlots.Value).OnComplete(() => { GameStateManager.Instance.MethodSingleton(); // Sometimes not calling MethodOne(); // always calling MethodTwo(); // always calling });
Edit: When I call the MethodSingleton for example in MethodOne, it works flawlessly. So it's 100% OnComplete and Singleton problem.
The text was updated successfully, but these errors were encountered:
I have a singleton class that has an Integer. I am incrementing this integer by one when I start a tween and in OnComplete of that tween decreasing it by one. Each tween is created by separate objects.
Issue is if these I create these tweens so fast, in some of the OnCompletes ignores the singleton call but calls other thins with no problem.
transform.DOMove(slot.transform.position, moveTimeToSlots.Value).OnComplete(() => { GameStateManager.Instance.MethodSingleton(); // Sometimes not calling MethodOne(); // always calling MethodTwo(); // always calling });
Edit: When I call the MethodSingleton for example in MethodOne, it works flawlessly. So it's 100% OnComplete and Singleton problem.
The text was updated successfully, but these errors were encountered: