The Destroy Event

The destroy event is one of the many events that can be triggered in an instance and may contain code or actions.

The Destroy event
This event is the very last event to be executed when an instance is destroyed. It is often overlooked when adding behaviours to objects, but it can be very useful, for example by creating explosion or particle effects when an enemy is killed, or for re-spawning a new instance of the object in another part of the room, or even for adding points onto a score.

NOTE: This event is called the moment the action or code to destroy the instance is run.


Back: Events
Next: The Alarm Events
© Copyright YoYo Games Ltd. 2018 All Rights Reserved