Using the Explosion Framework

I have a game object that gets destroyed when a collision is detected. I have now attached the detonator script to create an explosion. The documentation states that with the detonator attached, I can call the explode method in order to create my explosion. However, I’m confused as to how I call the Explode() method as it is abstract in the detonator script. How can I call this method to trigger my explosion?

Just call it. The Detonator.cs script has an abstract base class (DetonatorComponent, top of the file) and the normal Detonator class in it. And in Detonator, Explode is just regularly implemented. Btw, even if you only had access to the abstract base class, you could still call Explode for the component. It is not possible to have an instance of an abstract class, and subclasses need to implement abstract base functions (unless they are abstract themselves). So if you can call it there must be an implementation :slight_smile: