(BehaviorDesigner.Runtime.Tasks) Can I add the OnDestroy () method to the abstract class Task class?

eaglescv

New member
Hi, I want to receive an event when the object that owns the behavior tree is deleted immediately.

For example, OnAwake () adds an event when called.

I want to release the event when the object is deleted immediately.


question.jpg

Can I add the OnDestroy () interface in a similar method to the OnAwake () function?

Please let me know if there is another way.
 
OnDestroy doesn't exist, but OnBehaviorComplete does which will be called whenever the behavior tree is complete (including if it is destroyed).
 
Top