Compare commits

..

No commits in common. "67abd081c8a1cfefde1b3ae4f0aec03e74c34577" and "50c5627ac2c0593d48c6d62e20f8601f4f088d44" have entirely different histories.

27 changed files with 75 additions and 432 deletions

View File

@ -1,5 +1,4 @@
using System;
using UnityEngine;
namespace Guru
@ -116,7 +115,7 @@ namespace Guru
private void OnLoadMaxBanner()
{
_badsloadStartTime = DateTime.UtcNow;
_badsloadStartTime = Time.realtimeSinceStartup;
_chanelMax.LoadBannerAD();
OnBannerStartLoad?.Invoke(_chanelMax.MaxBADSSlotID);
}
@ -148,7 +147,7 @@ namespace Guru
}
private void OnLoadMaxIV() {
_iadsLoadStartTime = DateTime.UtcNow; // 更新计时器
_iadsLoadStartTime = Time.realtimeSinceStartup; // 更新计时器
_chanelMax.LoadInterstitialAD();
OnInterstitialStartLoad?.Invoke(_chanelMax.MaxIADSSlotID);
}
@ -181,7 +180,7 @@ namespace Guru
private void OnLoadMaxRV()
{
_radsLoadStartTime = DateTime.UtcNow; // 更新计时器
_radsLoadStartTime = Time.realtimeSinceStartup; // 更新计时器
_chanelMax.LoadRewardAD();
OnRewardedStartLoad?.Invoke(_chanelMax.MaxRADSSlotID);
}

View File

@ -213,24 +213,11 @@ namespace Guru
// #2 tch_001
double revenue = impressionData.value;
CalcTch001Value(revenue);
CalcTch02Value(revenue);
CalcTaichi001Value(revenue);
CalcTaichi02Value(revenue);
// #3 adjust_ad_revenue
AdjustService.TrackADRevenue(impressionData);
var adType = impressionData.ad_format.ToUpper();
// #4 Paid Event
Debug.Log($"{Tag} --- ReportAdsRevenue :: Send Paid Event: {adType}");
if (adType.Contains("INTER"))
{
OnInterstitialPaidEvent(impressionData);
}
else if (adType.Contains("REWARD"))
{
OnRewardedAdPaidEvent(impressionData);
}
}
@ -251,7 +238,7 @@ namespace Guru
else
{
// 找不到的话会缓存 adInfo, 等待获取 RCid
SetImpressionData(adInfo);
_impressionCache[adInfo.CreativeIdentifier] = CreateImpressionData(adInfo, "", Analytics.AdMAX);
}
}
@ -294,7 +281,7 @@ namespace Guru
/// 计算太极001收益
/// </summary>
/// <param name="revenue"></param>
private void CalcTch001Value(double revenue)
private void CalcTaichi001Value(double revenue)
{
TchAD001RevValue += revenue;
double revenueValue = TchAD001RevValue;
@ -311,7 +298,7 @@ namespace Guru
/// 计算太极02收益
/// </summary>
/// <param name="revenue"></param>
private void CalcTch02Value(double revenue)
private void CalcTaichi02Value(double revenue)
{
if (!Analytics.EnableTch02Event) return;
@ -333,24 +320,20 @@ namespace Guru
private string _backColorStr = "#50A436";
private Color _backColor = new Color(0, 0, 0, 0);
private string _badsCategory;
protected DateTime _badsloadStartTime;
protected float _badsloadStartTime = 0;
private bool _bannerVisible = false;
public bool IsBannerVisible => _bannerVisible;
private int _badsloadedNum = 0;
private int _badsLoadFailNum = 0;
/// <summary>
/// 获取动作间隔之间的毫秒数
/// </summary>
/// <param name="startTime"></param>
/// <returns></returns>
private int GetActionDuration(DateTime startTime)
{
var sp = DateTime.UtcNow.Subtract(startTime.ToUniversalTime()).Duration();
return (int) sp.TotalMilliseconds;
}
private int GetAdsLoadDuration(ref float startTime)
{
int duration = (int)((Time.realtimeSinceStartup - startTime) * 1000);
startTime = Time.realtimeSinceStartup;
return duration;
}
public virtual void RequestBannerAD()
{
@ -382,12 +365,12 @@ namespace Guru
public void OnLoadBads()
{
_badsloadStartTime = DateTime.UtcNow;
_badsloadStartTime = Time.realtimeSinceStartup;
}
protected virtual void OnBadsLoaded()
{
_badsloadStartTime = DateTime.UtcNow;
_badsloadStartTime = Time.realtimeSinceStartup;
OnBannerLoaded?.Invoke();
}
@ -463,7 +446,7 @@ namespace Guru
_badsLoadFailNum ++;
// Analytics.ADBadsFailed(adUnitId, (int)errorInfo.Code, GetAdsLoadDuration(ref _badsloadStartTime), _badsCategory);
Analytics.ADBadsFailed(AdParams.Build(adUnitId,
duration: GetActionDuration(_badsloadStartTime), category: _badsCategory,
duration: GetAdsLoadDuration(ref _badsloadStartTime), category: _badsCategory,
errorCode: (int)errorInfo.Code,
waterfallName: errorInfo?.WaterfallInfo?.Name ?? ""));
}
@ -505,12 +488,9 @@ namespace Guru
private string _iadsCategory = "main";
private int _interstitialRetryAttempt;
protected float _iadsLoadStartTime;
private Action _interCloseAction;
protected bool _isIadsLoading = false;
protected DateTime _iadsLoadStartTime;
private DateTime _iadsDisplayStartTime;
public bool IsIadsLoading => _isIadsLoading;
public virtual void RequestInterstitialAD()
@ -534,7 +514,7 @@ namespace Guru
public void OnLoadIads()
{
_iadsLoadStartTime = DateTime.UtcNow;
_iadsLoadStartTime = Time.realtimeSinceStartup;
}
@ -568,7 +548,6 @@ namespace Guru
_interCloseAction = dismissAction;
MaxSdk.ShowInterstitial(GetInterstitialID());
_iadsDisplayStartTime = DateTime.UtcNow;
// RequestInterstitialAD(); // 直接加载下一个广告
}
@ -579,7 +558,7 @@ namespace Guru
// Reset retry attempt
// Analytics.ADIadsLoaded(adUnitId, GetAdsLoadDuration(ref _iadsLoadStartTime), _iadsCategory);
Analytics.ADIadsLoaded(AdParams.Build(adUnitId,
duration: GetActionDuration(_iadsLoadStartTime), category: _iadsCategory));
duration: GetAdsLoadDuration(ref _iadsLoadStartTime), category: _iadsCategory));
_interstitialRetryAttempt = 0;
Debug.Log( $"[SDK][Ads][Loaded] --- adUnitId:{adUnitId} Revenue:{adInfo.Revenue} Type:{adInfo.AdFormat} CreativeId:{adInfo.CreativeIdentifier}");
@ -598,9 +577,8 @@ namespace Guru
float retryDelay = GetRetryDelaySeconds(_interstitialRetryAttempt);
DelayCall(retryDelay, RequestInterstitialAD);
// Analytics.ADIadsFailed(adUnitId, (int)errorInfo.Code, GetAdsLoadDuration(ref _iadsLoadStartTime), _iadsCategory);
if(string.IsNullOrEmpty(_iadsCategory)) _iadsCategory = "not_set";
Analytics.ADIadsFailed(AdParams.Build(adUnitId,
duration: GetActionDuration(_iadsLoadStartTime), category: _iadsCategory,
duration: GetAdsLoadDuration(ref _iadsLoadStartTime), category: _iadsCategory,
errorCode: (int)errorInfo.Code,
waterfallName: errorInfo?.WaterfallInfo?.Name ?? ""));
@ -615,65 +593,42 @@ namespace Guru
$"InterstitialFailedToDisplayEvent AdLoadFailureInfo:{errorInfo.AdLoadFailureInfo}, Message: {errorInfo.Message}");
// Analytics.ADIadsFailed(adUnitId, (int)errorInfo.Code, GetAdsLoadDuration(ref _iadsLoadStartTime), _iadsCategory);
Analytics.ADIadsFailed(AdParams.Build(adUnitId,
duration: GetActionDuration(_iadsDisplayStartTime), category: _iadsCategory,
duration: GetAdsLoadDuration(ref _iadsLoadStartTime), category: _iadsCategory,
errorCode: (int)errorInfo.Code,
waterfallName: errorInfo?.WaterfallInfo?.Name ?? ""));
DelayCall(2.0f, RequestInterstitialAD);
}
// iads_imp
protected virtual void OnInterstitialDisplayEvent(string adUnitId, MaxSdkBase.AdInfo adInfo)
{
// Analytics.ADIadsImp(adUnitId, _iadsCategory);
string reviewCreativeId = GetReviewCreativeId(adInfo.CreativeIdentifier);
Analytics.ADIadsImp(AdParams.Build(adUnitId, adInfo, category: _iadsCategory, reviewCreativeId:reviewCreativeId));
Analytics.ADIadsImp(AdParams.Build(adUnitId, category: _iadsCategory));
}
protected virtual void OnInterstitialClickEvent(string adUnitId, MaxSdkBase.AdInfo adInfo)
{
// Analytics.ADIadsClick(adUnitId, _iadsCategory);
string reviewCreativeId = GetReviewCreativeId(adInfo.CreativeIdentifier);
var impressionData = CreateImpressionData(adInfo, reviewCreativeId);
var data = impressionData.BuildEventData();
if(string.IsNullOrEmpty(_iadsCategory)) _iadsCategory = "not_set";
data["item_category"] = _iadsCategory;
data.Remove("ad_format");
Analytics.ADIadsClick(data);
Analytics.ADIadsClick(AdParams.Build(adUnitId, category: _iadsCategory));
}
// Close
protected virtual void OnInterstitialDismissedEvent(string adUnitId, MaxSdkBase.AdInfo adInfo)
{
// Interstitial ad is hidden. Pre-load the next ad
_interCloseAction?.Invoke();
OnInterstitialClosed?.Invoke();
// Analytics.ADIadsClose(adUnitId, _iadsCategory);
Analytics.ADIadsClose(AdParams.Build(adUnitId,
duration:GetActionDuration(_iadsDisplayStartTime),
category: _iadsCategory));
Analytics.ADIadsClose(AdParams.Build(adUnitId, category: _iadsCategory));
//延时加载下一个广告
DelayCall(2.0f, RequestInterstitialAD);
}
private void OnInterstitialPaidEvent(AdImpressionData impressionData)
{
var data = impressionData.BuildEventData();
if(string.IsNullOrEmpty(_iadsCategory)) _iadsCategory = "not_set";
data["item_category"] = _iadsCategory;
data.Remove("ad_format");
Analytics.ADIadsPaid(data);
}
#endregion
#region Rewarded Ads
private string _rewardCategory = "main";
private int _rewardRetryAttempt;
protected DateTime _radsLoadStartTime;
protected DateTime _radsShowStartTime;
protected float _radsLoadStartTime;
private Action _rvRewardAction;
private Action<string> _rvFailAction;
private Action _rvDismissAction;
@ -706,7 +661,7 @@ namespace Guru
public void OnLoadRads()
{
_radsLoadStartTime = DateTime.UtcNow;
_radsLoadStartTime = Time.realtimeSinceStartup;
}
@ -745,8 +700,6 @@ namespace Guru
_rvDismissAction = dismissAction;
MaxSdk.ShowRewardedAd(GetRewardedID());
_radsShowStartTime = DateTime.UtcNow;
// RequestRewardedAD();
}
@ -759,7 +712,7 @@ namespace Guru
// this.Log("OnRewardedAdLoadedEvent");
// Analytics.ADRadsLoaded(adUnitId, GetAdsLoadDuration(ref _radsLoadStartTime), _rewardCategory);
Analytics.ADRadsLoaded(AdParams.Build(adUnitId,
duration: GetActionDuration(_radsLoadStartTime), category: _iadsCategory));
duration: GetAdsLoadDuration(ref _radsLoadStartTime), category: _iadsCategory));
_rewardRetryAttempt = 0;
Debug.Log( $"[SDK][Ads][Loaded] --- adUnitId:{adUnitId} Revenue:{adInfo.Revenue} Type:{adInfo.AdFormat} CreativeId:{adInfo.CreativeIdentifier}");
@ -777,7 +730,7 @@ namespace Guru
$"OnRewardedAdFailedEvent AdLoadFailureInfo:{errorInfo.AdLoadFailureInfo}, Message: {errorInfo.Message}");
// Analytics.ADRadsFailed(adUnitId, (int)errorInfo.Code, GetAdsLoadDuration(ref _radsLoadStartTime), _rewardCategory);
Analytics.ADRadsFailed(AdParams.Build(adUnitId,
duration: GetActionDuration(_radsLoadStartTime), category: _rewardCategory,
duration: GetAdsLoadDuration(ref _radsLoadStartTime), category: _rewardCategory,
errorCode: (int)errorInfo.Code,
waterfallName: errorInfo?.WaterfallInfo?.Name ?? ""));
_rewardRetryAttempt++;
@ -795,7 +748,7 @@ namespace Guru
$"OnRewardedAdFailedToDisplayEvent AdLoadFailureInfo:{errorInfo.AdLoadFailureInfo}, Message: {errorInfo.Message}");
// Analytics.ADRadsFailed(adUnitId, (int)errorInfo.Code, GetAdsLoadDuration(ref _radsLoadStartTime), _rewardCategory);
Analytics.ADRadsFailed(AdParams.Build(adUnitId,
duration: GetActionDuration(_radsShowStartTime), category: _rewardCategory,
duration: GetAdsLoadDuration(ref _radsLoadStartTime), category: _rewardCategory,
errorCode: (int)errorInfo.Code,
waterfallName: errorInfo?.WaterfallInfo?.Name ?? ""));
_rvFailAction?.Invoke("OnRewardedAdFailedToDisplayEvent");
@ -808,23 +761,16 @@ namespace Guru
{
this.Log("OnRewardedAdDisplayedEvent");
// Analytics.ADRadsImp(adUnitId, _rewardCategory);
string reviewCreativeId = GetReviewCreativeId(adInfo.CreativeIdentifier);
Analytics.ADRadsImp(AdParams.Build(adUnitId, adInfo, category: _rewardCategory, reviewCreativeId:reviewCreativeId));
Analytics.ADRadsImp(AdParams.Build(adUnitId, category: _rewardCategory));
}
protected virtual void OnRewardedAdClickedEvent(string adUnitId, MaxSdkBase.AdInfo adInfo)
{
this.Log("OnRewardedAdClickedEvent");
// Analytics.ADRadsClick(adUnitId, _rewardCategory);
var impressionData = CreateImpressionData(adInfo, GetReviewCreativeId(adInfo.CreativeIdentifier));
var data = impressionData.BuildEventData();
if(string.IsNullOrEmpty(_rewardCategory)) _rewardCategory = "not_set";
data["item_category"] = _rewardCategory;
data.Remove("ad_format");
Analytics.ADRadsClick(data);
Analytics.ADRadsClick(AdParams.Build(adUnitId, category: _rewardCategory));
}
// rads_close
protected virtual void OnRewardedAdDismissedEvent(string adUnitId, MaxSdkBase.AdInfo adInfo)
{
this.Log("OnRewardedAdDismissedEvent");
@ -833,37 +779,24 @@ namespace Guru
OnRewardClosed?.Invoke();
// Analytics.ADRadsClose(adUnitId, _rewardCategory);
Analytics.ADRadsClose(AdParams.Build(adUnitId, duration:GetActionDuration(_radsShowStartTime), category: _rewardCategory));
Analytics.ADRadsClose(AdParams.Build(adUnitId, category: _rewardCategory));
//延时加载下一个广告
DelayCall(2.0f, RequestRewardedAD);
}
// rads_rewarded
protected virtual void OnRewardedAdReceivedRewardEvent(string adUnitId, MaxSdk.Reward reward,
MaxSdkBase.AdInfo adInfo)
MaxSdkBase.AdInfo arg3)
{
this.Log("OnRewardedAdReceivedRewardEvent");
// Analytics.ADRadsRewarded(adUnitId, _rewardCategory);
var impressionData = CreateImpressionData(adInfo, GetReviewCreativeId(adInfo.CreativeIdentifier));
var data = impressionData.BuildEventData();
if(string.IsNullOrEmpty(_rewardCategory)) _rewardCategory = "not_set";
data["item_category"] = _rewardCategory;
data.Remove("ad_format");
Analytics.ADRadsRewarded(data);
Analytics.ADRadsRewarded(AdParams.Build(adUnitId, category: _rewardCategory));
// Rewarded ad was displayed and user should receive the reward
_rvRewardAction?.Invoke();
}
// rads_paid
private void OnRewardedAdPaidEvent(AdImpressionData impressionData)
{
var data = impressionData.BuildEventData();
if(string.IsNullOrEmpty(_rewardCategory)) _rewardCategory = "not_set";
data["item_category"] = _rewardCategory;
data.Remove("ad_format");
Analytics.ADRadsPaid(data);
}
#endregion
#region Ad Settings
@ -907,36 +840,7 @@ namespace Guru
#endregion
#region CreativeID
private string GetReviewCreativeId(string creativeId)
{
if (_reviewCreativeIds == null)
{
return "";
}
if (_reviewCreativeIds.TryGetValue(creativeId, out var reviewCreativeId))
{
return reviewCreativeId;
}
return "";
}
private void SetReviewCreativeId(string creativeId, string reviewCreativeId)
{
if (_reviewCreativeIds == null) _reviewCreativeIds = new Dictionary<string, string>(10);
if (string.IsNullOrEmpty(reviewCreativeId)) return;
_reviewCreativeIds[creativeId] = reviewCreativeId;
}
private void SetImpressionData(MaxSdkBase.AdInfo adInfo, string reviewCreativeId = "", string platform = "")
{
if (string.IsNullOrEmpty(platform)) platform = Analytics.AdMAX;
_impressionCache[adInfo.CreativeIdentifier] = CreateImpressionData(adInfo, reviewCreativeId, platform);
}
/// <summary>
/// 获取 AdReviewCreativeId
/// </summary>
@ -952,8 +856,14 @@ namespace Guru
return;
}
if (_reviewCreativeIds == null) _reviewCreativeIds = new Dictionary<string, string>(10);
// 尝试直接上报广告收益 (可能存在异步上报的情况)
TryReportImpression(adInfo, reviewCreativeId);
if (!TryReportImpression(adInfo, reviewCreativeId))
{
_reviewCreativeIds[adInfo.CreativeIdentifier] = reviewCreativeId; // 如果上报未成功, 则缓存reviewCreativeId
}
}
/// <summary>
@ -962,9 +872,10 @@ namespace Guru
/// <param name="adInfo"></param>
/// <param name="reviewCreativeId"></param>
/// <returns></returns>
private void TryReportImpression(MaxSdk.AdInfo adInfo, string reviewCreativeId = "")
private bool TryReportImpression(MaxSdk.AdInfo adInfo, string reviewCreativeId = "")
{
string creativeId = adInfo.CreativeIdentifier;
bool result = false;
List<string> removeList = new List<string>();
if (_impressionCache.TryGetValue(creativeId, out var impressionData))
@ -974,11 +885,7 @@ namespace Guru
ReportAdsRevenue(impressionData);
removeList.Add(creativeId);
}
else
{
// 如果上报未成功, 则缓存reviewCreativeId
SetReviewCreativeId(adInfo.CreativeIdentifier, reviewCreativeId);
result = true;
}
// 清理超过 3 秒未上报的数据
@ -999,6 +906,8 @@ namespace Guru
_reviewCreativeIds.Remove(k);
}
}
return result;
}
#endregion

View File

@ -1,7 +1,5 @@
using System.Collections.Generic;
namespace Guru
{
using System;
@ -38,23 +36,5 @@ namespace Guru
}
public Dictionary<string, object> BuildEventData()
{
var data = new Dictionary<string, object>()
{
{ "value", value },
{ "currency", currency },
{ "ad_platform", ad_platform },
{ "ad_format", ad_format },
{ "ad_source", ad_source },
{ "ad_unit_name", ad_unit_name },
{ "ad_placement", ad_placement },
{ "ad_creative_id", ad_creative_id },
{ "review_creative_id", review_creative_id },
};
return data;
}
}
}

View File

@ -36,37 +36,15 @@ namespace Guru
if (adParams.duration > 0)
data[ParameterDuration] = adParams.duration;
if (adParams.errorCode != 0)
data[ParameterErrorCode] = adParams.errorCode;
if (!string.IsNullOrEmpty(adParams.networkName))
data[ParameterNetworkName] = adParams.networkName;
if (!string.IsNullOrEmpty(adParams.networkPlacement))
{
if (!string.IsNullOrEmpty(adParams.networkPlacement))
data[ParameterNetworkPlacement] = adParams.networkPlacement;
data[ParameterAdPlacement] = adParams.networkPlacement;
}
if (!string.IsNullOrEmpty(adParams.waterfallName))
data[ParameterWaterfall] = adParams.waterfallName;
if (!string.IsNullOrEmpty(adParams.creativeId))
data[ParameterAdCreativeId] = adParams.creativeId;
if (!string.IsNullOrEmpty(adParams.reviewCreativeId))
data[ParameterReviewCreativeId] = adParams.reviewCreativeId;
if (!string.IsNullOrEmpty(adParams.adPlatform))
data[ParameterAdPlatform] = adParams.adPlatform;
if (!string.IsNullOrEmpty(adParams.adSource))
data[ParameterAdSource] = adParams.adSource;
if (!string.IsNullOrEmpty(adParams.adFormat))
data[ParameterAdFormat] = adParams.adFormat;
if (extra != null && extra.Count > 0)
{
foreach (var k in extra.Keys)
@ -150,12 +128,7 @@ namespace Guru
/// </summary>
public static void ADIadsClick(AdParams adParams)
{
ADIadsClick(BuildAdEventData(adParams));
}
public static void ADIadsClick(Dictionary<string, object> data)
{
TrackEvent(EventIadsClick, data);
TrackEvent(EventIadsClick, BuildAdEventData(adParams));
}
/// <summary>
@ -166,15 +139,6 @@ namespace Guru
TrackEvent(EventIadsClose, BuildAdEventData(adParams));
}
/// <summary>
/// 插屏广告收到奖励
/// </summary>
/// <param name="data"></param>
public static void ADIadsPaid(Dictionary<string, object> data)
{
TrackEvent(EventIadsPaid, data);
}
//---------------------- REWARDS -------------------------
/// <summary>
/// 广告开始加载
@ -209,11 +173,7 @@ namespace Guru
/// </summary>
public static void ADRadsRewarded(AdParams adParams)
{
ADRadsRewarded(BuildAdEventData(adParams));
}
public static void ADRadsRewarded(Dictionary<string, object> data)
{
var data = BuildAdEventData(adParams);
TrackEvent(EventRadsRewarded, data);
if (RadsRewardCount == 0)
@ -223,15 +183,6 @@ namespace Guru
}
}
/// <summary>
/// 插屏广告收到奖励
/// </summary>
/// <param name="data"></param>
public static void ADRadsPaid(Dictionary<string, object> data)
{
TrackEvent(EventRadsPaid, data);
}
private static int RadsRewardCount
{
@ -252,12 +203,7 @@ namespace Guru
/// </summary>
public static void ADRadsClick(AdParams adParams)
{
ADRadsClick(BuildAdEventData(adParams));
}
public static void ADRadsClick(Dictionary<string, object> data)
{
TrackEvent(EventRadsClick, data);
TrackEvent(EventRadsClick, BuildAdEventData(adParams));
}
/// <summary>
@ -314,15 +260,10 @@ namespace Guru
public string category;
public string networkName;
public string networkPlacement;
public string adPlatform;
public string adSource;
public string adFormat;
public string waterfallName;
public string adUnitId;
public int errorCode = 0;
public int duration = 0;
public string creativeId;
public string reviewCreativeId;
/// <summary>
@ -334,47 +275,31 @@ namespace Guru
/// <param name="duration"></param>
/// <param name="errorCode"></param>
/// <param name="waterfallName"></param>
/// <param name="reviewCreativeId"></param>
/// <param name="adPlatform"></param>
/// <returns></returns>
public static AdParams Build(string adUnitId, MaxSdkBase.AdInfo adInfo = null, string category = "",
int duration = 0, int errorCode = 0, string waterfallName = "", string reviewCreativeId = "", string adPlatform = "")
int duration = 0, int errorCode = 0, string waterfallName = "")
{
if (string.IsNullOrEmpty(adUnitId) && adInfo != null) adUnitId = adInfo.AdUnitIdentifier;
var networkName = "";
var networkPlacement = "";
var creativeId = "";
var adSource = "";
var adFormart = "";
if (string.IsNullOrEmpty(adPlatform)) adPlatform = Analytics.AdMAX;
if (adInfo != null)
{
networkName = adInfo.NetworkName;
networkPlacement = adInfo.NetworkPlacement;
creativeId = adInfo.CreativeIdentifier;
adSource = adInfo.NetworkName;
adFormart = adInfo.AdFormat;
if (string.IsNullOrEmpty(waterfallName))
waterfallName = adInfo.WaterfallInfo?.Name ?? "";
}
var p = new AdParams()
{
adUnitId = adUnitId,
adPlatform = adPlatform,
adSource = adSource,
adFormat = adFormart,
duration = duration,
networkName = networkName,
networkPlacement = networkPlacement,
waterfallName = waterfallName,
category = category,
errorCode = errorCode,
creativeId = creativeId,
reviewCreativeId = reviewCreativeId,
};
return p;
}

View File

@ -161,7 +161,7 @@ namespace Guru
/// </summary>
public static void SetUserProperty(string propertyName, string propertyValue)
{
Debug.Log($"{TAG} --- SetUserProperty -> propertyName:{propertyName}, propertyValue:{propertyValue}");
Log.I(TAG,$"SetUserProperty -> propertyName:{propertyName}, propertyValue:{propertyValue}");
if (!IsReady)
return;

View File

@ -11,24 +11,6 @@ PluginImporter:
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
: Any
second:
enabled: 0
settings:
Exclude Android: 1
Exclude Editor: 1
Exclude Linux64: 1
Exclude OSXUniversal: 1
Exclude Win: 1
Exclude Win64: 1
Exclude iOS: 0
- first:
Android: Android
second:
enabled: 0
settings:
CPU: ARMv7
- first:
Any:
second:
@ -39,42 +21,13 @@ PluginImporter:
second:
enabled: 0
settings:
CPU: AnyCPU
DefaultValueInitialized: true
OS: AnyOS
- first:
Standalone: Linux64
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: OSXUniversal
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: Win
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: Win64
second:
enabled: 0
settings:
CPU: None
- first:
iPhone: iOS
second:
enabled: 1
settings:
AddToEmbeddedBinaries: false
CPU: AnyCPU
CompileFlags:
FrameworkDependencies:
AddToEmbeddedBinaries: true
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,7 +0,0 @@
fileFormatVersion: 2
guid: ec7317011341a40a1a0ee7ae5f38f270
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,8 +0,0 @@
fileFormatVersion: 2
guid: a4ccb52ed7f6b4dff8731e9e93293ccb
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,6 +1,6 @@
#if 0
#elif defined(__arm64__) && __arm64__
// Generated by Apple Swift version 5.9.2 effective-4.1.50 (swiftlang-5.9.2.2.56 clang-1500.1.0.2.5)
// Generated by Apple Swift version 5.9.2 (swiftlang-5.9.2.2.56 clang-1500.1.0.2.5)
#ifndef CONNECTIVITY_SWIFT_H
#define CONNECTIVITY_SWIFT_H
#pragma clang diagnostic push
@ -318,7 +318,7 @@ SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, copy) NSString * _No
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, copy) NSString * _Nonnull CONNECTIVITY_OTHER;)
+ (NSString * _Nonnull)CONNECTIVITY_OTHER SWIFT_WARN_UNUSED_RESULT;
- (nonnull instancetype)init SWIFT_UNAVAILABLE;
+ (nonnull instancetype)new SWIFT_DEPRECATED_MSG("-init is unavailable");
+ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
- (void)initializeWithCompletion:(void (^ _Nonnull)(BOOL))completion;
- (NSArray<NSString *> * _Nonnull)checkConnectionType SWIFT_WARN_UNUSED_RESULT;
@end

View File

@ -1,27 +0,0 @@
fileFormatVersion: 2
guid: c7072e499221b489e8a171a746c1d381
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Any:
second:
enabled: 1
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,7 +0,0 @@
fileFormatVersion: 2
guid: b3be6515c98fc4516b74799d2232851a
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,8 +0,0 @@
fileFormatVersion: 2
guid: 009197294dbfe4bd5b64f833fce7277e
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,8 +0,0 @@
fileFormatVersion: 2
guid: db929fad7809a40a6af254c5262adb3a
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,8 +0,0 @@
fileFormatVersion: 2
guid: d014052e45f6948db82f9fbecdb02a96
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,7 +0,0 @@
fileFormatVersion: 2
guid: 5a2b967c5b7f944adb348971a0e13c79
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,7 +0,0 @@
fileFormatVersion: 2
guid: b8637a4450c6b4ca895cd05427db6ffc
TextScriptImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,7 +0,0 @@
fileFormatVersion: 2
guid: 2b7b377a06cfe4472ace76077b0d1e24
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,7 +0,0 @@
fileFormatVersion: 2
guid: be5b523ba98e649d9938fc7df1e7b55a
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,7 +0,0 @@
fileFormatVersion: 2
guid: 97a465fd6df3b4f72a477ef19bf727a9
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,8 +0,0 @@
fileFormatVersion: 2
guid: 1a90376b0826241cf8ed25c4ba2b91fc
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -6,15 +6,15 @@
<dict>
<key>Headers/Connectivity-Swift.h</key>
<data>
2jZWRNZEB9lWoT02/WI0gpx8bUY=
yQkPWwZ2klcFBQT3c4PI/gTVVAE=
</data>
<key>Info.plist</key>
<data>
lVs8E6FtUHvDAsoK7zwpgZ+1m84=
n4FM+14bzgCqiae7BEnOfj78dFA=
</data>
<key>Modules/Connectivity.swiftmodule/Project/arm64-apple-ios.swiftsourceinfo</key>
<data>
3vRjRUNrw8fWaShfTaH+cBfxfLE=
KGmpTymRqrX9y4GV/j+eFuhhTYM=
</data>
<key>Modules/Connectivity.swiftmodule/arm64-apple-ios.abi.json</key>
<data>
@ -22,11 +22,11 @@
</data>
<key>Modules/Connectivity.swiftmodule/arm64-apple-ios.swiftdoc</key>
<data>
HgPMAkcK2+NGvcVfwyFJ9u/nd0k=
NaKg9acNtBzWngYfwx3Nt50tA5o=
</data>
<key>Modules/Connectivity.swiftmodule/arm64-apple-ios.swiftmodule</key>
<data>
nK9APrK3atZTGuid35+A6Dde02M=
TBHp8ndBz6+t9eK5i+Q7XONqD+w=
</data>
<key>Modules/module.modulemap</key>
<data>
@ -39,14 +39,14 @@
<dict>
<key>hash2</key>
<data>
xwPPIVygOJDaH/CCrDO25Y2645Q/IQYSiJrV3eJJy+M=
HIhSgITt+HNjHvu2O1pDvyjgx9HdyI801+Q9Bn92Suc=
</data>
</dict>
<key>Modules/Connectivity.swiftmodule/Project/arm64-apple-ios.swiftsourceinfo</key>
<dict>
<key>hash2</key>
<data>
Qgk/xiutw35xy8VeU5niELPbBEi5gVVuXYai3rhRrbI=
HnYY+N0JWfujm6LckQtevFuYEFW4uYx4hcAkaFgCZp0=
</data>
</dict>
<key>Modules/Connectivity.swiftmodule/arm64-apple-ios.abi.json</key>
@ -60,14 +60,14 @@
<dict>
<key>hash2</key>
<data>
ZNpy4/pGL15IFXpHTav2UvUYM7kQPN/0eTjxtfLqYq8=
sgsu9CnSXAG3fxoW1HBRLZ9lCTX38BR3y2eik7e37zU=
</data>
</dict>
<key>Modules/Connectivity.swiftmodule/arm64-apple-ios.swiftmodule</key>
<dict>
<key>hash2</key>
<data>
Et4EI2nA28WHGnFW0ki2IUjCTs703CjwdRvol0loQGo=
S73u4XvAyezKkKReZVBDl16w7MSeeI6FBXUJ9OirCI4=
</data>
</dict>
<key>Modules/module.modulemap</key>

View File

@ -1,7 +0,0 @@
fileFormatVersion: 2
guid: 158f1aee738db4ad8a07a36e89614060
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant: