how can i make an explosion

what am trying to make is that when my bullet object hits another object it makes an explosion.

Intertwine these to make what you want:


Instantiate function

Destroy function

This is properly all what you need to make what you you just described.

As Tom 17 said tutorials are always a great start. TornadoTwins helped me out when I started he will learn you the basics of Unity and scripting.


Well, if you know how to do the collision detection then you have the world position of the collision. All you would need to do is to spawn a prefab in that position. You can even use the normal of the collision to orient the explosion. The way to go would propably be to make a nice particle system to represent your explosion. Use google to find tutorials, there are a lot of them.

Btw if you don’t know how to script the collision detection, then you would have to learn that first. There are tutorials for that, too.