Problems with "orientation" in config.xml

Get help using Construct 2

Post » Tue Sep 30, 2014 12:16 pm

Hi all!

I am currently developing an application for Android with HTML 5 and Phonegap. This App should be locked to the "Portrait" orientation. In this application I also want to include a selfmade "runner" Contruct 2 game (which should be locked into "Landscape" orientation).

Here is my problem:

If i set <preference name="orientation" value="portrait" /> in my config.xml (which is needed for phonegap) the Construct html-file is also locked to the "Portrait mode" and my game is shown in "portrait" mode...
If I set the orientation into "landscape" in the config.xml file my application is also set to "landscape" mode and my app looks horrible.
If the orientation is set to "default" my application also looks horrible if i activate the "switch" command at the device.
Another problem is that the config.xml orientation overwrites all my commands in the html 5 documents...

My Question:

How can I manage that my Android application is set to "Portait" while my Construct 2 game which is included in the app is set to "landscape" mode?

Thanks for your help,
kind regards Davsmond
B
4
Posts: 2
Reputation: 204

Post » Tue Sep 30, 2014 2:57 pm

Maybe you can use the System -> "Is on platform" and check if its on "Android" or not and then switch it based on that. I have never used it my self as I only created stuff for desktops, so if it can solve it I don't know its just a guess :D
B
44
S
11
G
2
Posts: 1,182
Reputation: 6,848

Post » Fri Oct 03, 2014 6:18 am

I fear this doesn't work for me...
B
4
Posts: 2
Reputation: 204

Post » Fri Oct 03, 2014 1:06 pm

Why would you want to lock a landscape game in portrait mode?
Scirra Founder
B
400
S
236
G
89
Posts: 24,546
Reputation: 195,471


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 26 guests