Some delegates - don't work in Bolt 2

Aleksandr Ladenko 2 years ago updated by Lazlo Bonin (Lead Developer) 2 years ago 4

DOTween callbacks - don't work in Bolt 2.

When starting FlowMachine - I get an error:

NullReferenceException: Object reference not set.

But when I try to run the same script using MonoBehaviour, then everything is fine.

Bolt 2 - Error (OnComplete):

MonoBehaviour - OK:

dOTweenAnimation - it's variable for dotween Animation in unity inspector.

Full Stack trace:

NullReferenceException: Object reference not set to an instance of an object
Ludiq.Bolt.DelegateUnit.Delegate (Ludiq.Bolt.Flow fetchFlow, System.Object[] args) (at Assets/Ludiq/Bolt.Flow/Runtime/Framework/Flow/DelegateUnit.cs:94)
Ludiq.Bolt.DelegateUnit+<>c__DisplayClass30_0.b__1 (System.Object[] args) (at Assets/Ludiq/Bolt.Flow/Runtime/Framework/Flow/DelegateUnit.cs:67)
(wrapper dynamic-method) System.Object.lambda_method(System.Runtime.CompilerServices.Closure)
DG.Tweening.Tween.OnTweenCallback (DG.Tweening.TweenCallback callback) (at D:/DG/_Develop/__UNITY3_CLASSES/_Holoville/__DOTween/_DOTween.Assembly/DOTween/Tween.cs:290)
DG.Tweening.Tween.DoGoto (DG.Tweening.Tween t, System.Single toPosition, System.Int32 toCompletedLoops, DG.Tweening.Core.Enums.UpdateMode updateMode) (at D:/DG/_Develop/__UNITY3_CLASSES/_Holoville/__DOTween/_DOTween.Assembly/DOTween/Tween.cs:265)
DG.Tweening.Core.TweenManager.Update (DG.Tweening.UpdateType updateType, System.Single deltaTime, System.Single independentTime) (at D:/DG/_Develop/__UNITY3_CLASSES/_Holoville/__DOTween/_DOTween.Assembly/DOTween/Core/TweenManager.cs:490)
DG.Tweening.Core.DOTweenComponent.Update () (at D:/DG/_Develop/__UNITY3_CLASSES/_Holoville/__DOTween/_DOTween.Assembly/DOTween/Core/DOTweenComponent.cs:73)
Bolt Version:
Unity Version:
Scripting Backend:
.NET Version (API Compatibility Level):
Bolt 2
Satisfaction mark by Aleksandr Ladenko 2 years ago
Pending Review

Hi Aleksandr,

Thanks for the thorough report, I'll have a look!

Can confirm a very similar problem happened to me.

Fixed (Unreleased)

Hi Aleksandr,

Thank you for the report and sorry for the very late reply on this.

This issue will be fixed in the next version.