Hello! I made a game and used CocoonJS to add ads to my game. I want to use admob to do this. I exported the game using Cordova and XDK and now I am trying to publish my game (first time ever) and in my Google Play account there is an option called In-app products. When I click that it appears "To add in-app products, you need to add the BILLING permission to your APK." and "To add in-app products, you need to set up a Google Payments merchant account.". Do I need to do this, for ads, or this is only for when you buy stuff inside the game (gems or crystals or stuff like that)? Also, if I need to do this, how can I add Billing permission to my app. Is this done when I make the setting for SDK build? Thank you!
First, you need account with AdMob: then if you are done. sign-in to your account then go, Monetize New App --> Add Your App Manually. Then write your app name and chose the platform. click Add after that, then chose Banner and write a name for it down by "Ad unit name". After that click skip at Firebase for now. Finally Cilck at "Done".
it will take you back to new window. Chose your App from the left. Look at the right and copy your "Ad unit ID"
look at the picture:
Second, in your C2 Project open it and do as follows: Insert New Object --> Admob Ads
Third, click at the Admob Ads in your C2. You will see its properties. paste your "Ad unit ID" to "Banner ID ( Android )" Or
Banner ID ( IOS ).
Fourth, do as follow:
Add event -> System -> On Start of Layout
-Add action -> AdmobAds -> Preload banner ad
-Add action -> AdmobAds -> Show banner -> Position: Bottom center -> size: Smart Banner -> Done
Then add this plugin to your Config.xml File:
<plugin name="github.com/cranberrygame/cordova-plugin-ad-admob" source="npm" ></plugin>[/code:2kf9yzbu]
I hope this help...