Compare commits
3 Commits
f1606efad9
...
c89fe09c1a
| Author | SHA1 | Date |
|---|---|---|
|
|
c89fe09c1a | |
|
|
94fd22f534 | |
|
|
2f5914671c |
|
|
@ -180,6 +180,7 @@ namespace WZ
|
||||||
|
|
||||||
private bool IsAdsAvailable(string adUnit, AdsType adsType)
|
private bool IsAdsAvailable(string adUnit, AdsType adsType)
|
||||||
{
|
{
|
||||||
|
if (string.IsNullOrEmpty(adUnit)) return false;
|
||||||
if (adsType == AdsType.Rewarded)
|
if (adsType == AdsType.Rewarded)
|
||||||
{
|
{
|
||||||
if (!_maxRewardedUnits.Contains(adUnit)) return false;
|
if (!_maxRewardedUnits.Contains(adUnit)) return false;
|
||||||
|
|
|
||||||
|
|
@ -10,6 +10,9 @@ using Newtonsoft.Json;
|
||||||
using ThinkingAnalytics;
|
using ThinkingAnalytics;
|
||||||
using ThinkingData.Analytics;
|
using ThinkingData.Analytics;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
#if UNITY_PURCHASE
|
||||||
|
using UnityEngine.Purchasing;
|
||||||
|
#endif
|
||||||
using WZ;
|
using WZ;
|
||||||
|
|
||||||
public class RushSDKManager : D_MonoSingleton<RushSDKManager>
|
public class RushSDKManager : D_MonoSingleton<RushSDKManager>
|
||||||
|
|
@ -36,8 +39,39 @@ public class RushSDKManager : D_MonoSingleton<RushSDKManager>
|
||||||
EFSdkManager.Instance.Init();
|
EFSdkManager.Instance.Init();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if UNITY_PURCHASE
|
||||||
|
#region 支付
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 初始化回调
|
||||||
|
/// </summary>
|
||||||
|
public Action<bool, string> OnPurchaseInitComplete;
|
||||||
|
public void RegisterPurchaseInitHandler(Action<bool,string> _action)
|
||||||
|
{
|
||||||
|
OnPurchaseInitComplete = _action;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 获取 AppStore/Google Play 上所有配置的商品;
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="_action">返回所有商品信息</param>
|
||||||
|
/// ex:
|
||||||
|
/// Product[0].metadata.localizedTitle
|
||||||
|
/// Product[0].metadata.localizedPriceString
|
||||||
|
/// Product[0].metadata.localizedDescription
|
||||||
|
/// Product[0].metadata.isoCurrencyCode
|
||||||
|
public Action<Product[]> OnGetProductsInfo;
|
||||||
|
public void RegisterProductsInfoHandler(Action<Product[]> _action)
|
||||||
|
{
|
||||||
|
OnGetProductsInfo += _action;
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
#endif
|
||||||
|
|
||||||
#region 买量用户回调
|
#region 买量用户回调
|
||||||
|
|
||||||
public Action<bool, string> OnUserSourceListener;
|
public Action<bool, string> OnUserSourceListener;
|
||||||
|
|
||||||
/// Adjust归因回调
|
/// Adjust归因回调
|
||||||
|
|
@ -52,6 +86,7 @@ public class RushSDKManager : D_MonoSingleton<RushSDKManager>
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
||||||
#region 跳转谷歌评价
|
#region 跳转谷歌评价
|
||||||
public void Review()
|
public void Review()
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue