AdManager awakeにInitializeRewardedAds追加
This commit is contained in:
parent
2b0312ffe3
commit
a4ffb1ac49
|
|
@ -21,6 +21,11 @@ public sealed class AdManager : SingletonMonoBehaviour<AdManager> {
|
|||
|
||||
|
||||
void Awake(){
|
||||
#if UNITY_EDITOR
|
||||
return;
|
||||
#endif
|
||||
InitializeRewardedAds();
|
||||
|
||||
#if DEVELOPMENT_BUILD
|
||||
IronSource.Agent.validateIntegration ();
|
||||
IronSource.Agent.setAdaptersDebug(true);
|
||||
|
|
@ -29,6 +34,9 @@ public sealed class AdManager : SingletonMonoBehaviour<AdManager> {
|
|||
}
|
||||
|
||||
void Start(){
|
||||
#if UNITY_EDITOR
|
||||
return;
|
||||
#endif
|
||||
LoadBannerAds();
|
||||
ShowBannerAd();
|
||||
}
|
||||
|
|
@ -92,10 +100,11 @@ public sealed class AdManager : SingletonMonoBehaviour<AdManager> {
|
|||
_rewardAdClose = true;
|
||||
}
|
||||
public bool IsLoadedRewardVideo(){
|
||||
#if DEVELOPMENT_BUILD || UNITY_EDITOR
|
||||
#if UNITY_EDITOR
|
||||
return !UsayaStorageManager.LoadOrDefault(UsayaStorageFilename.Settings_Data, "DebugAlwaysVideoFailToLoad", false);
|
||||
#endif
|
||||
#else
|
||||
return IronSource.Agent.isRewardedVideoAvailable();
|
||||
#endif
|
||||
}
|
||||
public void ShowRewardVideo(Action<bool> callback){
|
||||
#if UNITY_EDITOR
|
||||
|
|
|
|||
Loading…
Reference in New Issue