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.
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, 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,
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
SETUP GUIDE
6
Select the desired advertisers from the settings window using the checkbox.
7
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).
8
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.
9
ADVANCED SETUP
If more than one advertiser is selected the mediation section will be displayed.
10
THERE ARE 2 OPTIONS:
11
ORDER MEDIATION
12
PERCENT MEDIATION
13
Independent mediation policy can be set for each ad type (banner, interstitial, rewarded video)
14
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.
15
The .txt file is located in Assets/GleyPlugins/Ads/AdOrderFile/AdOrder.txt
16
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).
17
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.
18
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();
Advertisements.Instance.ShowInterstitial(InterstitialClosed);
19
Show Rewarded Video ad:
Advertisements.Instance.ShowRewardedVideo(CompleteMethod);
The complete callback method is called after the rewarded video ad is closed.
bool Advertisements.Instance.IsBannerAvailable();
bool Advertisements.Instance.IsInterstitialAvailable();
bool Advertisements.Instance.IsRewardVideoAvailable()
20
EXAMPLES
The test scene can be opened by pressing the “Open Test Scene”
button or by going to:
Assets/GleyPlugins/Example/TestAdsScene.unity
21
ADVERTISER SDK SPECIFIC SETTINGS/ERRORS
22
Admob (tested with version 3.13.1)
23
Admob iOS (tested with version 3.13.1)
24
Chartboost(tested withe version 7.2.0)
25
Heyzap (Tested with version 9.21.0)
https://support.vungle.com/hc/en-us/articles/115000820512
27
The ads are only showing in build not in Unity editor.