Quick Links: Download Gideros Studio | Gideros Documentation | Gideros community chat | DONATE
App deploy with Admob — Gideros Forum

App deploy with Admob

Hello,

I was trying deploying my app game on Android and iOS. With the Ads and Gaming Gideros plugins the exports works fine on both systems.

After upgrading my MacOS Catalina to the last revision 10.15.7 and reinstall the last Gideros Studio version 2020.12, the iOS export gave me the following errors building on Xcode (vs. 11.4.1):

- At first load of project on Xcode, I got a popup with "The folder images.xcassets doesn't exist."
- On the file Plugins > Gaming > Ads > AdsAdmob.h the line @import GoogleMobileAds has a label with the error: Module 'GoogleMobileAds' not found



I usually export the iOS project without any addition on Xcode, all files seems to be right on the project.

Comments

  • At now, I can put it work. I have to got back to Gideros 2011.11 version.

    Likes: MoKaLux

    +1 -1 (+1 / -0 )Share on Facebook
  • hgy29hgy29 Maintainer
    I was kind of expecting this kind of issues, given the amount of code changes that happened. But I am surprised admob plugin ended under gaming folder (which is totally unrelated). I will do some tests, maybe admob needs an update to work with ARC

    Likes: MoKaLux

    +1 -1 (+1 / -0 )Share on Facebook
  • Now, the interstitial and rewarded are working normally with project export iOS. But on iPad the black container for ads are not covering the full screen, and the interstitial or reward ad seems to be on the full size screen, getting off center in the canvas.





    I use the common admob code on examples for calling the ads. Not using the setAligment because I think it was only for banner ads.

    It seem, the black canvas container should be fullscreen iPad for a right ad show. On Android not happens the same thing.

    Now, I was testing with Gideros 2020.11.1

    Any ideas what could?
    IMG_0224.PNG
    2224 x 1668 - 327K
    Screenshot 2020-12-06 at 5.12.44 PM.png
    2224 x 1668 - 332K
  • mcapppmcappp Member
    edited December 2020
    After making more tests, i had noticed that admob routines think the app is in PORTRAIT mode instead LANDSCAPE LEFT, at least at the beginning. After that, changes his orientation internally, but cause the glitches showed previusly.
    Is there any way how to lock screen on LANDSCAPE MODE in the Admob processing library?
  • maybe you can set screen orientation at the begining of your app?
    https://wiki.gideros.rocks/index.php/Application:setOrientation
    my growING GIDEROS github repositories: https://github.com/mokalux?tab=repositories
  • hgy29hgy29 Maintainer
    hgy29 said:

    I was kind of expecting this kind of issues, given the amount of code changes that happened. But I am surprised admob plugin ended under gaming folder (which is totally unrelated). I will do some tests, maybe admob needs an update to work with ARC

    It ended up being something else: apparently newer Xcode changed the project file format and Gideros plugin system wasn't able to patch in additional framework paths. I am fixing that. There were issues regarding ARC in AdMob and other ad providers too, I fixed the ones I could spot.

    Regarding orientation issue, make sure you disabled autorotation and set your app orientation in the project properties so that it is taken into account as soon as possible.

    Likes: MoKaLux, mcappp

    +1 -1 (+2 / -0 )Share on Facebook
  • Thanks for the answers!

    I have kept a serie of test with Gideros 2020.9.1. Above this version, the dark theme of my Mac cause a conflict on Gideros IDE, the code can't be viewed properly.

    Besides, use the Xcode 11.4.1 to run on my iOs Devices (iPad and iPhone 6 plus).

    There is a little bugs that I not mentioned before:

    - The Disable splash is checked on properties project, but Gideros splash is showing still. I can't get the way how to remove. No problems on Android.
    - The Autorotation is set with "No autorotation" and I was using Landscape Left orientation configured at properties project. Not applying programmatically on the code, because I think has the same effect. Bad ads effect happens with this configuration and others I tried. But i have to said that the ads are only showed bad on my iPad device.
    - On iPad, at the starting when a music background init, I hear a glitch. After that the app continues working fine. On my iPhone, the sound is not played in any way. Is muted. The iphone log:

    Warning: Real sample count differs from given gapless sample count. Frankenstein stream?
    Warning: Real sample count differs from given gapless sample count. Frankenstein stream?
    [gideros] starting render thread.
    [gideros] ending render thread.

    Very strange, the app has years working fine on Gideros, but now I added the ads, and take notice of this little mal functions.


  • hgy29hgy29 Maintainer
    Accepted Answer
    mcappp said:

    Thanks for the answers!
    - The Disable splash is checked on properties project, but Gideros splash is showing still. I can't get the way how to remove. No problems on Android.

    Splash is built-in all apps on iOS (system shows it while your app is loading), so you can't disable it. Just change it in your project properties to whatever you want, even an all black image if you don't want to bother too much.
    mcappp said:


    - The Autorotation is set with "No autorotation" and I was using Landscape Left orientation configured at properties project. Not applying programmatically on the code, because I think has the same effect. Bad ads effect happens with this configuration and others I tried. But i have to said that the ads are only showed bad on my iPad device.

    There is a to figure out if it is an orientation issue, that is if iOS UI orientation and Gideros orientation differs: try to show the keyboard (application:setKeyboardVisible(true)), if it doesn't pop at the bottom of the screen, then it is an orientation mismatch and a core Gideros issue. If the keyboard is shown ok, then it is an issue with AdMob plugin, and I don't really know how it works. Maybe its framework just needs to be updated though.
    mcappp said:


    - On iPad, at the starting when a music background init, I hear a glitch. After that the app continues working fine. On my iPhone, the sound is not played in any way. Is muted.

    iPad and iPhone code are the same, so you shouldn't experience any difference. Isn't it that your phone app sound is muted in the phone settings ?

    +1 -1 (+2 / -0 )Share on Facebook
  • Thanks for the answers again.
    I configured the splash on iOS properties and works fine.
    The sound on my iPhone didn't sound because accidentally i turned off the ringer.

    I want to deploy on an iPhone Max Pro 11, but the project doesn't run on Xcode 11.4. So, I downloaded the last versions Gideros 2020.12 and XCode 12.2.

    Once the project is on Xcode this error is showing, i'm not a XCode developer, i think it seems simple, but i have no idea what could move on Xcode project to fix the error.


    xcode error.jpg
    1024 x 500 - 148K
  • hgy29hgy29 Maintainer
    This is a problem with 2020.12, and although I fixed the sources I am not ready to build another pre-release yet. It should work ok with 2012.11 and Xcode 12.

    You can also try to fix it directly in your exported project:
    1° Make sure GoogleMobileAds is in the path. A trick that worked for me was to go to projects general settings, scroll down to the Framework listing and chnage GoogleMobileAds to 'Embed', try to launch, and switch it back to what it was before (non embed).
    2° If that solved the issue with GoogleMobileAds not found, you should now face two more code issues in AdsAdMob.m, related to ARC. Just comment out the offending lines (interstitial_=nil and view_=nil).

    That should do it.
  • hgy29 said:



    mcappp said:


    - The Autorotation is set with "No autorotation" and I was using Landscape Left orientation configured at properties project. Not applying programmatically on the code, because I think has the same effect. Bad ads effect happens with this configuration and others I tried. But i have to said that the ads are only showed bad on my iPad device.

    There is a to figure out if it is an orientation issue, that is if iOS UI orientation and Gideros orientation differs: try to show the keyboard (application:setKeyboardVisible(true)), if it doesn't pop at the bottom of the screen, then it is an orientation mismatch and a core Gideros issue. If the keyboard is shown ok, then it is an issue with AdMob plugin, and I don't really know how it works. Maybe its framework just needs to be updated though.

    The setKeyboardVisibility not show the keyboard on the screen. However I did the test setting the orientation on LANDSCAPE and PORTRAIT, getting the following results:

    On portrait mode the interstitial looks fine:


    On landscape mode the interstitial doesn't match on the canvas container. It's a pity because my game is landscape. I can't figure how to change that width canvas in order to get the full ad inside it.


    On others apps from the store we could see the adds on fullscreen.


    Maybe I will have to publish only as a iPhone app :smile:



    portrait.PNG
    1668 x 2224 - 159K
    landscape.PNG
    2224 x 1668 - 378K
    normal.PNG
    2224 x 1668 - 260K
  • You should talk to official support I think. They should help if your apps are necessary.
Sign In or Register to comment.