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

what does that error mean ?

$
0
0
please would you tell me what does error mean ?

Cannot implicitly convert type `UnityEngine.Component' to `DonutButton'. An explicit conversion exists (are you missing a cast?)

Code (CSharp):
  1. public DonutButton other ;
  2.  
  3. void OnTriggerEnter2D(Collider2D collisionObject){
  4.  
  5. other = gameObject.GetComponent ("DonutButton"); //DonutButton is another Class
  6.         other.OnMouseDown ();
  7.  
  8. }

Viewing all articles
Browse latest Browse all 1466670

Trending Articles



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