How to add Coins or Collectables in Unity in 60 seconds

Опубликовано: 20 Июнь 2026
на канале: The Game Mekanik
2,081
59

How to make a Coin or Collectable in Unity

So, you want collectables in your Unity Project. No problem. Go ahead and make an empty game object, and then add the visuals for whatever collectible you are making. Move it up to about eye level, and let's add some components.

Add a sphere collider, an Animation, and a script.

For the collider, set it to just a bit bigger than the mesh, and to a trigger.

Let's make an animation. Add one to the project, name it, and drag it onto the animation slot.

Make an animation, and set it to loop by clicking the animation in the project and setting the wrap mode to loop.

Now, in the script, we are going to store the collider into a property, and then fire an event when the collider gets touched.

What you do in here is up to you, for now, we are going to delete the coin.

And, we're done! Any collectable will use this pattern, so tweak it to best fit your needs.