title: Comparing enum values in C#/Unity?
body: <p>I was wondering if it is possible to compare the (int) of two seperate Enums (from different scripts)? </p>
  
  <p>I am currently trying:</p>
  
  <pre><code> if((int)newMiner.minerType == (int)resourceType)
          {
              Debug.Log("Resource Holder Accepts Miner");
          }
  </code></pre>
  
  <p>newMiner is the other script that has the enum I'm trying to compare and minerType is one Enum while resourceType is the local Enum I am trying to compare it with. </p>
  
  <p>What I have now does not return an error, however, it always returns true. Any information on how this does/doesn't work would be very much appreciated :) </p>