Hey guys! I am attempting to set up a base AIR Mobile AS3 application in FD using FP as well.
I am just testing the waters, and I was going to make a simple side-scroller test game. For this I need the screen orientation to be forced to the left. Here is what I have so far:
package {
import flash.desktop.NativeApplication;
import flash.events.Event;
import flash.display.Sprite;
import flash.display.StageAlign;
import flash.display.StageScaleMode;
import flash.ui.Multitouch;
import flash.ui.MultitouchInputMode;
import net.flashpunk.Engine;
import net.flashpunk.FP;
import flash.display.StageOrientation;
[SWF(width="800", height="480", frameRate="30")]
public class Main extends Engine
{
public function Main()
{
super(800, 480, 30, false);
StageOrientation.ROTATED_LEFT;
stage.scaleMode = StageScaleMode.EXACT_FIT;
}
private function deactivate(e:Event):void
{
NativeApplication.nativeApplication.exit();
}
}
}
I have made applications for my phone before which were all portrait and used the reverse width and height, 480x800 which is my screen size. However I would like to force landscape now.
Any input would be greatly appreciated! Thanks guys