Quantcast
Channel: Unity Forum
Viewing all articles
Browse latest Browse all 1466670

Coin Pick Up Issue

$
0
0
I created a coin that has a particle effect and an add value to the score once you pick it up. I created a prefab of the coin and everytime I pick up the coin, all the other prefabs disappear but the score adds up for all the other coins. Any help?

CoinPickup.js
Code (JavaScript):
  1. #pragma strict
  2.  
  3. var coinEffect : Transform;
  4. var coinValue = 1;
  5.  
  6. function OnTriggerEnter (info : Collider)
  7. {
  8.     if (info.tag == "Player")
  9.     {
  10.         GameMaster.currentScore += coinValue;...
Coin Pick Up Issue

Viewing all articles
Browse latest Browse all 1466670

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>