Function onDestroy(tag: Tag, action: (obj: GameObj) => void): KEventController Register an event that runs when a game obj with certain tag is destroyed.param tag- The tag to listen for.param action- The function to run when the event is triggered.returns The event controller.since v2000.0group Events
Function onDestroy(action: (obj: GameObj) => void): KEventController Register an event that runs when a game obj is destroyed.param action- The function to run when the event is triggered.returns The event controller.group Events