Quantcast
Viewing latest article 2
Browse Latest Browse All 9

Answer by robhuhn

I guess because all of them have the tag "resource". You should check if *this* is the clicked object or destroy the object which was hit. (code not tested) if (hit.gameObject.Equals(gameObject)) { Destroy(gameObject); } or if (hit.transform.tag == "resource") { Destroy ( hit.gameObject ); }

Viewing latest article 2
Browse Latest Browse All 9

Trending Articles



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