appmobi supported orientations

0 favourites
  • Why does phonegap get a setting for supported orientations, and appmobi does not? Can appmobi get this? appmobi runs better and has sound, would be nice if it also had the supported orientations options.

  • I was wondering this also. I've looked at editing the html file to lock the orientation and I've googled ways to set it to landscape but I've not managed to find anything.

    Also on a side note, the preview looks and plays perfect on AppMobi but the end result apk on my phone is zoomed in and the screen doesn't fit.

  • It's on our todo list!

  • Awesome Thanks!

  • Bert Just did a quick and dirty test and got our locking orientation code: AppMobi.device.setRotateOrientation("landscape"); working. Just search your index.html code and paste it in the top of the "appMobi.device.ready" event listener function.

    We also have orientation setup when you build the app through our build system.

    I recommend trying your game on device by using our "appLab" test container (can be found in both the App Store and Market), since our XDK emulation doesn't always display the C2 output correctly.

    You can find the appMobi API commands here: appmobi.com/documentation/jsAPI.html

    Just make sure the event "appMobi.device.ready" has fired before making any calls since the appMobi.js lib has to be loaded

  • Thanks Tyler! I will try this. Also please keep in mind I do not know how to program, so I will do my best. I've tried my game through both the emulator and the applab app, I've also exported and ran it on an Android. The screen turns with the phone(not what I want). I assume if I want "portrait"(I do) I just put that where landscape goes. Here is a link to my game on the chrome store. Check it out if you like there are cool screen shots and a video of it. Maze Manor

    As you can see it was designed for a mobile device. Also there is a $99 fee for pro support on appmobi IOS output, would that support help with device orientation if I had a problem with it? I was planning on buying it anyway once my app(I mean construct2) is ready. There is a small list of things I need to make my game an app.

    1. Device rotation locked

    2. Sound not to randomly stop working(this might be fixed with the RAM issue)

    3. Textures only to be loaded to RAM as needed(not the whole game on boot up)

    <img src="http://kroma.us/ad/images/mazemanor.jpg" border="0">

  • I can answer:

    1) Can be done see posts above

    2) Strange, as far as I know appmobi (and apple device) doeasn't have problems with html5, but then again currently construct2 is not optimized for appmobi (it's on the todo list of Ashley)

    3) C2 doesn't currently support resources streaming, if I'm not mistaken is on the todo list.

  • Yes they are all on the to do list, thankfully.

  • Bert Just did a quick and dirty test and got our locking orientation code: AppMobi.device.setRotateOrientation("landscape"); working. Just search your index.html code and paste it in the top of the "appMobi.device.ready" event listener function.

    We also have orientation setup when you build the app through our build system.

    I recommend trying your game on device by using our "appLab" test container (can be found in both the App Store and Market), since our XDK emulation doesn't always display the C2 output correctly.

    You can find the appMobi API commands here: appmobi.com/documentation/jsAPI.html

    Just make sure the event "appMobi.device.ready" has fired before making any calls since the appMobi.js lib has to be loaded

    Any help with this would be greatly appreciated. It's like Chinese to me. Maybe just an example html with the orientation locked?

  • Never mind I got it to work! woot!

  • Bert I think I'm having the same problem as you. Can you dumb it down for me please and explain exactly how u did it? Maybe just copy and paste the section of the html rather than just typing up the command. Would be a big help.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • FredQ edit exported for appmobi html, add this:

    AppMobi.device.setRotateOrientation('landscape');
    AppMobi.device.setAutoRotate(false);

    right after these lines:

    document.addEventListener("appMobi.device.ready", function ()
    {

    change landscape to portrait depending on what orientation you need.

  • Thank you, works great, that's all I needed!

    When exporting your project from C2 are you setting it as fullscreen (crop mode) or fullscreen (scale mode)? I'm having the problem where it looks great in the appMobi emulator but is stretched and won't fit the screen when actually played on my phone.

  • I use full screen scale mode.

    ranma I got mine to work without this line:

    AppMobi.device.setAutoRotate(false);

    What does that one do? is it needed?

  • <img src="http://kroma.us/ad/images/mazemanor.jpg" border="0" />

    How do you get an image to also be a hyperlink, seems like I have to pick one or the other?

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)