diff --git a/Assets/Plugins/Android/FirebaseCrashlytics.androidlib/res/values/crashlytics_build_id.xml b/Assets/Plugins/Android/FirebaseCrashlytics.androidlib/res/values/crashlytics_build_id.xml
index d5a356f..82d4d98 100644
--- a/Assets/Plugins/Android/FirebaseCrashlytics.androidlib/res/values/crashlytics_build_id.xml
+++ b/Assets/Plugins/Android/FirebaseCrashlytics.androidlib/res/values/crashlytics_build_id.xml
@@ -1 +1 @@
-c45ec7aa-6b06-44f5-a853-c0fb3a4e9252
+9bdc54ad-1cc2-4efd-a721-547163c61c6b
diff --git a/Assets/Plugins/Android/mainTemplate.gradle b/Assets/Plugins/Android/mainTemplate.gradle
index e70570d..1c56998 100644
--- a/Assets/Plugins/Android/mainTemplate.gradle
+++ b/Assets/Plugins/Android/mainTemplate.gradle
@@ -4,16 +4,15 @@ apply plugin: 'com.android.library'
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
// Android Resolver Dependencies Start
- implementation 'androidx.annotation:annotation:1.2.0' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/kwai/Editor/Dependencies.xml:8
- implementation 'androidx.appcompat:appcompat:1.6.1' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/kwai/Editor/Dependencies.xml:6
- implementation 'androidx.browser:browser:1.4.0' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/Editor/Dependencies.xml:4
+ implementation 'androidx.annotation:annotation:1.2.0' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/kwai/Editor/Dependencies.xml:8
+ implementation 'androidx.appcompat:appcompat:1.6.1' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/kwai/Editor/Dependencies.xml:6
+ implementation 'androidx.browser:browser:1.4.0' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/Editor/Dependencies.xml:4
implementation 'androidx.constraintlayout:constraintlayout:2.1.4' // Assets/GoogleMobileAds/Editor/GoogleMobileAdsDependencies.xml:12
implementation 'androidx.lifecycle:lifecycle-process:2.6.2' // Assets/GoogleMobileAds/Editor/GoogleMobileAdsDependencies.xml:17
- implementation 'androidx.media3:media3-exoplayer:1.0.0-alpha01' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/kwai/Editor/Dependencies.xml:5
- // implementation 'androidx.recyclerview:recyclerview:1.1.0' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/gtm/Editor/Dependencies.xml:7
+ implementation 'androidx.media3:media3-exoplayer:1.0.0-alpha01' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/kwai/Editor/Dependencies.xml:5
implementation 'androidx.recyclerview:recyclerview:1.2.1' // Assets/MaxSdk/Mediation/Mintegral/Editor/Dependencies.xml:9
- implementation 'com.adjust.sdk:adjust-android:5.4.2' // Assets/rd3/Adjust/Native/Editor/Dependencies.xml:5
- implementation 'com.android.installreferrer:installreferrer:2.2' // Assets/rd3/Adjust/Native/Editor/Dependencies.xml:7
+ implementation 'com.adjust.sdk:adjust-android:5.4.2' // Assets/Adjust/Native/Editor/Dependencies.xml:5
+ implementation 'com.android.installreferrer:installreferrer:2.2' // Assets/Adjust/Native/Editor/Dependencies.xml:7
implementation 'com.applovin.mediation:bigoads-adapter:5.5.1.2' // Assets/MaxSdk/Mediation/BigoAds/Editor/Dependencies.xml:4
implementation 'com.applovin.mediation:bytedance-adapter:7.5.0.3.0' // Assets/MaxSdk/Mediation/ByteDance/Editor/Dependencies.xml:8
implementation 'com.applovin.mediation:fyber-adapter:8.3.8.0' // Assets/MaxSdk/Mediation/Fyber/Editor/Dependencies.xml:4
@@ -23,33 +22,33 @@ dependencies {
implementation 'com.applovin.mediation:moloco-adapter:4.0.0.0' // Assets/MaxSdk/Mediation/Moloco/Editor/Dependencies.xml:4
implementation 'com.applovin.mediation:unityads-adapter:4.16.1.0' // Assets/MaxSdk/Mediation/UnityAds/Editor/Dependencies.xml:4
implementation 'com.applovin.mediation:vungle-adapter:7.5.1.0' // Assets/MaxSdk/Mediation/Vungle/Editor/Dependencies.xml:4
- implementation 'com.applovin:applovin-sdk:13.3.1' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/applovin/Editor/Dependencies.xml:3
+ // implementation 'com.applovin:applovin-sdk:13.2.0' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/applovin/Editor/Dependencies.xml:3
+ implementation 'com.applovin:applovin-sdk:13.3.1' // Assets/MaxSdk/AppLovin/Editor/Dependencies.xml:4
// implementation 'com.bigossp:bigo-ads:5.0.0' // Assets/BigoSDK/Editor/Dependencies.xml:11
- implementation 'com.bigossp:bigo-ads:5.3.0' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/bigo/Editor/Dependencies.xml:3
- implementation 'com.fyber:marketplace-sdk:8.3.7' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/fyber/Editor/Dependencies.xml:3
- // implementation 'com.google.android.gms:play-services-ads:24.4.0' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/admob/Editor/Dependencies.xml:3
+ implementation 'com.bigossp:bigo-ads:5.3.0' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/bigo/Editor/Dependencies.xml:3
+ implementation 'com.earn.money:sdk:+' // Assets/EFSDK/Editor/Dependencies.xml:10
+ implementation 'com.fyber:marketplace-sdk:8.3.5' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/fyber/Editor/Dependencies.xml:3
+ // implementation 'com.google.android.gms:play-services-ads:24.0.0' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/admob/Editor/Dependencies.xml:3
implementation 'com.google.android.gms:play-services-ads:24.5.0' // Assets/GoogleMobileAds/Editor/GoogleMobileAdsDependencies.xml:7
- // implementation 'com.google.android.gms:play-services-ads-identifier:18.0.1' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/vungle/Editor/Dependencies.xml:5
- implementation 'com.google.android.gms:play-services-ads-identifier:18.2.0' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/pangle/Editor/Dependencies.xml:7
- implementation 'com.google.android.gms:play-services-base:18.7.2' // Assets/rd3/Firebase/Editor/AppDependencies.xml:17
- implementation 'com.google.android.gms:play-services-basement:18.1.0' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/vungle/Editor/Dependencies.xml:4
- implementation 'com.google.android.material:material:1.2.1' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/kwai/Editor/Dependencies.xml:7
+ implementation 'com.google.android.gms:play-services-ads-identifier:18.0.1' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/vungle/Editor/Dependencies.xml:5
+ implementation 'com.google.android.gms:play-services-base:18.7.2' // Assets/Firebase/Editor/AppDependencies.xml:17
+ implementation 'com.google.android.gms:play-services-basement:18.1.0' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/vungle/Editor/Dependencies.xml:4
+ implementation 'com.google.android.material:material:1.2.1' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/kwai/Editor/Dependencies.xml:7
implementation 'com.google.android.ump:user-messaging-platform:3.2.0' // Assets/GoogleMobileAds/Editor/GoogleUmpDependencies.xml:7
- implementation 'com.google.firebase:firebase-analytics:23.0.0' // Assets/rd3/Firebase/Editor/RemoteConfigDependencies.xml:15
- implementation 'com.google.firebase:firebase-analytics-unity:13.1.0' // Assets/rd3/Firebase/Editor/AnalyticsDependencies.xml:18
- implementation 'com.google.firebase:firebase-app-unity:13.1.0' // Assets/rd3/Firebase/Editor/AppDependencies.xml:22
- implementation 'com.google.firebase:firebase-common:22.0.0' // Assets/rd3/Firebase/Editor/AppDependencies.xml:13
- implementation 'com.google.firebase:firebase-config:23.0.0' // Assets/rd3/Firebase/Editor/RemoteConfigDependencies.xml:13
- implementation 'com.google.firebase:firebase-config-unity:13.1.0' // Assets/rd3/Firebase/Editor/RemoteConfigDependencies.xml:20
- implementation 'com.google.firebase:firebase-crashlytics-ndk:20.0.0' // Assets/rd3/Firebase/Editor/CrashlyticsDependencies.xml:13
- implementation 'com.google.firebase:firebase-crashlytics-unity:13.1.0' // Assets/rd3/Firebase/Editor/CrashlyticsDependencies.xml:20
- implementation 'com.mbridge.msdk.oversea:mbridge_android_sdk:16.9.71' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/gtm/Editor/Dependencies.xml:6
- implementation 'com.pangle.global:pag-sdk:7.2.0.6' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/pangle/Editor/Dependencies.xml:6
- implementation 'com.unity3d.ads:unity-ads:4.14.0' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/unityads/Editor/Dependencies.xml:3
- implementation 'com.vungle:vungle-ads:7.5.0' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/vungle/Editor/Dependencies.xml:3
- implementation 'io.github.kwainetwork:adApi:1.2.19' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/kwai/Editor/Dependencies.xml:3
- implementation 'io.github.kwainetwork:adImpl:1.2.19' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/kwai/Editor/Dependencies.xml:4
- implementation 'org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.4.10' // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/kwai/Editor/Dependencies.xml:9
+ implementation 'com.google.firebase:firebase-analytics:23.0.0' // Assets/Firebase/Editor/RemoteConfigDependencies.xml:15
+ implementation 'com.google.firebase:firebase-analytics-unity:13.1.0' // Assets/Firebase/Editor/AnalyticsDependencies.xml:18
+ implementation 'com.google.firebase:firebase-app-unity:13.1.0' // Assets/Firebase/Editor/AppDependencies.xml:22
+ implementation 'com.google.firebase:firebase-common:22.0.0' // Assets/Firebase/Editor/AppDependencies.xml:13
+ implementation 'com.google.firebase:firebase-config:23.0.0' // Assets/Firebase/Editor/RemoteConfigDependencies.xml:13
+ implementation 'com.google.firebase:firebase-config-unity:13.1.0' // Assets/Firebase/Editor/RemoteConfigDependencies.xml:20
+ implementation 'com.google.firebase:firebase-crashlytics-ndk:20.0.0' // Assets/Firebase/Editor/CrashlyticsDependencies.xml:13
+ implementation 'com.google.firebase:firebase-crashlytics-unity:13.1.0' // Assets/Firebase/Editor/CrashlyticsDependencies.xml:20
+ implementation 'com.pangle.global:pag-sdk:7.2.0.6' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/pangle/Editor/Dependencies.xml:6
+ implementation 'com.unity3d.ads:unity-ads:4.14.0' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/unityads/Editor/Dependencies.xml:3
+ implementation 'com.vungle:vungle-ads:7.4.3' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/vungle/Editor/Dependencies.xml:3
+ implementation 'io.github.kwainetwork:adApi:1.2.15' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/kwai/Editor/Dependencies.xml:3
+ implementation 'io.github.kwainetwork:adImpl:1.2.15' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/kwai/Editor/Dependencies.xml:4
+ implementation 'org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.4.10' // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/kwai/Editor/Dependencies.xml:9
// Android Resolver Dependencies End
**DEPS**}
diff --git a/Assets/Plugins/Android/settingsTemplate.gradle b/Assets/Plugins/Android/settingsTemplate.gradle
index 6d2a719..c5599a0 100644
--- a/Assets/Plugins/Android/settingsTemplate.gradle
+++ b/Assets/Plugins/Android/settingsTemplate.gradle
@@ -19,19 +19,28 @@ dependencyResolutionManagement {
// Android Resolver Repos Start
def unityProjectPath = $/file:///**DIR_UNITYPROJECT**/$.replace("\\", "/")
maven {
- url "https://dl-maven-android.mintegral.com/repository/mbridge_android_sdk_oversea" // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/gtm/Editor/Dependencies.xml:5, Assets/MaxSdk/Mediation/Mintegral/Editor/Dependencies.xml:8
- }
- maven {
- url "https://artifact.bytedance.com/repository/pangle" // Assets/rd3/ShuShu/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/pangle/Editor/Dependencies.xml:5, Assets/MaxSdk/Mediation/ByteDance/Editor/Dependencies.xml:8
+ url "https://artifact.bytedance.com/repository/pangle" // Assets/ThinkupTpnPlugin/AnyThinkAds/Plugins/Android/NonChina/mediation/pangle/Editor/Dependencies.xml:5, Assets/MaxSdk/Mediation/ByteDance/Editor/Dependencies.xml:8
}
maven {
url "https://repo1.maven.org/maven2/" // Assets/BigoSDK/Editor/Dependencies.xml:11
}
+ maven {
+ url "https://repo.dgtverse.cn/repository/maven-public/" // Assets/EFSDK/Editor/Dependencies.xml:10
+ }
+ maven {
+ url (unityProjectPath + "/Assets/GeneratedLocalRepo/Firebase/m2repository") // Assets/Firebase/Editor/AnalyticsDependencies.xml:18, Assets/Firebase/Editor/AppDependencies.xml:22, Assets/Firebase/Editor/CrashlyticsDependencies.xml:20, Assets/Firebase/Editor/RemoteConfigDependencies.xml:20
+ }
maven {
url "https://maven.google.com/" // Assets/GoogleMobileAds/Editor/GoogleMobileAdsDependencies.xml:7, Assets/GoogleMobileAds/Editor/GoogleMobileAdsDependencies.xml:12, Assets/GoogleMobileAds/Editor/GoogleMobileAdsDependencies.xml:17, Assets/GoogleMobileAds/Editor/GoogleUmpDependencies.xml:7
}
maven {
- url (unityProjectPath + "/Assets/Firebase/m2repository") // Assets/rd3/Firebase/Editor/AnalyticsDependencies.xml:18, Assets/rd3/Firebase/Editor/AppDependencies.xml:22, Assets/rd3/Firebase/Editor/CrashlyticsDependencies.xml:20, Assets/rd3/Firebase/Editor/RemoteConfigDependencies.xml:20
+ url "https://dl-maven-android.mintegral.com/repository/mbridge_android_sdk_oversea" // Assets/MaxSdk/Mediation/Mintegral/Editor/Dependencies.xml:8, Assets/EFSDK/Editor/Dependencies.xml:10
+ }
+ maven {
+ url "https://android-sdk.is.com/" // Assets/EFSDK/Editor/Dependencies.xml:10
+ }
+ maven {
+ url "https://artifact.bytedance.com/repository/pangle/" // Assets/EFSDK/Editor/Dependencies.xml:10
}
mavenLocal()
// Android Resolver Repos End
diff --git a/Assets/Script/SDKManager/AppSDKManager.cs b/Assets/Script/SDKManager/AppSDKManager.cs
index aafc3ff..593c1cb 100644
--- a/Assets/Script/SDKManager/AppSDKManager.cs
+++ b/Assets/Script/SDKManager/AppSDKManager.cs
@@ -1,6 +1,8 @@
using System;
using System.Collections;
using System.Collections.Generic;
+using EFSDK;
+using Firebase.RemoteConfig;
using Script.Common;
using Script.SDKManager.AdsSDKManager.Constant;
using Script.Utils;
@@ -21,6 +23,7 @@ public class AppSDKManager : MonoBehaviour
AdjustManager.Instance.Init();
ShuShuMangage.Instance.Init();
AdsSDKManager.Instance.InitSDK();
+ EFSdkManager.Instance.Init();
}
///
@@ -71,4 +74,411 @@ public class AppSDKManager : MonoBehaviour
});
}
}
+
+
+ #region EFSDK
+
+ ///
+ /// 展示WebView
+ ///
+ /// 标签id,存在多个WebView时,用于标识WebView
+ /// 网址
+ /// WebView展示区域的RectTransform
+ /// 可不传;传值的话要传正交相机
+ public void ShowWebView(int id, string url, RectTransform pRect, Camera pCam = null)
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().ShowWebView(id, url, pRect, pCam);
+ }
+
+ ///
+ /// 移除所有原生WebView, 回到游戏时调用
+ ///
+ ///
+ public void RemoveAll()
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().RemoveAll();
+ }
+
+ ///
+ /// 刷新当前页面
+ ///
+ ///
+ public void Refresh()
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().Refresh();
+ }
+
+ ///
+ /// 回上一页
+ ///
+ ///
+ public void GoBack()
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().CanGoback((IsGoback) =>
+ {
+ if (IsGoback)
+ {
+ EFSdk.get().GoBack();
+ }
+ });
+ }
+
+ ///
+ /// 是否手动控制漂浮道具显示/隐藏
+ /// SDK内默认当H5页面加载完成后自动显示漂浮道具
+ ///
+ /// true: 自动显示/隐藏道具 false: 游戏主动控制道具显示/隐藏
+ ///
+ public void AutoShowFloat(bool autoShow)
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().AutoShowFloat(false);
+ }
+
+ ///
+ /// 新增接口飘金币
+ ///
+ ///
+ /// 悬浮金币按钮的图片资源,传字符串 0 或 1 0:金币图 1:红点宝箱图
+ ///
+ public void ShowFloatCoin(String res)
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ var remoteConfig = FireBaseRemoteConfigManager.Instance.GetRemoteConfigInt("coin_position", 3);
+ if (remoteConfig <= 0)
+ {
+ remoteConfig = 3;
+ }
+ if (remoteConfig > 10)
+ {
+ remoteConfig = 3;
+ }
+ EFSdk.get().SetFloatCoinRes(res);
+ EFSdk.get().ShowFloatCoin(remoteConfig);
+ }
+
+ ///
+ /// 隐藏金币
+ ///
+ ///
+ public void HideFloatCoin()
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().HideFloatCoin();
+ }
+
+ /// 宝箱动画起始位置
+ /// 宝箱动画移动结束位置
+ /// 首次delay时间
+ /// 每次漂浮移动的时间间隔
+ ///
+ public void ShowBalloon(int startId, int endId, int fly_first_time, int fly_gap_time)
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ var startFlyIndex = FireBaseRemoteConfigManager.Instance.GetRemoteConfigInt("start_fly", 40);
+ var endFlyIndex = FireBaseRemoteConfigManager.Instance.GetRemoteConfigInt("end_fly", 60);
+ var flyFirstTime = FireBaseRemoteConfigManager.Instance.GetRemoteConfigInt("fly_first_time", 3);
+ var flyGapTime = FireBaseRemoteConfigManager.Instance.GetRemoteConfigInt("fly_gap_time", 15);
+ EFSdk.get().ShowBalloon(startFlyIndex, endFlyIndex, flyFirstTime, flyGapTime);
+ }
+
+ ///
+ /// 隐藏气球
+ ///
+ ///
+ public void HideBalloon()
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().HideBalloon();
+ }
+
+ ///
+ /// 设置推送开关, SDK默认关闭通知
+ ///
+ ///
+ public void SetPushSwitch(bool isOpen)
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().SetPushSwitch(isOpen);
+ }
+
+ ///
+ /// 向SDK上报当前金币总数,每次金币变化都要调用一次
+ ///
+ ///
+ public void SendTotalGold2SDK(int totalGold)
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().SendTotalGold2SDK(totalGold);
+ }
+
+ ///
+ /// 向SDK上报当前要提现的现金额,每次变化都要调用一次
+ ///
+ ///
+ public void SendCashNum2SDK(double cashNum)
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().SendCashNum2SDK(cashNum);
+ }
+
+ ///
+ /// 向SDK上报 游戏名字(当前语言的),每次语言变化都上报
+ ///
+ ///
+ public void SetGameName(string gameName)
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().SetGameName(gameName);
+ }
+
+ ///
+ /// 设置当前游戏语言是否是 巴西语
+ ///
+ ///
+ /// 巴西语传 true, 其他的都传 false
+ public void SetCurrLang(bool isPT)
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().SetCurrLang(isPT);
+ }
+
+ ///
+ /// 消息类通知弹出间隔,SDK默认设置为60秒(在线参数控制)-Key: messagenotif Value:60
+ ///
+ ///
+ public void SetPushMessagenotif()
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ int timeSeconds = FireBaseRemoteConfigManager.Instance.GetRemoteConfigInt("messagenotif", 60);
+ EFSdk.get().SetPushMessagenotif(timeSeconds);
+ }
+
+ ///
+ /// 持续性通知在进入游戏时弹出的时间间隔,SDK默认设置为300秒(在线参数控制 )-Key:persistentnotif Value:300
+ ///
+ ///
+ public void SetPushPersistentnotif()
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ int timeSeconds = FireBaseRemoteConfigManager.Instance.GetRemoteConfigInt("persistentnotif", 300);
+ EFSdk.get().SetPushPersistentnotif(timeSeconds);
+ }
+
+ ///
+ /// 每次回调游戏的onResume的时候都调用一次,获取游戏要跳转的页面
+ ///
+ ///
+ /// 0 不需要进行任何跳转
+ /// 1 进行游戏主页
+ /// 2 进入游戏的金币提现界面
+ /// 3 进入对应小游戏1界面
+ /// 4 进入对应小游戏2界面
+ ///
+ public void GetJumpPage()
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ int pageId = EFSdk.get().GetJumpPage();
+ switch (pageId)
+ {
+ case 0:
+ // Nothing to do
+ break;
+ case 1:
+ // 回到游戏主页
+ break;
+ case 2:
+ // 进入游戏的金币提现界面
+ break;
+ case 3:
+ // 进入对应小游戏1界面
+ break;
+ case 4:
+ // 进入对应小游戏2界面
+ break;
+ }
+ }
+
+ ///
+ /// 获取当前是否有通知权限
+ ///
+ public bool HasNotifyPermission()
+ {
+ if (Application.isEditor)
+ {
+ return false;
+ }
+ return EFSdk.get().HasNotifyPermission();
+ }
+
+ ///
+ /// 请求获取通知权限
+ /// 授权弹窗关闭回调 bool:表示用户是否允许了权限 true:有权限 false:无权限
+ ///
+ public void ReqNotifyPermission(Action action)
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ // 如果没有通知权限就尝试申请通知权限
+ if(!HasNotifyPermission())
+ {
+ EFSdk.get().ReqNotifyPermission(isgGranted =>
+ {
+ //收到回调之后,可以认为权限申请弹窗弹出来了
+ if (isgGranted)
+ {
+ //用户已同意授权
+ }
+ else
+ {
+ //用户拒绝了授权
+ }
+ });
+ }
+ }
+
+ ///
+ /// 满足条件:未领取 R$0.1 的 买量用户, 调用这个方法
+ ///
+ public void SubscribeUnclaimed01()
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().SubscribeUnclaimed01();
+ }
+
+ ///
+ /// 不满足条件:未领取 R$0.1 的 买量用户, 调用这个方法
+ ///
+ public void UnSubscribeUnclaimed01()
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().UnSubscribeUnclaimed01();
+ }
+
+ ///
+ // 满足条件: 在排队中 且 当日R$1 未领取 的买量用户, 调用这个方法
+ ///
+ public void SubscribePending1()
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().SubscribePending1();
+ }
+
+ ///
+ /// 不满足条件: 在排队中 且 当日R$1 未领取 的买量用户, 调用这个方法
+ ///
+ public void UnSubscribePending1()
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().UnSubscribePending1();
+ }
+
+ ///
+ /// 订阅Firebase推送主题
+ ///
+ /// 主题名称
+ public void SubscribeToTopic(string topic)
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().SubscribeToTopic(topic);
+ }
+
+ /// 取消订阅Firebase推送主题
+ ///
+ /// 主题名称
+ public void UnSubscribeToTopic(string topic)
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().UnSubscribeToTopic(topic);
+ }
+
+ ///
+ /// 可覆盖广告的Toast
+ ///
+ ///
+ public void ShowToast(string message)
+ {
+ if (Application.isEditor)
+ {
+ return;
+ }
+ EFSdk.get().ShowToast(message);
+ }
+
+ #endregion
}
diff --git a/Assets/Script/SDKManager/EFSdkManager.meta b/Assets/Script/SDKManager/EFSdkManager.meta
new file mode 100644
index 0000000..58efc9a
--- /dev/null
+++ b/Assets/Script/SDKManager/EFSdkManager.meta
@@ -0,0 +1,3 @@
+fileFormatVersion: 2
+guid: 7c64ea7790054a1ab434ca0de1bb2652
+timeCreated: 1756711229
\ No newline at end of file
diff --git a/Assets/Script/SDKManager/EFSdkManager/EFSdkManager.cs b/Assets/Script/SDKManager/EFSdkManager/EFSdkManager.cs
new file mode 100644
index 0000000..1379b17
--- /dev/null
+++ b/Assets/Script/SDKManager/EFSdkManager/EFSdkManager.cs
@@ -0,0 +1,46 @@
+using EFSDK;
+using Firebase.Analytics;
+using Script.Utils;
+using UnityEngine;
+
+public class EFSdkManager : NormalSingleton
+{
+ public void Init()
+ {
+ EFSdk.get().Init((actionType, str) =>
+ {
+ if (EFSdk.ActionType.COIN_CLICK == actionType)
+ {
+ //TOTO 游戏在此处理 点击金币弹广告的逻辑或其他
+ }
+ if (EFSdk.ActionType.BALLOON_CLICK == actionType)
+ {
+ //TOTO 游戏在此处理 点击宝箱弹广告的逻辑或其他
+ }
+ if (EFSdk.ActionType.COIN_SHOW == actionType)
+ {
+
+ }
+ if (EFSdk.ActionType.BOX_SHOW == actionType)
+ {
+
+ }
+ if (EFSdk.ActionType.GAM_LOAD_SUCC == actionType)
+ {
+ // 标签id,标识哪个WebView加载成功了
+ int id = int.Parse(str);
+ }
+ });
+
+ SetSDKEventCallback();
+ }
+
+ private void SetSDKEventCallback()
+ {
+ EFSdk.get().SetSDKEventCallback((eventName, dict) =>
+ {
+ FireBaseAnalyticsManager.Instance.LogEvent(eventName, dict);
+ ShuShuEvent.Instance.Track(eventName, dict);
+ });
+ }
+}
\ No newline at end of file
diff --git a/Assets/Script/SDKManager/EFSdkManager/EFSdkManager.cs.meta b/Assets/Script/SDKManager/EFSdkManager/EFSdkManager.cs.meta
new file mode 100644
index 0000000..5103b7d
--- /dev/null
+++ b/Assets/Script/SDKManager/EFSdkManager/EFSdkManager.cs.meta
@@ -0,0 +1,3 @@
+fileFormatVersion: 2
+guid: 112b724762024ad5946af4fe967ee073
+timeCreated: 1756711246
\ No newline at end of file
diff --git a/Assets/Script/SDKManager/FirebaseManager/FireBaseAnalyticsManager.cs b/Assets/Script/SDKManager/FirebaseManager/FireBaseAnalyticsManager.cs
index 0938c1b..f5f1f0f 100644
--- a/Assets/Script/SDKManager/FirebaseManager/FireBaseAnalyticsManager.cs
+++ b/Assets/Script/SDKManager/FirebaseManager/FireBaseAnalyticsManager.cs
@@ -1,4 +1,5 @@
+using System.Collections.Generic;
using Firebase.Analytics;
using Newtonsoft.Json;
using Script.Common;
@@ -40,6 +41,17 @@ public class FireBaseAnalyticsManager : NormalSingleton dict)
+ {
+ List parameters = new List();
+ foreach (var item in dict)
+ {
+ Parameter parameter = new Parameter(item.Key, item.Value);
+ parameters.Add(parameter);
+ }
+ Firebase.Analytics.FirebaseAnalytics.LogEvent(eventName, parameters.ToArray());
+ }
///
/// 设置用户属性
diff --git a/Assets/Script/SDKManager/FirebaseManager/FireBaseSDKManager.cs b/Assets/Script/SDKManager/FirebaseManager/FireBaseSDKManager.cs
index f1bed22..d09b427 100644
--- a/Assets/Script/SDKManager/FirebaseManager/FireBaseSDKManager.cs
+++ b/Assets/Script/SDKManager/FirebaseManager/FireBaseSDKManager.cs
@@ -8,8 +8,6 @@ using UnityEngine;
public class FireBaseSDKManager : NormalSingleton
{
- public bool IsInit {private set; get; }
-
public void Init()
{
InitSDK();
diff --git a/Assets/Script/SDKManager/ShuShuMangage/ShuShuEvent.cs b/Assets/Script/SDKManager/ShuShuMangage/ShuShuEvent.cs
index cad0c20..38783cb 100644
--- a/Assets/Script/SDKManager/ShuShuMangage/ShuShuEvent.cs
+++ b/Assets/Script/SDKManager/ShuShuMangage/ShuShuEvent.cs
@@ -1,4 +1,5 @@
using System.Collections.Generic;
+using System.Linq;
using Script.Utils;
using ThinkingData.Analytics;
@@ -36,7 +37,18 @@ public class ShuShuEvent : NormalSingleton
{
TDAnalytics.Track(eventName, properties);
}
-
+
+ ///
+ /// 发送事件
+ ///
+ public void Track(string eventName, Dictionary properties)
+ {
+ var newProperties = properties.ToDictionary(
+ pair => pair.Key,
+ pair => (object)pair.Value
+ );
+ TDAnalytics.Track(eventName, newProperties);
+ }
///
/// 数数收益上报
diff --git a/Assets/StreamingAssets/google-services-desktop.json.meta b/Assets/StreamingAssets/google-services-desktop.json.meta
index e036ee7..18ad4c3 100644
--- a/Assets/StreamingAssets/google-services-desktop.json.meta
+++ b/Assets/StreamingAssets/google-services-desktop.json.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: b218769dd2f8e41f3a8821896e5a13ef
+guid: 26462fea0f177a5498e4d2cf5671c30a
TextScriptImporter:
externalObjects: {}
userData: