0 Replies Latest reply on Jun 13, 2012 12:19 AM by GameDesignProfessor

    Orientation problem with iOS for landscape is there a fix?

    GameDesignProfessor Level 1

      Hello all,

      I would like to set my game to LANDSCAPE permanently

       

      I have an Action Script Project for iOS and I am having a problem with the Orientation: Here is my app file function for the aspect ratio:

       

      public function KnockemOff_Mobile_iOS()

              {

                  trace (flash.system.Capabilities.version);

                  trace (flash.system.Capabilities.os);

                  trace (flash.system.Capabilities.playerType);

                 

                 

                  // Initialize the game when stage is ready

                  if(stage)

                      init();

                  else

                      addEventListener(Event.ADDED_TO_STAGE, init);

                  //GameIFace.IGameController().stage.

                  var ver:String = flash.system.Capabilities.version.substr(0,3);

                  if (ver == "AND")

                  {

                      //[SWF(width="1024", height="600", backgroundColor="#000000", frameRate="60")]

                      GameIFace.IGameController().stage.setAspectRatio(StageAspectRatio.LANDSCAPE);

                      //GameIFace.IGameController().stage.setOrientation(StageOrientation.DEFAULT);

                     

                  }

              }

       

      Here is the app.xml file code for orientation:

       

      <autoOrients>false</autoOrients>
          <fullScreen>true</fullScreen>
          <visible>true</visible>

       

      It would not except the <aspectRatio>LANDSCAPE</aspectRatio> tag

       

      Thanks