title: How to check the Auto Rotation orientation in Unity for Android Device?
body: <p>I am creating a simple plugin for android. I want to set the orientation Using C# on Unity side only.</p>
  
  <p>I am checking the orientation of the screen using this code.</p>
  
  <pre><code>if (Screen.orientation == ScreenOrientation.Portrait) {
  // portrait
  }
  else
  {
  // landscape
  }
  </code></pre>
  
  <p><strong>But there is something missing in my code which I am looking for.</strong> As there is <strong>Auto Rotation</strong> mode also. And I am not able to check that scenario. Can anybody help me to check the <strong><em><code>AutoRotation</code></em></strong> mode via Unity for Android Device.</p>
  
  <p>Thanks,</p>