Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Banner isn't at the bottom of the screen on iPhone 12 Pro #66

Closed
novalis opened this issue Dec 12, 2022 · 6 comments
Closed

Banner isn't at the bottom of the screen on iPhone 12 Pro #66

novalis opened this issue Dec 12, 2022 · 6 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@novalis
Copy link

novalis commented Dec 12, 2022

Godot version

3.5.1

Plugin version

v2.1.1

Phone information

iPhone 12 Pro, ios 16

Issue description

screenshot-iPhone 12 Pro-16 0

The banner isn't at the bottom of the screen -- instead, it has crept up to cover my content.

Steps to reproduce

This seems to be true whether or not I have respect_safe_area turned on.

Additional context

No response

@novalis novalis added the bug Something isn't working label Dec 12, 2022
@gumaciel
Copy link
Contributor

Thank you for opening this Issue, we will investigate this.

@gumaciel gumaciel transferred this issue from poingstudios/godot-admob-ios Mar 2, 2023
@gumaciel gumaciel added this to the godot4-v1.0.1 milestone Mar 2, 2023
@gumaciel gumaciel self-assigned this Mar 2, 2023
@gumaciel
Copy link
Contributor

gumaciel commented Mar 4, 2023

Seems to be working normally on Godot 3, i will generate some version of the plugins this days, but this bug really happened on Godot 4 and it's already be fixing

Without Respect Safe Area:

Captura de Tela 2023-03-03 às 23 33 38
Captura de Tela 2023-03-03 às 23 33 51

With Respect Safe Area:
Captura de Tela 2023-03-03 às 23 34 08

Tested on :
Godot: 3.5.1-stable
Godot AdMob Editor: godot3-v1.3.3
Godot AdMob iOS: v2.1.2

@novalis
Copy link
Author

novalis commented Mar 4, 2023 via email

@gumaciel
Copy link
Contributor

@novalis this is actually working for me, it still happens to you on the latest version?

@novalis
Copy link
Author

novalis commented Apr 25, 2023

I'm sorry, but unfortunately, I don't know. I was testing using BrowserStack, since getting Godot working with the simulator on a M1 Mac is pretty annoying. But I gave up my BrowserStack account. I'm no longer working on the app in question, or any app that uses ads (for now). For what it's worth, the fix for me was:

diff --git a/plugin/admob/src/formats/Banner.mm b/plugin/admob/src/formats/Banner.mm
index 75e2a64..9f8cee1 100755
--- a/plugin/admob/src/formats/Banner.mm
+++ b/plugin/admob/src/formats/Banner.mm
@@ -150,6 +150,7 @@ - (void)addBannerViewToView {
                                         attribute:NSLayoutAttributeBottom
                                         multiplier:1
                                         constant:0]];
+       bannerView.center = CGPointMake(rootController.view.center.x, rootController.view.frame.size.height-CGSizeFromGADAdSize(GADAdSizeBanner).height/2);

@gumaciel
Copy link
Contributor

Closing due stale, on #82 it should only appear the BannerAds in the SafeArea

@gumaciel gumaciel closed this as not planned Won't fix, can't repro, duplicate, stale Jun 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Done
Development

No branches or pull requests

2 participants