Tricky iOS Universal App Ad Question
pHghost
London, UKMember Posts: 2,342
Unfortunately, I don't have an iPad to test this, hopefully someone might and will be able to weigh in on the issue.
I am building an app which will be iOS Universal (as all should be, nowadays), but the tricky bit is that on iPhone it works in portrait mode, but on iPad in landscape mode. Now, I have that part of the issue sorted, I'm using rotate camera to align everything on screen, the issue I'm facing is what will happen with ads. Will they appear sideways along the shorter dimension of the iPad screen (where they normally should appear, had the iPad been oriented as portrait as well)?
Comments
That's a good question! I'm not sure - I've never tested it out, but my gut says that the ads automatically detect the orientation of the device and orient themselves appropriately.
My GameSalad Academy Courses! ◦ Check out my quality templates! ◦ Add me on Skype: braydon_sfx
Unfortunately I broke my iPad awhile back so I can't test either, But in my game that was landscape, I had a portrait game and ads appeared on the side. But that may have only been because I built portrait game sideways I did not rotate camera.
I agree with @Braydon_SFX. My guess is that the ad will detect the orientation but I am not 100% sure as I have not tested it either ... If you make a cutdown project I am happy to package it or run it in the viewer and do a quick test for you on an iPad ...
Free Mini Games and Demo Templates
Perhaps not going to help so much with ads but don't forget you can install the GS Viewer to Simulator.
(Simulator being the Xcode iOS/tvOS/watchOS Simulator )
I agree that when the device determines the oreintation...the ad will end up viewed top or bottom...I would not EXPECT it to display sideways.
Complete Guide to iOS Publishing {} Complete Guide to Mac Publishing
Personally Im very interested to know WHY your app views are portrait on iphones and landscape on an ipad....this does not sound right.
Complete Guide to iOS Publishing {} Complete Guide to Mac Publishing
Its actually very right, apple even encourages using the iPad as a platform with bigger real estate to show features,maps,buttons in apps that would normally have to be hidden in phones due to screen size.
Fortuna Infortuna Forti Una
Maybe Im not visualizing this very well. I probably should be asking HOW does a portrait oreintated game....I assume with portrait clicked...become landscape oreintated...not so mich wether yoi should or not...but how is that happening ? Can yoi choose orentiations based on device screen size? Do you end up building two seperate games inside one project?
Complete Guide to iOS Publishing {} Complete Guide to Mac Publishing
Thanks, I'll try to make a sample project for testing.
Well, that's the issue. I'm not sure whether the device will understand it's landscape, or if it will think it is in portrait, since that is the general setting of the project.
That's exactly why it's in landscape orientation on iPad.
Hah! Well, it's not a game -- that might be part of the answer. I cannot put up screenshots just yet, unfortunately. But if you find and send me that UDID, you'll probably understand exactly what I'm talking about.
Basically you need to code everything to readjust when it sees an iPad. This is how it works in Xcode it's just that in Xcode Apple has tools to help with auto adjust. I would build out two separate versions one for iPad and one for iPhone. If you rely on movement and X and Y positions going from portrait to landscape will be tricky.
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS
I'm not entirely sure where Apple takes their info for the app (ad) orientation.
Is it simply based on your publishing settings (checked supported orientations), or based on the orientation you set in-scene?
I think that's the main question, and what I'd test if I had an iPad.
I believe it ultimately comes at publishing. But both need to be in sync. So look at it this way. Selecting one way in a scene will tell it how to orient but if that option isn't selected in publishing it won't get recognized. So basically the publishing system is the total of the ones you are using and the scene determines it on display. I hope that made sense..lol
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS
Yes, it makes absolute sense. I'd generally think the same, that the publishing settings override the in-scene settings, which would mean you cannot have unique orientation settings per-scene.
The one problem there is that if you check two orientations on publishing, then BOTH will be active on each device (if I understand correctly), and so on the iPhone, if you turned the device sideways, it will stretch, crop, or letterbox the scene.
Or am I wrong?
No you can have unique ones but you need to select both in publishing system. Get it?
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS
Ah! If that is true, it'd be perfect.
I remember having problems with that some time back (which is why I started this thread), but it was quite some time ago, when GS was a lot more buggy, had less features and my GS skills were also quite limited, for sure, so I'll have to look at that again.
Thanks!
Just tested it in Ad-Hoc, and unfortunately it doesn't work. If you select all orientations in the publishing system, it overwrites the scene attributes.
Anything I might be missing, @GeorgeGS ?
bump