Gley MobileAds Documentation
Gley MobileAds Documentation
● Integrate easily all supported advertisers simply by importing their SDK, no other settings are
required. It is not mandatory to integrate all/any of the supported advertisers to work.
● Customizable mediation policy by using either order mediation or percent based mediation. You
can select independent type of mediation for each type of ad (banner, interstitial, rewarded
video).
● Read mediation config file from an external server of choice to allow the ad display order to be
changed without uploading a new build to the store.
● GDPR Compliant.
● COPPA Compliant
2
CURRENTLY SUPPORTED ADVERTISERS
3
GDPR COMPLIANCE
Our plugin does not collect any personal information only selected advertisers collect personal
information about users. Here is a list of how any advertiser deals with personal user data and what you
have to do to be compliant with GDPR:
Unity Ads
Versions 2.0 and above will automatically present users with an opportunity to opt-out of
targeted advertising, with no implementation needed from the publisher. On a per-app
basis, the first time a Unity ad appears, the user will see a banner with the option to
opt-out of behaviorally targeted advertising. Thereafter, the user can click an informa-
tion button to receive the opt-out again.
No specific action needed.
Vungle
Vungle will display a consent dialog before playing an ad for a European user, and will
remember the user’s consent or rejection for subsequent ads.
No specific action needed.
4
Admob, AdColony, AppLovin, Heyzap
All require that implementation of getting user consent for receiving targeted ads to be
made by publisher in his application and then to be sent to their SDK(Admob, AdColony, AppLovin
Heyzap).
If the application user does not accept the compliance they will keep serving ads but it
will not be targeted anymore.
Getting consent from the user is needed to display ads in order to be compliant with GDPR.
Chartboost
Chartboost requires that implementation of getting user consent for receiving targeted ads
to be made by publisher in his application and then sent to Chartboost SDK.
If the application user does not accept the compliance Chartboost SDK will not provide any
Ads.
Getting consent from the user is needed to display ads in order to be compliant with GDPR.
5
COPPA COMPLIANCE
COPPA (Children's Online Privacy Protection Act) is required if your app is directed to children under the
age of 13. To be compliant with COPPA your app does not have to collect any user data.
Each ad publisher we support has his own way to deal with COPPA. some of them within dashboard and
some of them required some in app setup. Here is a detailed description of what you should do to be
compliant:
Admob
6
Heyzap
Official documentation can be found here:
https://developers.heyzap.com/docs/faq
Additionally you have to check the directed for children check-box in our Settings Window.
Unity Ads
Official documentation can be found here:
https://docs.unity3d.com/Manual/UnityAnalyticsCOPPA.html
All is done from dashboard, no action required from SDK.
Chartboost
Official documentation can be found here:
https://answers.chartboost.com/en-us/zingtree in section: Data, Privacy & GDPR -> Behavioral
Targeting.
All is done from dashboard, no action required from SDK.
AdColony
Official documentation can be found here:
http://support.adcolony.com/customer/en/portal/articles/1211853-coppa-f-a-q-
All is done from dashboard, no action required from SDK.
AppLovin
Official documentation can be found here:
https://dash.applovin.com/docs/integration#androidUnityPrivacySettings
We do all that for you, just have to check the box in our Settings Window.
Vungle
You have to send an e-mail to Vungle team to enable COPPA for your app. It cannot be enabled
7
from your dashboard.
SETUP GUIDE
8
Select the desired advertisers from the settings window using the checkbox.
9
Select the desired platforms to build for(Android/iOS/Windows Store).
Add sdk keys for all your platforms of choice (Read the SDK provider documentation on how to obtain
these keys).
10
Download and import the selected advertiser SDK. No additional Unity setup is required.
Press the Save button for saving settings made in previous steps and all is done.
11
ADVANCED SETUP
If more than one advertiser is selected the mediation section will be displayed.
12
THERE ARE 2 OPTIONS:
13
ORDER MEDIATION
14
PERCENT MEDIATION
15
Independent mediation policy can be set for each ad type (banner, interstitial, rewarded video)
16
EXTERNAL FILE SETTINGS
To be able to change the above settings outside the build (after the build was published to store) an
external config file can be used.
Press the Generate Settings File button and all your settings will be saved in a .txt file that can be
uploaded to any server and the URL of the file must be pasted in the text box above the button.
17
The .txt file is located in Assets/GleyPlugins/Ads/AdOrderFile/AdOrder.txt
18
USAGE GUIDE
Debug Mode
If the debug mode is checked in the settings window, debug messages will be displayed
on the screen.
GDPR Compliance
(it is not required if just Unity and/or Vungle sdk`s are used, otherwise is mandatory for GDPR).
19
Advertisements.Instance.SetUserConsent(bool consent);
Sets and also stores(saves on device) the user answer so all ads from now on will be displayed
Based on this settings.
The default setting (if is not set by the user) is true - will display targeted ads.
bool Advertisements.Instance.UserConsentWasSet()
If true, user already gave his consent, do not bother him anymore.
Remove Ads
Advertisements.Instance.RemoveAds(true);
If parameter is true, no banner and interstitial ads will be shown, rewarded videos will work.
You have to call this just once, then it will be saved and used accordingly.
You only need this method if you have an in app product that has remove ads functionality or
other methods that permit to remove all ads from the game.
20
Initializing the SDK:
Advertisements.Instance.Initialize();
This method must be called once at the launch of your project.
No prefabs need to be dragged into stage and no scripts needs to be attached to GameObjects.
Advertisements.Instance.ShowBanner(BannerPosition.BOTTOM);
Supported banner positions are TOP and BOTTOM.
Advertisements.Instance.HideBanner();
The complete callback method is called after the rewarded video ad is closed.
bool Advertisements.Instance.IsInterstitialAvailable();
bool Advertisements.Instance.IsRewardVideoAvailable();
bool Advertisements.Instance.IsBannerOnScreen(); 22
Playmaker Support
● To be able to use Playmaker actions, Playmaker Support must be enabled from Settings Window:
● To initialize the SDK you have to drag and drop the InitializeGleyAds on your first scene of the
project
● The prefab is located in: GleyPlugins/Ads/PlayMakerSupport/Prefabs/InitializeGleyAds
● To be able to use Bolt actions, Bolt Support must be enabled from Settings Window:
24
Game Flow Support
● To be able to use Game Flow actions, Game Flow Support must be enabled from Settings Window:
The test scene can be opened by pressing the “Open Test Scene”
button or by going to:
Assets/GleyPlugins/Example/TestAdsScene.unity
26
ADVERTISER SDK SPECIFIC SETTINGS/ERRORS
27
Admob (tested with version 3.18.3)
To receive live ads make sure your payment details are filled in your Admob account and
your app is signed with your release key
28
Admob
If your app crashes at right after start:
29
Admob iOS (tested with version 3.18.3)
30
AppLovin (tested with version 6.1.1)
For iOS in xCode you have to add you SDK key to your info.plist:
● Create a string property named AppLovinSdkKey and add your SDK key as a value like in the
screenshot below:
31
Heyzap (tested with version 9.56.0)
32
Unity (tested with version 3.2.0)
You need Unity Monetization 3.0 or above to work, it does not work with the built in editor
ads. Please disable Ads from Service window.
33
Vungle (tested with version 6.3.0)
https://support.vungle.com/hc/en-us/articles/115000820512
34
Facebook Audience Network (tested with version 5.4.1)
● Support-compat
● Support-core-ui
● Support-core-utils
Delete Assets/Plugins/Android/androidx.core.core-1.0.0
35
The ads are only showing in build not in Unity editor.