瀏覽代碼

接入TalkingData

lzx 16 小時之前
父節點
當前提交
f01baa0d17
共有 40 個文件被更改,包括 3663 次插入163 次删除
  1. 12 1
      Assets/Plugins/Android/AndroidManifest.xml
  2. 二進制
      Assets/Plugins/Android/SaaS_TalkingDataSDK_Android_V5.0.35.jar
  3. 37 0
      Assets/Plugins/Android/SaaS_TalkingDataSDK_Android_V5.0.35.jar.meta
  4. 371 0
      Assets/Plugins/iOS/TalkingDataSDK.h
  5. 33 0
      Assets/Plugins/iOS/TalkingDataSDK.h.meta
  6. 二進制
      Assets/Plugins/iOS/libTalkingDataSDK.a
  7. 33 0
      Assets/Plugins/iOS/libTalkingDataSDK.a.meta
  8. 1 1
      Assets/Res/UI/MainPanel/CheckBoxPanel.prefab.meta
  9. 1 1
      Assets/Res/UI/SettingPanel/Btn_Audio.prefab.meta
  10. 1 1
      Assets/Res/UI/SettingPanel/SettingPanel.prefab.meta
  11. 95 95
      Assets/Scenes/testCombat.scene
  12. 2 1
      Assets/Scripts/GameLogic/Fort23.GameLogic.asmdef
  13. 1 1
      Assets/Scripts/GameLogic/Hero/HeroInfo.cs
  14. 8 4
      Assets/Scripts/GameLogic/SDK/DBManager.cs
  15. 104 0
      Assets/Scripts/GameLogic/SDK/TalkingDataManager.cs
  16. 11 0
      Assets/Scripts/GameLogic/SDK/TalkingDataManager.cs.meta
  17. 5 3
      Assets/Scripts/GameUI/GameApplction.cs
  18. 8 0
      Assets/Scripts/ThirdParty/TalkingDataScripts.meta
  19. 400 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TDDemoScript.cs
  20. 11 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TDDemoScript.cs.meta
  21. 71 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataOrder.cs
  22. 11 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataOrder.cs.meta
  23. 468 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataProfile.cs
  24. 11 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataProfile.cs.meta
  25. 1066 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataSDK.cs
  26. 11 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataSDK.cs.meta
  27. 80 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataSDKConfig.cs
  28. 11 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataSDKConfig.cs.meta
  29. 210 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataSearch.cs
  30. 11 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataSearch.cs.meta
  31. 63 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataShoppingCart.cs
  32. 11 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataShoppingCart.cs.meta
  33. 220 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataTransaction.cs
  34. 11 0
      Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataTransaction.cs.meta
  35. 0 0
      Assets/StreamingAssets/assetConfig.txt
  36. 1 1
      Assets/StreamingAssets/assetMD5.txt
  37. 1 1
      ProjectSettings/HybridCLRSettings.asset
  38. 2 2
      ProjectSettings/ProjectSettings.asset
  39. 269 51
      UserSettings/Layouts/default-2022.dwlt
  40. 1 0
      XiuXianGame.sln.DotSettings.user

+ 12 - 1
Assets/Plugins/Android/AndroidManifest.xml

@@ -6,17 +6,28 @@
     <uses-permission android:name="android.permission.INTERNET"/>
     <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
     <uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
+    <uses-permission android:name="android.permission.READ_PHONE_STATE"/>
+    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
+    <supports-screens
+            android:smallScreens="true"
+            android:normalScreens="true"
+            android:largeScreens="true"
+            android:xlargeScreens="true"
+            android:anyDensity="true"/>
     <application>
         <meta-data
                 android:name="Crasheye_appkey"
                 android:value="sm0zzhed" />
         <activity android:name="com.taptap.xy.yousanjie.MainActivity"
-                  android:theme="@style/TuanjieThemeSelector">
+                  android:theme="@style/TuanjieThemeSelector"
+                  android:configChanges="fontScale|keyboard|keyboardHidden|locale|mnc|mcc|navigation|orientation|screenLayout|screenSize|smallestScreenSize|uiMode|touchscreen">>
             <intent-filter>
                 <action android:name="android.intent.action.MAIN" />
                 <category android:name="android.intent.category.LAUNCHER" />
             </intent-filter>
             <meta-data android:name="unityplayer.UnityActivity" android:value="true" />
+            <meta-data android:name="android.app.lib_name" android:value="unity"/>
+            <meta-data android:name="unityplayer.ForwardNativeEventsToDalvik" android:value="false"/>
         </activity>
     </application>
 </manifest>

二進制
Assets/Plugins/Android/SaaS_TalkingDataSDK_Android_V5.0.35.jar


+ 37 - 0
Assets/Plugins/Android/SaaS_TalkingDataSDK_Android_V5.0.35.jar.meta

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

+ 371 - 0
Assets/Plugins/iOS/TalkingDataSDK.h

@@ -0,0 +1,371 @@
+//
+//  TalkingDataSDK.h
+//  TalkingData
+//
+//  Created by liweiqiang on 21-03-16.
+//  Copyright (c) 2021年 TendCloud. All rights reserved.
+//
+
+#import <Foundation/Foundation.h>
+
+
+typedef NS_OPTIONS(NSUInteger, TalkingDataDisable) {
+    TalkingDataDisablePreciseArea           = 1 << 0,
+    TalkingDataDisableAnalyticsIntellignet  = 1 << 1,
+    TalkingDataDisableDeviceIdentification  = 1 << 2,
+    TalkingDataDisableAntiCheating          = 1 << 3,
+};
+
+typedef NS_ENUM(NSUInteger, TalkingDataVendorIdType) {
+    TalkingDataVendorIdTypeZX           = 1,    // 卓信
+    TalkingDataVendorIdTypeGX           = 2,    // 广协
+};
+
+typedef NS_ENUM(NSInteger, TalkingDataSharingFilter) {
+    TalkingDataSharingFilterShare       = 0,    // 可共享
+    TalkingDataSharingFilterOnlyInstall = 1,    // 仅共享Install事件
+    TalkingDataSharingFilterUnshare     = 2,    // 不可共享
+};
+
+typedef NS_ENUM(NSUInteger, TalkingDataProfileType) {
+    TalkingDataProfileTypeAnonymous     = 0,    // 匿名账户
+    TalkingDataProfileTypeRegistered    = 1,    // 显性注册账户
+    TalkingDataProfileTypeSinaWeibo     = 2,    // 新浪微博
+    TalkingDataProfileTypeQQ            = 3,    // QQ账户
+    TalkingDataProfileTypeQQWeibo       = 4,    // 腾讯微博
+    TalkingDataProfileTypeND91          = 5,    // 91账户
+    TalkingDataProfileTypeWeiXin        = 6,    // 微信
+    TalkingDataProfileTypeType1         = 11,   // 自定义类型1
+    TalkingDataProfileTypeType2         = 12,   // 自定义类型2
+    TalkingDataProfileTypeType3         = 13,   // 自定义类型3
+    TalkingDataProfileTypeType4         = 14,   // 自定义类型4
+    TalkingDataProfileTypeType5         = 15,   // 自定义类型5
+    TalkingDataProfileTypeType6         = 16,   // 自定义类型6
+    TalkingDataProfileTypeType7         = 17,   // 自定义类型7
+    TalkingDataProfileTypeType8         = 18,   // 自定义类型8
+    TalkingDataProfileTypeType9         = 19,   // 自定义类型9
+    TalkingDataProfileTypeType10        = 20,   // 自定义类型10
+};
+
+typedef NS_ENUM(NSUInteger, TalkingDataGender) {
+    TalkingDataGenderUnknown            = 0,    // 未知
+    TalkingDataGenderMale               = 1,    // 男
+    TalkingDataGenderFemale             = 2,    // 女
+};
+
+
+@interface TalkingDataProfile : NSObject
+
++ (TalkingDataProfile *)createProfile;
+
+// 账户名称
+@property (nonatomic, strong) NSString *name;
+// 账户类型
+@property (nonatomic, assign) TalkingDataProfileType type;
+// 用户性别
+@property (nonatomic, assign) TalkingDataGender gender;
+// 用户年龄
+@property (nonatomic, assign) int age;
+
+// 自定义属性1-10,类型为NSString或NSNumber
+@property (nonatomic, strong) id property1;
+@property (nonatomic, strong) id property2;
+@property (nonatomic, strong) id property3;
+@property (nonatomic, strong) id property4;
+@property (nonatomic, strong) id property5;
+@property (nonatomic, strong) id property6;
+@property (nonatomic, strong) id property7;
+@property (nonatomic, strong) id property8;
+@property (nonatomic, strong) id property9;
+@property (nonatomic, strong) id property10;
+
+@end
+
+
+@interface TalkingDataSearch : NSObject
+
++ (TalkingDataSearch *)createSearch;
+
+// 搜索类别
+@property (nonatomic, strong) NSString *category;
+// 搜索内容
+@property (nonatomic, strong) NSString *content;
+
+
+
+@end
+
+
+
+
+
+
+@interface TalkingDataSDK : NSObject
+
+/**
+ *  获取TalkingData分配的设备ID
+ *  @return deviceId        设备的ID
+ */
++ (NSString *)getDeviceId;
+
+/**
+ *  设置不显示日志。如发布时不需显示日志,应当最先调用该接口。
+ */
++ (void)setVerboseLogDisable;
+
+/**
+ *  设置关闭配置
+ */
++ (void)setConfigurationDisable:(TalkingDataDisable)options;
+
+
+
+/**
+ *  开启后台使用时长统计,需在SDK初始化之前调用。
+ */
++ (void)backgroundSessionEnabled;
+
+#if TARGET_OS_IOS
+/**
+ *  用于精准的追踪以Safari作为资源载体的广告来源,如果需要使用应当在init接口之前调用。
+ */
++ (void)enableSFSafariViewControllerTracking API_DEPRECATED("此接口会影响到用户交互,使用前请确保和产品、业务沟通清楚!", ios(1, 1));
+#endif
+
+/**
+ *  此接口已废弃,请调用'initSDK'和'startA'接口,详细说明请见官网集成文档。
+ */
++ (void)init:(NSString *)appId channelId:(NSString *)channelId custom:(NSString *)custom NS_UNAVAILABLE;
+
+/**
+ *  SDK初始化接口,仅会执行SDK初始化,不会进行任何信息采集。
+ *  请在application:didFinishLaunchingWithOptions:中调用
+ *  @param  appId           应用的唯一标识,统计后台注册得到
+ *  @param  channelId       渠道名(可选)。如“AppStore”
+ *  @param  custom          自定义参数(可选)。
+ */
++ (void)initSDK:(NSString *)appId channelId:(NSString *)channelId custom:(NSString *)custom;
+
+/**
+ *  SDK启动分析,基础数据准备。
+ */
++ (void)startA;
+
+/**
+ *  设置第三方的ID
+ *  @param  vendorId        第三方的ID
+ *  @param  type            ID的提供方
+ */
++ (void)setVendorId:(NSString *)vendorId ofType:(TalkingDataVendorIdType)type;
+
+/**
+ *  设置位置信息
+ *  @param  latitude        纬度
+ *  @param  longitude       经度
+ */
++ (void)setLatitude:(double)latitude longitude:(double)longitude;
+
+/**
+ *  设置自定义数据是否可共享
+ *  @param flag             是否可共享
+ */
++ (void)setCustomDataSwitch:(TalkingDataSharingFilter)flag;
+
+#if TARGET_OS_IOS
+/**
+ *  是否捕捉程序崩溃记录
+ *  如果需要记录程序崩溃日志,请将值设成YES,并且在初始化后尽早调用
+ *  @param  enable          默认NO
+ */
++ (void)setExceptionReportEnabled:(BOOL)enable;
+
+/**
+ *  是否捕捉异常信号
+ *  如果需要开启异常信号捕捉功能,请将值设成YES,并且在初始化后尽早调用
+ *  @param  enable          默认NO
+ */
++ (void)setSignalReportEnabled:(BOOL)enable;
+#endif
+
+/**
+ *  开始跟踪某一页面,记录页面打开时间
+ *  建议在viewWillAppear或者viewDidAppear中调用
+ *  @param  pageName        页面名称
+ */
++ (void)onPageBegin:(NSString *)pageName;
+
+/**
+ *  结束某一页面的跟踪,记录页面的关闭时间
+ *  此接口与onPageBegin接口结对使用
+ *  建议在viewWillDisappear或者viewDidDisappear中调用
+ *  @param  pageName        页面名称,请跟onPageBegin接口的页面名称保持一致
+ */
++ (void)onPageEnd:(NSString *)pageName;
+
+/**
+ *  获取短链
+ *  @param  params          生成短链所参数
+ *  @param  callback        返回结果
+ */
++ (void)getShortUrl:(NSDictionary *)params callback:(void (^)(NSString *shortUrl))callback;
+
+#if TARGET_OS_IOS
+/**
+ *  获取延时链接
+ */
++ (NSString *)getDeferredLink;
+#endif
+
+/**
+ *  处理UniversalLink
+ *  @param  userActivity    获取到的NSUserActivity对象
+ *  @return deeplink        深度链接
+ */
++ (NSString *)handleUniversalLink:(NSUserActivity *)userActivity;
+
+/**
+ *  唤醒事件
+ *  @param  link            唤醒链接
+ */
++ (void)onReceiveDeepLink:(NSURL *)link;
+
+/**
+ *  注册
+ *  @param  profileId       账户ID
+ *  @param  profile         账户属性
+ *  @param  invitationCode  邀请码
+ *  @param  eventValue      用户自定义事件参数
+ */
++ (void)onRegister:(NSString *)profileId profile:(TalkingDataProfile *)profile invitationCode:(NSString *)invitationCode eventValue:(NSDictionary *)eventValue;
++ (void)onRegister:(NSString *)profileId profile:(TalkingDataProfile *)profile invitationCode:(NSString *)invitationCode;
+
+/**
+ *  登录
+ *  @param  profileId       账户ID
+ *  @param  profile         账户属性
+ *  @param  eventValue      用户自定义事件参数
+ */
++ (void)onLogin:(NSString *)profileId profile:(TalkingDataProfile *)profile eventValue:(NSDictionary *)eventValue;
++ (void)onLogin:(NSString *)profileId profile:(TalkingDataProfile *)profile;
+
+/**
+ *  更新账户信息
+ *  @param  profile         账户属性
+ */
++ (void)onProfileUpdate:(TalkingDataProfile *)profile;
+
+/**
+ *  添加支付信息
+ *  @param  profileId       账户ID
+ *  @param  method          支付方式
+ *  @param  content         支付信息
+ */
++ (void)onCreateCard:(NSString *)profileId method:(NSString *)method content:(NSString *)content;
+
+/**
+ *  收藏
+ *  @param  category        收藏类别
+ *  @param  content         收藏内容
+ *  @param  eventValue      用户自定义事件参数
+ */
++ (void)onFavorite:(NSString *)category content:(NSString *)content eventValue:(NSDictionary *)eventValue;
++ (void)onFavorite:(NSString *)category content:(NSString *)content;
+
+/**
+ *  分享
+ *  @param  profileId       账户ID
+ *  @param  content         分享内容
+ *  @param  eventValue      用户自定义事件参数
+ */
++ (void)onShare:(NSString *)profileId content:(NSString *)content eventValue:(NSDictionary *)eventValue;
++ (void)onShare:(NSString *)profileId content:(NSString *)content;
+
+/**
+ *  签到打卡
+ *  @param  profileId       账户ID
+ *  @param  punchId         签到打卡ID
+ */
++ (void)onPunch:(NSString *)profileId punchId:(NSString *)punchId;
+
+/**
+ *  搜索事件
+ *  @param  search          搜索信息详情
+ */
++ (void)onSearch:(TalkingDataSearch *)search;
+
+
+/**
+ *  付费
+ *  @param  profileId       账户ID
+ *  @param  orderId         订单ID
+ *  @param  amount          订单金额
+ *  @param  currencyType    货币类型
+ *  @param  paymentType     支付类型
+ *  @param  itemId          商品ID
+ *  @param  itemCount       商品个数
+ */
++ (void)onPay:(NSString *)profileId orderId:(NSString *)orderId amount:(int)amount currencyType:(NSString *)currencyType paymentType:(NSString *)paymentType itemId:(NSString *)itemId itemCount:(int)itemCount;
+
+
+
+
+
+
+/**
+ *  创建角色
+ *  @param  name            角色名称
+ */
++ (void)onCreateRole:(NSString *)name;
+
+/**
+ *  通过关卡
+ *  @param  profileId       账户ID
+ *  @param  levelId         关卡ID
+ */
++ (void)onLevelPass:(NSString *)profileId levelId:(NSString *)levelId;
+
+/**
+ *  完成新手教程
+ *  @param  profileId       账户ID
+ *  @param  content         教程信息
+ */
++ (void)onGuideFinished:(NSString *)profileId content:(NSString *)content;
+
+
+
+
+
+/**
+ *  解锁成就
+ *  @param  profileId       账户ID
+ *  @param  achievementId   成就ID
+ */
++ (void)onAchievementUnlock:(NSString *)profileId achievementId:(NSString *)achievementId;
+
+
+
+/**
+ *  自定义事件
+ *  @param  eventId         事件名称
+ *  @param  parameters      事件参数 (key只支持NSString, value支持NSString和NSNumber)
+ *  @param  eventValue      用户自定义事件参数
+ */
++ (void)onEvent:(NSString *)eventId parameters:(NSDictionary *)parameters eventValue:(NSDictionary *)eventValue;
++ (void)onEvent:(NSString *)eventId parameters:(NSDictionary *)parameters;
++ (void)onEvent:(NSString *)eventId value:(double)eventValue parameters:(NSDictionary *)parameters API_DEPRECATED_WITH_REPLACEMENT("onEvent:parameters", ios(1,1));
+
+/**
+ *  添加自定义事件全局参数
+ *  @param  key             参数的key
+ *  @param  value           参数的value,NSString或NSNumber类型
+ */
++ (void)setGlobalKV:(NSString *)key value:(id)value;
+
+/**
+ *  删除自定义事件全局参数
+ *  @param  key             参数的key
+ */
++ (void)removeGlobalKV:(NSString *)key;
+
+
+@end

+ 33 - 0
Assets/Plugins/iOS/TalkingDataSDK.h.meta

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

二進制
Assets/Plugins/iOS/libTalkingDataSDK.a


+ 33 - 0
Assets/Plugins/iOS/libTalkingDataSDK.a.meta

@@ -0,0 +1,33 @@
+fileFormatVersion: 2
+guid: Wi9JsyOkWihx5hXyiIHc26HHELpe/4siQfX57B6gPZN10IQ7xP3JZmvyMbvK
+PluginImporter:
+  externalObjects: {}
+  serializedVersion: 2
+  iconMap: {}
+  executionOrder: {}
+  defineConstraints: []
+  isPreloaded: 0
+  isOverridable: 0
+  isExplicitlyReferenced: 0
+  validateReferences: 1
+  platformData:
+  - first:
+      Any: 
+    second:
+      enabled: 0
+      settings: {}
+  - first:
+      Editor: Editor
+    second:
+      enabled: 0
+      settings:
+        DefaultValueInitialized: true
+  - first:
+      iPhone: iOS
+    second:
+      enabled: 1
+      settings:
+        AddToEmbeddedBinaries: true
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 1 - 1
Assets/Res/UI/MainPanel/CheckBoxPanel.prefab.meta

@@ -3,5 +3,5 @@ guid: Wn4esSKuW3MI2m87d/2WcXfYGy5sA+YxTiBuOrHXyPLAnazttZ9gSb2HIHwo
 PrefabImporter:
   externalObjects: {}
   userData: 
-  assetBundleName: alternamepanel
+  assetBundleName: checkboxpanel
   assetBundleVariant: 

+ 1 - 1
Assets/Res/UI/SettingPanel/Btn_Audio.prefab.meta

@@ -3,5 +3,5 @@ guid: DXxJ4H75W3JB++ZhNNoQYiRqYzN/SFmAOIqxe5mSaPzd3SmUUoAKpqcQh7l+
 PrefabImporter:
   externalObjects: {}
   userData: 
-  assetBundleName: 
+  assetBundleName: btn_audio
   assetBundleVariant: 

+ 1 - 1
Assets/Res/UI/SettingPanel/SettingPanel.prefab.meta

@@ -3,5 +3,5 @@ guid: XXMZtiuqBX6E4yLijPDG9oYVhFcxoqaSs1liDAsXz64VbdkFRD3Lzio6GT+a
 PrefabImporter:
   externalObjects: {}
   userData: 
-  assetBundleName: alternamepanel
+  assetBundleName: settingpanel
   assetBundleVariant: 

+ 95 - 95
Assets/Scenes/testCombat.scene

@@ -156,7 +156,7 @@ MonoBehaviour:
   m_Name: 
   m_EditorClassIdentifier: 
   ShaderVariantCollection: {fileID: 20000000, guid: 3536136831feec548bbaa7febad775f8, type: 2}
-  LoadType: 0
+  LoadType: 1
   h5Url: http://127.0.0.1:8000
   isOpenHotFix: 0
   isLoadDll: 0
@@ -1237,96 +1237,7 @@ MonoBehaviour:
   m_OnValueChanged:
     m_PersistentCalls:
       m_Calls: []
---- !u!1 &1831378551
-GameObject:
-  m_ObjectHideFlags: 0
-  m_CorrespondingSourceObject: {fileID: 0}
-  m_PrefabInstance: {fileID: 0}
-  m_PrefabAsset: {fileID: 0}
-  serializedVersion: 7
-  m_Component:
-  - component: {fileID: 1831378552}
-  - component: {fileID: 1831378554}
-  - component: {fileID: 1831378553}
-  m_Layer: 0
-  m_HasEditorInfo: 1
-  m_Name: myImage
-  m_TagString: Untagged
-  m_Icon: {fileID: 0}
-  m_NavMeshLayer: 0
-  m_StaticEditorFlags: 0
-  m_IsActive: 1
---- !u!224 &1831378552
-RectTransform:
-  m_ObjectHideFlags: 0
-  m_CorrespondingSourceObject: {fileID: 0}
-  m_PrefabInstance: {fileID: 0}
-  m_PrefabAsset: {fileID: 0}
-  m_GameObject: {fileID: 1831378551}
-  m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
-  m_LocalPosition: {x: 0, y: 0, z: 0}
-  m_LocalScale: {x: 1, y: 1, z: 1}
-  m_ConstrainProportionsScale: 0
-  m_Children: []
-  m_Father: {fileID: 123020045}
-  m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
-  m_AnchorMin: {x: 0.5, y: 0.5}
-  m_AnchorMax: {x: 0.5, y: 0.5}
-  m_AnchoredPosition: {x: 0, y: 0}
-  m_SizeDelta: {x: 100, y: 100}
-  m_Pivot: {x: 0.5, y: 0.5}
---- !u!114 &1831378553
-MonoBehaviour:
-  m_ObjectHideFlags: 0
-  m_CorrespondingSourceObject: {fileID: 0}
-  m_PrefabInstance: {fileID: 0}
-  m_PrefabAsset: {fileID: 0}
-  m_GameObject: {fileID: 1831378551}
-  m_Enabled: 1
-  m_EditorHideFlags: 0
-  m_Script: {fileID: 11500000, guid: 3c247620ca3a1fd4ab2a2f3a5b287e07, type: 3}
-  m_Name: 
-  m_EditorClassIdentifier: 
-  m_Material: {fileID: 0}
-  m_Color: {r: 1, g: 1, b: 1, a: 1}
-  m_RaycastTarget: 1
-  m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
-  m_Maskable: 1
-  m_OnCullStateChanged:
-    m_PersistentCalls:
-      m_Calls: []
-  m_Sprite: {fileID: 2080538702}
-  m_Type: 0
-  m_PreserveAspect: 0
-  m_FillCenter: 1
-  m_FillMethod: 4
-  m_FillAmount: 1
-  m_FillClockwise: 1
-  m_FillOrigin: 0
-  m_UseSpriteMesh: 0
-  m_PixelsPerUnitMultiplier: 1
-  _icon_name: dec_jianbian_tiao
-  isNotLoadDeftIcon: 0
-  CurrSpriteAtlas: {fileID: 100100200, guid: b02f6b41a7a9fa8458f4226ab6b3ea47, type: 3}
-  packInfo:
-    packName: tongyong
-    packgJsonPath: /Art/UIAssets/TextrueJson\tongyong.txt
-    packgSpritePath: Assets/Res/UIAtlas/tongyong.spriteatlasv2
-    lasetJsonGUID: 6f525d051e27c33e0699a302ce6a4b3d
-  imageH: 100
-  useGradient: 0
-  topOrLeftColor: {r: 1, g: 1, b: 1, a: 1}
-  bottomOrRightColor: {r: 0, g: 0, b: 0, a: 1}
-  direction: 0
---- !u!222 &1831378554
-CanvasRenderer:
-  m_ObjectHideFlags: 0
-  m_CorrespondingSourceObject: {fileID: 0}
-  m_PrefabInstance: {fileID: 0}
-  m_PrefabAsset: {fileID: 0}
-  m_GameObject: {fileID: 1831378551}
-  m_CullTransparentMesh: 1
---- !u!213 &2080538702
+--- !u!213 &1477443412
 Sprite:
   m_ObjectHideFlags: 0
   m_CorrespondingSourceObject: {fileID: 0}
@@ -1525,14 +1436,14 @@ Sprite:
     m_Bindpose: []
     textureRect:
       serializedVersion: 2
-      x: 389
-      y: 1229
+      x: 0
+      y: 1562
       width: 115
       height: 33
     textureRectOffset: {x: 0, y: 0}
-    atlasRectOffset: {x: 389, y: 1229}
+    atlasRectOffset: {x: 0, y: 1562}
     settingsRaw: 67
-    uvTransform: {x: 100, y: 446.5, z: 100, w: 1245.5}
+    uvTransform: {x: 100, y: 57.5, z: 100, w: 1578.5}
     downscaleMultiplier: 1
   m_PhysicsShape:
   - - {x: 0.345, y: 0.16499999}
@@ -1541,6 +1452,95 @@ Sprite:
     - {x: 0.575, y: 0.16499999}
   m_Bones: []
   m_SpriteID: 5e97eb03825dee720800000000000000
+--- !u!1 &1831378551
+GameObject:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  serializedVersion: 7
+  m_Component:
+  - component: {fileID: 1831378552}
+  - component: {fileID: 1831378554}
+  - component: {fileID: 1831378553}
+  m_Layer: 0
+  m_HasEditorInfo: 1
+  m_Name: myImage
+  m_TagString: Untagged
+  m_Icon: {fileID: 0}
+  m_NavMeshLayer: 0
+  m_StaticEditorFlags: 0
+  m_IsActive: 1
+--- !u!224 &1831378552
+RectTransform:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 1831378551}
+  m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
+  m_LocalPosition: {x: 0, y: 0, z: 0}
+  m_LocalScale: {x: 1, y: 1, z: 1}
+  m_ConstrainProportionsScale: 0
+  m_Children: []
+  m_Father: {fileID: 123020045}
+  m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
+  m_AnchorMin: {x: 0.5, y: 0.5}
+  m_AnchorMax: {x: 0.5, y: 0.5}
+  m_AnchoredPosition: {x: 0, y: 0}
+  m_SizeDelta: {x: 100, y: 100}
+  m_Pivot: {x: 0.5, y: 0.5}
+--- !u!114 &1831378553
+MonoBehaviour:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 1831378551}
+  m_Enabled: 1
+  m_EditorHideFlags: 0
+  m_Script: {fileID: 11500000, guid: 3c247620ca3a1fd4ab2a2f3a5b287e07, type: 3}
+  m_Name: 
+  m_EditorClassIdentifier: 
+  m_Material: {fileID: 0}
+  m_Color: {r: 1, g: 1, b: 1, a: 1}
+  m_RaycastTarget: 1
+  m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
+  m_Maskable: 1
+  m_OnCullStateChanged:
+    m_PersistentCalls:
+      m_Calls: []
+  m_Sprite: {fileID: 1477443412}
+  m_Type: 0
+  m_PreserveAspect: 0
+  m_FillCenter: 1
+  m_FillMethod: 4
+  m_FillAmount: 1
+  m_FillClockwise: 1
+  m_FillOrigin: 0
+  m_UseSpriteMesh: 0
+  m_PixelsPerUnitMultiplier: 1
+  _icon_name: dec_jianbian_tiao
+  isNotLoadDeftIcon: 0
+  CurrSpriteAtlas: {fileID: 100100200, guid: b02f6b41a7a9fa8458f4226ab6b3ea47, type: 3}
+  packInfo:
+    packName: tongyong
+    packgJsonPath: /Art/UIAssets/TextrueJson\tongyong.txt
+    packgSpritePath: Assets/Res/UIAtlas/tongyong.spriteatlasv2
+    lasetJsonGUID: 6f525d051e27c33e0699a302ce6a4b3d
+  imageH: 100
+  useGradient: 0
+  topOrLeftColor: {r: 1, g: 1, b: 1, a: 1}
+  bottomOrRightColor: {r: 0, g: 0, b: 0, a: 1}
+  direction: 0
+--- !u!222 &1831378554
+CanvasRenderer:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 1831378551}
+  m_CullTransparentMesh: 1
 --- !u!114 &4237119297094294473
 MonoBehaviour:
   m_ObjectHideFlags: 0

+ 2 - 1
Assets/Scripts/GameLogic/Fort23.GameLogic.asmdef

@@ -10,7 +10,8 @@
         "GUID:d8b63aba1907145bea998dd612889d6b",
         "GUID:5efd170ecd8084500bed5692932fe14e",
         "GUID:8097be56b8f8a81458fa9b1971038cec",
-        "GUID:9aacf4a871662084382dfb2f67105436"
+        "GUID:9aacf4a871662084382dfb2f67105436",
+        "ThirdParty"
     ],
     "includePlatforms": [],
     "excludePlatforms": [],

+ 1 - 1
Assets/Scripts/GameLogic/Hero/HeroInfo.cs

@@ -71,7 +71,7 @@ namespace GameLogic.Hero
 
         public HeroInfo Upgrade()
         {
-            Dictionary<string, string> dictionary = new Dictionary<string, string>();
+            Dictionary<string, object> dictionary = new Dictionary<string, object>();
             dictionary.Add("JingJie", heroData.heroPowerId.ToString());
             DBManager.Instance.CustomEvent("Hero_levelup", dictionary);
             int currentMiao = (int)((TimeHelper.ClientNow() - PlayerManager.Instance.myHero.heroData.upTime) / 1000);

+ 8 - 4
Assets/Scripts/GameLogic/SDK/DBManager.cs

@@ -5,14 +5,18 @@ using Utility;
 
 public class DBManager : Singleton<DBManager>
 {
-   
+    public DBManager()
+    {
+        TalkingDataManager.Instance.CustomInit();
+    }
+
     /// <summary>
     /// 自定义打点
     /// </summary>
     /// <param name="key"></param>
     /// <param name="lable"></param>
-    public void CustomEvent(string key, Dictionary<string, string> lable)
+    public void CustomEvent(string key, Dictionary<string, object> lable)
     {
-
+        TalkingDataManager.Instance.TrackEvent(key, lable);
     }
-}
+}

+ 104 - 0
Assets/Scripts/GameLogic/SDK/TalkingDataManager.cs

@@ -0,0 +1,104 @@
+using System.Collections.Generic;
+using Fort23.UTool;
+using UnityEngine;
+using Utility;
+
+
+public class TalkingDataManager : Singleton<TalkingDataManager>
+{
+    private string appID = "965461C1FE104336864EF6D7EBABC2A7";
+
+#if Taptap
+  private string channelID = "Taptap";
+#elif HaoYouKuaiBao
+      private string channelID = "好友快报";
+#elif Google
+    private string channelID = "Google";
+#else
+        private string channelID = "Unity";
+#endif
+
+
+    private bool isInitialized = false;
+
+
+    public void CustomInit()
+    {
+        InitializeTalkingData();
+    }
+
+    /// <summary>
+    /// 初始化TalkingData SDK
+    /// </summary>
+    public void InitializeTalkingData()
+    {
+        if (isInitialized) return;
+
+        try
+        {
+            TalkingDataSDKConfig config = TalkingDataSDKConfig.CreateConfig();
+            config.SetIMEIAndMEIDEnabled(true) //不允许收集IMEI和MEID
+                .SetMACEnabled(true) //不允许收集MAC
+                .SetAppListEnabled(true) //不允许收集应用列表
+                .SetLocationEnabled(true) //不允许收集位置信息
+                .SetWifiEnabled(true); //不允许收集网络信息
+
+            TalkingDataSDK.SetConfig(config);
+            TalkingDataSDK.BackgroundSessionEnabled();
+            TalkingDataSDK.InitSDK(appID, channelID, "");
+            TalkingDataSDK.StartA();
+            isInitialized = true;
+            LogTool.Log($"TalkingData 初始化成功 - AppID: {appID}, Channel: {channelID}");
+        }
+        catch (System.Exception e)
+        {
+            LogTool.Error($"TalkingData 初始化失败: {e.Message}");
+        }
+    }
+
+    /// <summary>
+    /// 账户登录
+    /// </summary>
+    public void OnLogin()
+    {
+        if (!isInitialized) return;
+
+        try
+        {
+            TalkingDataProfile profile = TalkingDataProfile.CreateProfile();
+            profile.SetName(PlayerManager.Instance.PlayerName);
+            profile.SetType(TalkingDataProfileType.TYPE1);
+            profile.SetGender(TalkingDataGender.UNKNOWN);
+            Dictionary<string, object> eventValue = new Dictionary<string, object>
+            {
+            };
+            TalkingDataSDK.OnLogin(PlayerManager.Instance.PlayerName, profile, eventValue);
+
+            LogTool.Log($"TalkingData 设置账户: {PlayerManager.Instance.PlayerName}");
+        }
+        catch (System.Exception e)
+        {
+            LogTool.Error($"TalkingData 设置账户失败: {e.Message}");
+        }
+    }
+
+
+    /// <summary>
+    /// 记录自定义事件
+    /// </summary>
+    public void TrackEvent(string eventID, Dictionary<string, object> parameters,
+        Dictionary<string, object> eventValue = null)
+    {
+        if (!isInitialized) return;
+
+        try
+        {
+            TalkingDataSDK.OnEvent(eventID, parameters, eventValue);
+            LogTool.Log($"TalkingData 记录事件: {eventID} ");
+        }
+        catch (System.Exception e)
+        {
+            LogTool.Error($"TalkingData 记录事件失败: {e.Message}");
+        }
+    }
+}

+ 11 - 0
Assets/Scripts/GameLogic/SDK/TalkingDataManager.cs.meta

@@ -0,0 +1,11 @@
+fileFormatVersion: 2
+guid: B3Me5HylVCrxvL6xMzuyheiDMvefnWgH/sbVrFRKKTLp24VQl1Nxlv9wAhYm
+MonoImporter:
+  externalObjects: {}
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 5 - 3
Assets/Scripts/GameUI/GameApplction.cs

@@ -114,7 +114,7 @@ public class GameApplction : IGameStart, ILogSend
         AssetHandle gameRuntimeAssetHandle =
             await AssetBundleLoadManager.Instance.LoadAssetAsyncTask<GameRuntimeConfig>("GameRuntimeConfig.asset");
         gameRuntimeConfig = gameRuntimeAssetHandle.AssetObject<GameRuntimeConfig>();
-    
+
         await ConfigComponent.Instance.Preload();
         await AnimationCurveManager.Instance.Init();
         UGUIPackLoad uguiPackLoad = new UGUIPackLoad();
@@ -147,9 +147,11 @@ public class GameApplction : IGameStart, ILogSend
         //     LogTool.Error("登陆失败");
         //     return;
         // }
-        
+
         await TimeHelper.InitNetworkTime();
-        
+
+        DBManager.Instance.CustomEvent("StartGame", null);
+
         EventManager.Instance.RemoveEventListener(CustomEventType.DialoguePanelOpen, DialoguePanelOpenEvent);
         EventManager.Instance.AddEventListener(CustomEventType.DialoguePanelOpen, DialoguePanelOpenEvent);
         UIManager.Instance.Canvas.gameObject.SetActive(true);

+ 8 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts.meta

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

+ 400 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TDDemoScript.cs

@@ -0,0 +1,400 @@
+using UnityEngine;
+using System.Collections.Generic;
+
+public class TDDemoScript : MonoBehaviour
+{
+    private const int top = 100;
+    private const int left = 80;
+    private const int height = 60;
+    private const int spacing = 20;
+    private readonly int width = (Screen.width - (left * 2) - spacing) / 2;
+    private const int step = 80;
+    private string tdid;
+    private string oaid;
+
+    private void OnGUI()
+    {
+        int i = 0;
+        GUI.Box(new Rect(10, 10, Screen.width - 20, Screen.height - 20), "Demo Menu");
+
+        GUI.Label(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), tdid);
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "getTDID"))
+        {
+            tdid = TalkingDataSDK.GetDeviceId();
+        }
+
+#if UNITY_ANDROID
+        GUI.Label(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), oaid);
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "getOAID"))
+        {
+            oaid = TalkingDataSDK.GetOAID();
+        }
+#endif
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnPageBegin"))
+        {
+            TalkingDataSDK.OnPageBegin("home_page");
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnPageEnd"))
+        {
+            TalkingDataSDK.OnPageEnd("home_page");
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnReceiveDeepLink"))
+        {
+            TalkingDataSDK.OnReceiveDeepLink("https://www.talkingdata.com");
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnRegister"))
+        {
+            TalkingDataProfile profile = TalkingDataProfile.CreateProfile();
+            profile.SetName("name01");
+            profile.SetType(TalkingDataProfileType.WEIXIN);
+            profile.SetGender(TalkingDataGender.MALE);
+            profile.SetAge(18);
+            profile.SetProperty1("property1");
+            profile.SetProperty2(2);
+            profile.SetProperty3(3.14);
+            profile.SetProperty4("property4");
+            profile.SetProperty5("property5");
+            profile.SetProperty6(0.618);
+            profile.SetProperty7("property7");
+            profile.SetProperty8("property8");
+            profile.SetProperty9(9.8);
+            profile.SetProperty10("property10");
+            Dictionary<string, object> eventValue = new Dictionary<string, object>
+            {
+                { "key", "value" }
+            };
+            TalkingDataSDK.OnRegister("user01", profile, "123456", eventValue);
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnLogin"))
+        {
+            TalkingDataProfile profile = TalkingDataProfile.CreateProfile();
+            profile.SetName("name01");
+            profile.SetType(TalkingDataProfileType.WEIXIN);
+            profile.SetGender(TalkingDataGender.MALE);
+            profile.SetAge(18);
+            profile.SetProperty1("property1");
+            profile.SetProperty2(2);
+            profile.SetProperty3(3.14);
+            profile.SetProperty4("property4");
+            profile.SetProperty5("property5");
+            profile.SetProperty6(0.618);
+            profile.SetProperty7("property7");
+            profile.SetProperty8("property8");
+            profile.SetProperty9(9.8);
+            profile.SetProperty10("property10");
+            Dictionary<string, object> eventValue = new Dictionary<string, object>
+            {
+                { "key", "value" }
+            };
+            TalkingDataSDK.OnLogin("user01", profile, eventValue);
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnProfileUpdate"))
+        {
+            TalkingDataProfile profile = TalkingDataProfile.CreateProfile();
+            profile.SetName("name01");
+            profile.SetType(TalkingDataProfileType.WEIXIN);
+            profile.SetGender(TalkingDataGender.MALE);
+            profile.SetAge(18);
+            profile.SetProperty1("property1");
+            profile.SetProperty2(2);
+            profile.SetProperty3(3.14);
+            profile.SetProperty4("property4");
+            profile.SetProperty5("property5");
+            profile.SetProperty6(0.618);
+            profile.SetProperty7("property7");
+            profile.SetProperty8("property8");
+            profile.SetProperty9(9.8);
+            profile.SetProperty10("property10");
+            TalkingDataSDK.OnProfileUpdate(profile);
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnCreateCard"))
+        {
+            TalkingDataSDK.OnCreateCard("user01", "支付宝", "支付宝账号123456789");
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnFavorite"))
+        {
+            Dictionary<string, object> eventValue = new Dictionary<string, object>
+            {
+                { "key", "value" }
+            };
+            TalkingDataSDK.OnFavorite("服装", "2019新款", eventValue);
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnShare"))
+        {
+            Dictionary<string, object> eventValue = new Dictionary<string, object>
+            {
+                { "key", "value" }
+            };
+            TalkingDataSDK.OnShare("user01", "课程", eventValue);
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnPunch"))
+        {
+            TalkingDataSDK.OnPunch("user01", "签到0023");
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnSearch"))
+        {
+            TalkingDataSearch search = TalkingDataSearch.CreateSearch();
+            search.SetCategory("类型");
+            search.SetContent("内容");
+#if TD_RETAIL
+            search.SetItemId("商品ID");
+            search.SetItemLocationId("location12314");
+#endif
+#if TD_TOUR
+            search.SetDestination("目的地");
+            search.SetOrigin("出发地");
+            search.SetStartDate(1565176907309);
+            search.SetEndDate(1565176908309);
+#endif
+            TalkingDataSDK.OnSearch(search);
+        }
+
+#if TD_RETAIL || TD_FINANCE || TD_TOUR || TD_ONLINEEDU
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnContact"))
+        {
+            TalkingDataSDK.OnContact("user01", "联系平台内容");
+        }
+#endif
+
+#if TD_GAME || TD_TOUR || TD_ONLINEEDU || TD_READING || TD_OTHER
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnPay"))
+        {
+            TalkingDataSDK.OnPay("user01", "order01", 1077600, "CNY", "Apple Pay", "item01", 2);
+        }
+#endif
+
+#if TD_RETAIL || TD_FINANCE || TD_TOUR || TD_ONLINEEDU
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnChargeBack"))
+        {
+            TalkingDataSDK.OnChargeBack("user01", "order01", "7天无理由退货", "仅退款");
+        }
+#endif
+
+#if TD_FINANCE || TD_ONLINEEDU
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnReservation"))
+        {
+            TalkingDataSDK.OnReservation("user01", "AdTracking_123456", "借贷类", 12, "商品信息");
+        }
+#endif
+
+#if TD_RETAIL || TD_TOUR
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnBooking"))
+        {
+            TalkingDataSDK.OnBooking("user01", "002391", "电子", 123, "商品信息");
+        }
+#endif
+
+#if TD_RETAIL
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnViewItem"))
+        {
+            Dictionary<string, object> eventValue = new Dictionary<string, object>
+            {
+                { "key", "value" }
+            };
+            TalkingDataSDK.OnViewItem("A1660", "手机", "iPhone 7", 538800, eventValue);
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnAddItemToShoppingCart"))
+        {
+            Dictionary<string, object> eventValue = new Dictionary<string, object>
+            {
+                { "key", "value" }
+            };
+            TalkingDataSDK.OnAddItemToShoppingCart("MLH12CH", "电脑", "MacBook Pro", 1388800, 1, eventValue);
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnViewShoppingCart"))
+        {
+            TalkingDataShoppingCart shoppingCart = TalkingDataShoppingCart.CreateShoppingCart();
+            if (shoppingCart != null)
+            {
+                shoppingCart.AddItem("A1660", "手机", "iPhone 7", 538800, 2);
+                shoppingCart.AddItem("MLH12CH", "电脑", "MacBook Pro", 1388800, 1);
+                TalkingDataSDK.OnViewShoppingCart(shoppingCart);
+            }
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnPlaceOrder"))
+        {
+            TalkingDataOrder order = TalkingDataOrder.CreateOrder("order01", 2466400, "CNY");
+            order.AddItem("A1660", "手机", "iPhone 7", 538800, 2);
+            order.AddItem("MLH12CH", "电脑", "MacBook Pro", 1388800, 1);
+            Dictionary<string, object> eventValue = new Dictionary<string, object>
+            {
+                { "key", "value" }
+            };
+            TalkingDataSDK.OnPlaceOrder(order, "user01", eventValue);
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnOrderPaySucc"))
+        {
+            TalkingDataOrder order = TalkingDataOrder.CreateOrder("order01", 2466400, "CNY");
+            order.AddItem("A1660", "手机", "iPhone 7", 538800, 2);
+            order.AddItem("MLH12CH", "电脑", "MacBook Pro", 1388800, 1);
+            TalkingDataSDK.OnOrderPaySucc(order, "AliPay", "user01");
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnCancelOrder"))
+        {
+            TalkingDataOrder order = TalkingDataOrder.CreateOrder("order01", 2466400, "CNY");
+            order.AddItem("A1660", "手机", "iPhone 7", 538800, 2);
+            order.AddItem("MLH12CH", "电脑", "MacBook Pro", 1388800, 1);
+            TalkingDataSDK.OnCancelOrder(order);
+        }
+#endif
+
+#if TD_FINANCE
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnCredit"))
+        {
+            TalkingDataSDK.OnCredit("user01", 123456, "授信详情为......");
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnTransaction"))
+        {
+            TalkingDataTransaction transaction = TalkingDataTransaction.CreateTransaction();
+            transaction.SetTransactionId("AdTracking_123456");
+            transaction.SetCategory("定期");
+            transaction.SetAmount(3222);
+            transaction.SetPersonA("张三");
+            transaction.SetPersonB("金融平台");
+            transaction.SetStartDate(1565176907309);
+            transaction.SetEndDate(1565176908309);
+            transaction.SetCurrencyType("CNY");
+            transaction.SetContent("交易详情为......");
+            TalkingDataSDK.OnTransaction("user01", transaction);
+        }
+#endif
+
+#if TD_GAME
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnCreateRole"))
+        {
+            TalkingDataSDK.OnCreateRole("role01");
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnLevelPass"))
+        {
+            TalkingDataSDK.OnLevelPass("user01", "AdTracking_123456");
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnGuideFinished"))
+        {
+            TalkingDataSDK.OnGuideFinished("user01", "新手教程顺利通过");
+        }
+#endif
+
+#if TD_ONLINEEDU
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnLearn"))
+        {
+            TalkingDataSDK.OnLearn("user01", "成人教育第一节", 1501234567890, 20);
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnPreviewFinished"))
+        {
+            TalkingDataSDK.OnPreviewFinished("user01", "基础课程试听结束");
+        }
+#endif
+
+#if TD_READING
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnRead"))
+        {
+            TalkingDataSDK.OnRead("user01", "西游记第一章", 1501234567890, 20);
+        }
+
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnFreeFinished"))
+        {
+            TalkingDataSDK.OnFreeFinished("user01", "免费章节阅读结束");
+        }
+#endif
+
+#if TD_GAME || TD_ONLINEEDU
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnAchievementUnlock"))
+        {
+            TalkingDataSDK.OnAchievementUnlock("user01", "AdTracking_123456");
+        }
+#endif
+
+#if TD_FINANCE || TD_TOUR || TD_OTHER
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnBrowse"))
+        {
+            TalkingDataSDK.OnBrowse("user01", "详情页page1", 1501234567890, 20);
+        }
+#endif
+
+#if TD_RETAIL || TD_FINANCE || TD_TOUR || TD_OTHER
+        if (GUI.Button(new Rect(left + i % 2 * (width + spacing), top + step * (i++ / 2), width, height), "OnTrialFinished"))
+        {
+            TalkingDataSDK.OnTrialFinished("user01", "试用体验结束");
+        }
+#endif
+
+        if (GUI.Button(new Rect(left, top + (step * i++), width, height), "OnEvent"))
+        {
+            Dictionary<string, object> dic = new Dictionary<string, object>
+            {
+                { "StringValue", "Pi" },
+                { "NumberValue", 3.14 }
+            };
+            Dictionary<string, object> eventValue = new Dictionary<string, object>
+            {
+                { "key", "value" }
+            };
+            TalkingDataSDK.OnEvent("action_id", dic, eventValue);
+        }
+    }
+
+    void Start()
+    {
+        Debug.Log("Start");
+        // TalkingDataSDK.SetVerboseLogDisable();
+        TalkingDataSDKConfig config = TalkingDataSDKConfig.CreateConfig();
+        config.SetIMEIAndMEIDEnabled(false)//不允许收集IMEI和MEID
+                .SetMACEnabled(false)//不允许收集MAC
+                .SetAppListEnabled(false)//不允许收集应用列表
+                .SetLocationEnabled(false)//不允许收集位置信息
+                .SetWifiEnabled(false);//不允许收集网络信息
+        TalkingDataSDK.SetConfig(config);
+        TalkingDataSDK.BackgroundSessionEnabled();
+        TalkingDataSDK.InitSDK("your_app_id", "your_channel_id", "your_custom_parameter");
+        TalkingDataSDK.StartA();
+    }
+
+    void Update()
+    {
+        if (Input.GetKey(KeyCode.Escape))
+        {
+            Application.Quit();
+        }
+    }
+
+    void OnDestroy()
+    {
+        Debug.Log("onDestroy");
+        TalkingDataSDK.OnPause();
+    }
+
+    void Awake()
+    {
+        Debug.Log("Awake");
+    }
+
+    void OnEnable()
+    {
+        Debug.Log("OnEnable");
+    }
+
+    void OnDisable()
+    {
+        Debug.Log("OnDisable");
+    }
+}

+ 11 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TDDemoScript.cs.meta

@@ -0,0 +1,11 @@
+fileFormatVersion: 2
+guid: WntOvSutVHptthMVwcnd70SVcWhij8L0SWaXhbK5fS9Qpk15L7OM04ovXLl6
+MonoImporter:
+  externalObjects: {}
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 71 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataOrder.cs

@@ -0,0 +1,71 @@
+using UnityEngine;
+
+
+#if TD_RETAIL
+public class TalkingDataOrder
+{
+#if UNITY_ANDROID
+    public AndroidJavaObject javaObj;
+#endif
+
+#if UNITY_IPHONE
+    private string orderId;
+    private int total;
+    private string currencyType;
+    private string items = "";
+#endif
+
+    public static TalkingDataOrder CreateOrder(string orderId, int total, string currencyType)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+            TalkingDataOrder order = new TalkingDataOrder();
+#if UNITY_ANDROID
+            AndroidJavaClass javaClass = new AndroidJavaClass("com.tendcloud.tenddata.TalkingDataOrder");
+            order.javaObj = javaClass.CallStatic<AndroidJavaObject>("createOrder", orderId, total, currencyType);
+#endif
+#if UNITY_IPHONE
+            order.orderId = orderId;
+            order.total = total;
+            order.currencyType = currencyType;
+#endif
+            return order;
+        }
+        return null;
+    }
+
+    public TalkingDataOrder AddItem(string itemId, string category, string name, int unitPrice, int amount)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("addItem", itemId, category, name, unitPrice, amount);
+            }
+#endif
+#if UNITY_IPHONE
+            string item = "{\"itemId\":\"" + itemId + "\",\"category\":\"" + category + "\",\"name\":\"" + name + "\",\"unitPrice\":" + unitPrice + ",\"amount\":" + amount + "}";
+            if (items.Length > 0)
+            {
+                items += ",";
+            }
+            items += item;
+#endif
+        }
+        return this;
+    }
+
+#if UNITY_IPHONE
+    public override string ToString()
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+            string orderStr = "{\"orderId\":\"" + orderId + "\",\"total\":" + total + ",\"currencyType\":\"" + currencyType + "\",\"items\":[" + items + "]}";
+            return orderStr;
+        }
+        return null;
+    }
+#endif
+}
+#endif

+ 11 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataOrder.cs.meta

@@ -0,0 +1,11 @@
+fileFormatVersion: 2
+guid: CSlMtS2pWnvStkMzeGxRcdWR+fhYoghk3PeEpXIHlvRSBwJJW4uZKPoWD+BZ
+MonoImporter:
+  externalObjects: {}
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 468 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataProfile.cs

@@ -0,0 +1,468 @@
+using UnityEngine;
+
+
+public enum TalkingDataProfileType
+{
+    ANONYMOUS   = 0,
+    REGISTERED  = 1,
+    SINA_WEIBO  = 2,
+    QQ          = 3,
+    QQ_WEIBO    = 4,
+    ND91        = 5,
+    WEIXIN      = 6,
+    TYPE1       = 11,
+    TYPE2       = 12,
+    TYPE3       = 13,
+    TYPE4       = 14,
+    TYPE5       = 15,
+    TYPE6       = 16,
+    TYPE7       = 17,
+    TYPE8       = 18,
+    TYPE9       = 19,
+    TYPE10      = 20
+}
+
+
+public enum TalkingDataGender
+{
+    UNKNOWN     = 0,
+    MALE        = 1,
+    FEMALE      = 2
+}
+
+
+public class TalkingDataProfile
+{
+#if UNITY_ANDROID
+    public AndroidJavaObject javaObj;
+#endif
+
+#if UNITY_IPHONE
+    private string name;
+    private TalkingDataProfileType type;
+    private TalkingDataGender gender;
+    private int age;
+    private object property1;
+    private object property2;
+    private object property3;
+    private object property4;
+    private object property5;
+    private object property6;
+    private object property7;
+    private object property8;
+    private object property9;
+    private object property10;
+#endif
+
+    public static TalkingDataProfile CreateProfile()
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+            TalkingDataProfile profile = new TalkingDataProfile();
+#if UNITY_ANDROID
+            AndroidJavaClass javaClass = new AndroidJavaClass("com.tendcloud.tenddata.TalkingDataProfile");
+            profile.javaObj = javaClass.CallStatic<AndroidJavaObject>("createProfile");
+#endif
+            return profile;
+        }
+        return null;
+    }
+
+    // 账户名称
+    public TalkingDataProfile SetName(string name)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setName", name);
+            }
+#endif
+#if UNITY_IPHONE
+            this.name = name;
+#endif
+        }
+        return this;
+    }
+
+    // 账户类型
+    public TalkingDataProfile SetType(TalkingDataProfileType type)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                AndroidJavaClass enumClass = new AndroidJavaClass("com.tendcloud.tenddata.TalkingDataProfileType");
+                AndroidJavaObject typeObj = enumClass.CallStatic<AndroidJavaObject>("valueOf", type.ToString());
+                javaObj.Call<AndroidJavaObject>("setType", typeObj);
+            }
+#endif
+#if UNITY_IPHONE
+            this.type = type;
+#endif
+        }
+        return this;
+    }
+
+    // 性别
+    public TalkingDataProfile SetGender(TalkingDataGender gender)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                AndroidJavaClass enumClass = new AndroidJavaClass("com.tendcloud.tenddata.TalkingDataGender");
+                AndroidJavaObject genderObj = enumClass.CallStatic<AndroidJavaObject>("valueOf", gender.ToString());
+                javaObj.Call<AndroidJavaObject>("setGender", genderObj);
+            }
+#endif
+#if UNITY_IPHONE
+            this.gender = gender;
+#endif
+        }
+        return this;
+    }
+
+    // 年龄
+    public TalkingDataProfile SetAge(int age)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setAge", age);
+            }
+#endif
+#if UNITY_IPHONE
+            this.age = age;
+#endif
+        }
+        return this;
+    }
+
+    // 用户属性1
+    public TalkingDataProfile SetProperty1(object property)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                AndroidJavaObject androidObject = AndroidJavaObjectFromObject(property);
+                javaObj.Call<AndroidJavaObject>("setProperty1", androidObject);
+            }
+#endif
+#if UNITY_IPHONE
+            this.property1 = property;
+#endif
+        }
+        return this;
+    }
+
+    // 用户属性2
+    public TalkingDataProfile SetProperty2(object property)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                AndroidJavaObject androidObject = AndroidJavaObjectFromObject(property);
+                javaObj.Call<AndroidJavaObject>("setProperty2", androidObject);
+            }
+#endif
+#if UNITY_IPHONE
+            this.property2 = property;
+#endif
+        }
+        return this;
+    }
+
+    // 用户属性3
+    public TalkingDataProfile SetProperty3(object property)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                AndroidJavaObject androidObject = AndroidJavaObjectFromObject(property);
+                javaObj.Call<AndroidJavaObject>("setProperty3", androidObject);
+            }
+#endif
+#if UNITY_IPHONE
+            this.property3 = property;
+#endif
+        }
+        return this;
+    }
+
+    // 用户属性4
+    public TalkingDataProfile SetProperty4(object property)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                AndroidJavaObject androidObject = AndroidJavaObjectFromObject(property);
+                javaObj.Call<AndroidJavaObject>("setProperty4", androidObject);
+            }
+#endif
+#if UNITY_IPHONE
+            this.property4 = property;
+#endif
+        }
+        return this;
+    }
+
+    // 用户属性5
+    public TalkingDataProfile SetProperty5(object property)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                AndroidJavaObject androidObject = AndroidJavaObjectFromObject(property);
+                javaObj.Call<AndroidJavaObject>("setProperty5", androidObject);
+            }
+#endif
+#if UNITY_IPHONE
+            this.property5 = property;
+#endif
+        }
+        return this;
+    }
+
+    // 用户属性6
+    public TalkingDataProfile SetProperty6(object property)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                AndroidJavaObject androidObject = AndroidJavaObjectFromObject(property);
+                javaObj.Call<AndroidJavaObject>("setProperty6", androidObject);
+            }
+#endif
+#if UNITY_IPHONE
+            this.property6 = property;
+#endif
+        }
+        return this;
+    }
+
+    // 用户属性7
+    public TalkingDataProfile SetProperty7(object property)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                AndroidJavaObject androidObject = AndroidJavaObjectFromObject(property);
+                javaObj.Call<AndroidJavaObject>("setProperty7", androidObject);
+            }
+#endif
+#if UNITY_IPHONE
+            this.property7 = property;
+#endif
+        }
+        return this;
+    }
+
+    // 用户属性8
+    public TalkingDataProfile SetProperty8(object property)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                AndroidJavaObject androidObject = AndroidJavaObjectFromObject(property);
+                javaObj.Call<AndroidJavaObject>("setProperty8", androidObject);
+            }
+#endif
+#if UNITY_IPHONE
+            this.property8 = property;
+#endif
+        }
+        return this;
+    }
+
+    // 用户属性9
+    public TalkingDataProfile SetProperty9(object property)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                AndroidJavaObject androidObject = AndroidJavaObjectFromObject(property);
+                javaObj.Call<AndroidJavaObject>("setProperty9", androidObject);
+            }
+#endif
+#if UNITY_IPHONE
+            this.property9 = property;
+#endif
+        }
+        return this;
+    }
+
+    // 用户属性10
+    public TalkingDataProfile SetProperty10(object property)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                AndroidJavaObject androidObject = AndroidJavaObjectFromObject(property);
+                javaObj.Call<AndroidJavaObject>("setProperty10", androidObject);
+            }
+#endif
+#if UNITY_IPHONE
+            this.property10 = property;
+#endif
+        }
+        return this;
+    }
+
+#if UNITY_ANDROID
+    private AndroidJavaObject AndroidJavaObjectFromObject(object parameter)
+    {
+        AndroidJavaObject androidObject = null;
+        if (parameter is string)
+        {
+            androidObject = new AndroidJavaObject("java.lang.String", parameter);
+        }
+        else if (parameter is byte || parameter is sbyte)
+        {
+            androidObject = new AndroidJavaObject("java.lang.Byte", parameter);
+        }
+        else if (parameter is short || parameter is ushort)
+        {
+            androidObject = new AndroidJavaObject("java.lang.Short", parameter);
+        }
+        else if (parameter is int || parameter is uint)
+        {
+            androidObject = new AndroidJavaObject("java.lang.Integer", parameter);
+        }
+        else if (parameter is long || parameter is ulong)
+        {
+            androidObject = new AndroidJavaObject("java.lang.Long", parameter);
+        }
+        else if (parameter is float)
+        {
+            androidObject = new AndroidJavaObject("java.lang.Float", parameter);
+        }
+        else if (parameter is double)
+        {
+            androidObject = new AndroidJavaObject("java.lang.Double", parameter);
+        }
+        return androidObject;
+    }
+#endif
+
+#if UNITY_IPHONE
+    public override string ToString()
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+            string profileStr = "{\"name\":\"" + name + "\""
+                              + ",\"type\":" + (int)type
+                              + ",\"gender\":" + (int)gender
+                              + ",\"age\":" + age;
+            if (property1 is string)
+            {
+                profileStr += ",\"property1\":\"" + property1 + "\"";
+            }
+            else
+            {
+                profileStr += ",\"property1\":" + property1;
+            }
+            if (property2 is string)
+            {
+                profileStr += ",\"property2\":\"" + property2 + "\"";
+            }
+            else
+            {
+                profileStr += ",\"property2\":" + property2;
+            }
+            if (property3 is string)
+            {
+                profileStr += ",\"property3\":\"" + property3 + "\"";
+            }
+            else
+            {
+                profileStr += ",\"property3\":" + property3;
+            }
+            if (property4 is string)
+            {
+                profileStr += ",\"property4\":\"" + property4 + "\"";
+            }
+            else
+            {
+                profileStr += ",\"property4\":" + property4;
+            }
+            if (property5 is string)
+            {
+                profileStr += ",\"property5\":\"" + property5 + "\"";
+            }
+            else
+            {
+                profileStr += ",\"property5\":" + property5;
+            }
+            if (property6 is string)
+            {
+                profileStr += ",\"property6\":\"" + property6 + "\"";
+            }
+            else
+            {
+                profileStr += ",\"property6\":" + property6;
+            }
+            if (property7 is string)
+            {
+                profileStr += ",\"property7\":\"" + property7 + "\"";
+            }
+            else
+            {
+                profileStr += ",\"property7\":" + property7;
+            }
+            if (property8 is string)
+            {
+                profileStr += ",\"property8\":\"" + property8 + "\"";
+            }
+            else
+            {
+                profileStr += ",\"property8\":" + property8;
+            }
+            if (property9 is string)
+            {
+                profileStr += ",\"property9\":\"" + property9 + "\"";
+            }
+            else
+            {
+                profileStr += ",\"property9\":" + property9;
+            }
+            if (property10 is string)
+            {
+                profileStr += ",\"property10\":\"" + property10 + "\"";
+            }
+            else
+            {
+                profileStr += ",\"property10\":" + property10;
+            }
+            profileStr += "}";
+            return profileStr;
+        }
+        return null;
+    }
+#endif
+}

+ 11 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataProfile.cs.meta

@@ -0,0 +1,11 @@
+fileFormatVersion: 2
+guid: WnsZ4SmoVipELlyOjwAfMmTYo/CeBMP1I1BYiBLdoAgCS74hSysz7C0schwM
+MonoImporter:
+  externalObjects: {}
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 1066 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataSDK.cs

@@ -0,0 +1,1066 @@
+// version: 5.0.4
+
+using UnityEngine;
+using System.Collections.Generic;
+#if UNITY_ANDROID
+using System;
+#endif
+#if UNITY_IPHONE
+using System.Runtime.InteropServices;
+using System.Collections;
+#endif
+
+
+public static class TalkingDataSDK
+{
+#if UNITY_ANDROID
+    private static readonly string TALKINGDATA_CLASS = "com.tendcloud.tenddata.TalkingDataSDK";
+    private static AndroidJavaClass talkingdataClass;
+    private static AndroidJavaClass unityPlayerClass;
+#endif
+
+#if UNITY_IPHONE
+    [DllImport("__Internal")]
+    private static extern void TDInitSDK(string appId, string channelId, string custom);
+
+    [DllImport("__Internal")]
+    private static extern void TDStartA();
+
+    [DllImport("__Internal")]
+    private static extern void TDBackgroundSessionEnabled();
+
+    [DllImport("__Internal")]
+    private static extern string TDGetDeviceId();
+
+    [DllImport("__Internal")] 
+    private static extern void TDSetVerboseLogDisable();
+
+    [DllImport("__Internal")]
+    private static extern void TDSetLocation(double latitude, double longitude);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnPageBegin(string pageName);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnPageEnd(string pageName);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnReceiveDeepLink(string url);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnRegister(string profileId, string profileJson, string invitationCode, string eventValueJson);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnLogin(string profileId, string profileJson, string eventValueJson);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnProfileUpdate(string profileJson);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnCreateCard(string profileId, string method, string content);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnFavorite(string category, string content, string eventValueJson);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnShare(string profileId, string content, string eventValueJson);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnPunch(string profileId, string punchId);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnSearch(string searchJson);
+
+#if TD_RETAIL || TD_FINANCE || TD_TOUR || TD_ONLINEEDU
+    [DllImport("__Internal")]
+    private static extern void TDOnContact(string profileId, string content);
+#endif
+
+#if TD_GAME || TD_TOUR || TD_ONLINEEDU || TD_READING || TD_OTHER
+    [DllImport("__Internal")]
+    private static extern void TDOnPay(string profileId, string orderId, int amount, string currencyType, string paymentType, string itemId, int itemCount);
+#endif
+
+#if TD_RETAIL || TD_FINANCE || TD_TOUR || TD_ONLINEEDU
+    [DllImport("__Internal")]
+    private static extern void TDOnChargeBack(string profileId, string orderId, string reason, string type);
+#endif
+
+#if TD_FINANCE || TD_ONLINEEDU
+    [DllImport("__Internal")]
+    private static extern void TDOnReservation(string profileId, string reservationId, string category, int amount, string term);
+#endif
+
+#if TD_RETAIL || TD_TOUR
+    [DllImport("__Internal")]
+    private static extern void TDOnBooking(string profileId, string bookingId, string category, int amount, string content);
+#endif
+
+#if TD_RETAIL
+    [DllImport("__Internal")]
+    private static extern void TDOnViewItem(string itemId, string category, string name, int unitPrice, string eventValueJson);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnAddItemToShoppingCart(string item, string category, string name, int unitPrice, int amount, string eventValueJson);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnViewShoppingCart(string shoppingCartJson);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnPlaceOrder(string orderJson, string profileId, string eventValueJson);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnOrderPaySucc(string orderJson, string paymentType, string profileId);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnCancelOrder(string orderJson);
+#endif
+
+#if TD_FINANCE
+    [DllImport("__Internal")]
+    private static extern void TDOnCredit(string profileId, int amount, string content);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnTransaction(string profileId, string transactionJson);
+#endif
+
+#if TD_GAME
+    [DllImport("__Internal")]
+    private static extern void TDOnCreateRole(string name);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnLevelPass(string profileId, string levelId);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnGuideFinished(string profileId, string content);
+#endif
+
+#if TD_ONLINEEDU
+    [DllImport("__Internal")]
+    private static extern void TDOnLearn(string profileId, string course, long begin, int duration);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnPreviewFinished(string profileId, string content);
+#endif
+
+#if TD_READING
+    [DllImport("__Internal")]
+    private static extern void TDOnRead(string profileId, string book, long begin, int duration);
+
+    [DllImport("__Internal")]
+    private static extern void TDOnFreeFinished(string profileId, string content);
+#endif
+
+#if TD_GAME || TD_ONLINEEDU
+    [DllImport("__Internal")]
+    private static extern void TDOnAchievementUnlock(string profileId, string achievementId);
+#endif
+
+#if TD_FINANCE || TD_TOUR || TD_OTHER
+    [DllImport("__Internal")]
+    private static extern void TDOnBrowse(string profileId, string content, long begin, int duration);
+#endif
+
+#if TD_RETAIL || TD_FINANCE || TD_TOUR || TD_OTHER
+    [DllImport("__Internal")]
+    private static extern void TDOnTrialFinished(string profileId, string content);
+#endif
+
+    [DllImport("__Internal")]
+    private static extern void TDOnEvent(string eventId, string parameters, string eventValueJson);
+
+    [DllImport("__Internal")]
+    private static extern void TDSetGlobalKV(string key, string strVal, double numVal);
+
+    [DllImport("__Internal")]
+    private static extern void TDRemoveGlobalKV(string key);
+#endif
+
+#if UNITY_ANDROID
+    private static AndroidJavaObject GetCurrentActivity()
+    {
+        if (unityPlayerClass == null)
+        {
+            unityPlayerClass = new AndroidJavaClass("com.unity3d.player.UnityPlayer");
+        }
+        AndroidJavaObject activity = unityPlayerClass.GetStatic<AndroidJavaObject>("currentActivity");
+        return activity;
+    }
+
+    private static AndroidJavaObject DictionaryToAndroidMap(Dictionary<string, object> parameters)
+    {
+        AndroidJavaObject map = null;
+        if (parameters != null && parameters.Count > 0)
+        {
+            int count = parameters.Count;
+            map = new AndroidJavaObject("java.util.HashMap", count);
+            IntPtr method_Put = AndroidJNIHelper.GetMethodID(map.GetRawClass(), "put", "(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;");
+            object[] args = new object[2];
+            foreach (KeyValuePair<string, object> kvp in parameters)
+            {
+                args[0] = new AndroidJavaObject("java.lang.String", kvp.Key);
+                args[1] = typeof(string).IsInstanceOfType(kvp.Value)
+                    ? new AndroidJavaObject("java.lang.String", kvp.Value)
+                    : new AndroidJavaObject("java.lang.Double", "" + kvp.Value);
+                AndroidJNI.CallObjectMethod(map.GetRawObject(), method_Put, AndroidJNIHelper.CreateJNIArgArray(args));
+            }
+        }
+        return map;
+    }
+#endif
+
+#if UNITY_IPHONE
+    private static string DictionaryToJSONString(Dictionary<string, object> parameters)
+    {
+        string json = null;
+        if (parameters != null && parameters.Count > 0)
+        {
+            json = "{";
+            foreach (KeyValuePair<string, object> kvp in parameters)
+            {
+                if (kvp.Value is string)
+                {
+                    json += "\"" + kvp.Key + "\":\"" + kvp.Value + "\",";
+                }
+                else
+                {
+                    try
+                    {
+                        double tmp = System.Convert.ToDouble(kvp.Value);
+                        json += "\"" + kvp.Key + "\":" + tmp + ",";
+                    }
+                    catch (System.Exception)
+                    {
+                    }
+                }
+            }
+            json = json.TrimEnd(',');
+            json += "}";
+        }
+        return json;
+    }
+#endif
+
+    public static void SetConfig(TalkingDataSDKConfig config)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass == null)
+            {
+                talkingdataClass = new AndroidJavaClass(TALKINGDATA_CLASS);
+            }
+            talkingdataClass.CallStatic("setConfig", config.javaObj);
+#endif
+        }
+    }
+
+    public static void InitSDK(string appId, string channelId, string custom)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+            Debug.Log("TalkingData Unity SDK.");
+#if UNITY_ANDROID
+            using (AndroidJavaClass dz = new AndroidJavaClass("com.tendcloud.tenddata.dz"))
+            {
+                dz.SetStatic("a", 2);
+            }
+            if (talkingdataClass == null)
+            {
+                talkingdataClass = new AndroidJavaClass(TALKINGDATA_CLASS);
+            }
+            AndroidJavaObject activity = GetCurrentActivity();
+            talkingdataClass.CallStatic("initSDK", activity, appId, channelId, custom);
+#endif
+#if UNITY_IPHONE
+            TDInitSDK(appId, channelId, custom);
+#endif
+        }
+    }
+
+    public static void StartA()
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                AndroidJavaObject activity = GetCurrentActivity();
+                talkingdataClass.CallStatic("startA", activity);
+                talkingdataClass.CallStatic("onResume", activity);
+            }
+#endif
+#if UNITY_IPHONE
+            TDStartA();
+#endif
+        }
+    }
+
+    public static void OnPause()
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onPause", GetCurrentActivity());
+            }
+#endif
+        }
+    }
+
+    public static void BackgroundSessionEnabled()
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_IPHONE
+            TDBackgroundSessionEnabled();
+#endif
+        }
+    }
+
+    private static string deviceId = null;
+    public static string GetDeviceId()
+    {
+        if (deviceId == null && Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass == null)
+            {
+                talkingdataClass = new AndroidJavaClass(TALKINGDATA_CLASS);
+            }
+            deviceId = talkingdataClass.CallStatic<string>("getDeviceId", GetCurrentActivity());
+#endif
+#if UNITY_IPHONE
+            deviceId = TDGetDeviceId();
+#endif
+        }
+        return deviceId;
+    }
+
+    private static string oaid = null;
+    public static string GetOAID()
+    {
+        if (oaid == null && Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass == null)
+            {
+                talkingdataClass = new AndroidJavaClass(TALKINGDATA_CLASS);
+            }
+            oaid = talkingdataClass.CallStatic<string>("getOAID", GetCurrentActivity());
+#endif
+        }
+        return oaid;
+    }
+
+    public static void SetVerboseLogDisable()
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass == null)
+            {
+                talkingdataClass = new AndroidJavaClass(TALKINGDATA_CLASS);
+            }
+            talkingdataClass.CallStatic("setVerboseLogDisable");
+#endif
+#if UNITY_IPHONE
+            TDSetVerboseLogDisable();
+#endif
+        }
+    }
+
+    public static void SetLocation(double latitude, double longitude)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_IPHONE
+            TDSetLocation(latitude, longitude);
+#endif
+        }
+    }
+
+    public static void OnPageBegin(string pageName)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onPageBegin", GetCurrentActivity(), pageName);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnPageBegin(pageName);
+#endif
+        }
+    }
+
+    public static void OnPageEnd(string pageName)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onPageEnd", GetCurrentActivity(), pageName);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnPageEnd(pageName);
+#endif
+        }
+    }
+
+    public static void OnReceiveDeepLink(string url)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onReceiveDeepLink", url);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnReceiveDeepLink(url);
+#endif
+        }
+    }
+
+    public static void OnRegister(string profileId, TalkingDataProfile profile, string invitationCode, Dictionary<string, object> eventValue)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                AndroidJavaObject eventValueMap = DictionaryToAndroidMap(eventValue);
+                talkingdataClass.CallStatic("onRegister", profileId, profile.javaObj, invitationCode, eventValueMap);
+                if (eventValueMap != null)
+                {
+                    eventValueMap.Dispose();
+                }
+            }
+#endif
+#if UNITY_IPHONE
+            string eventValueJson = DictionaryToJSONString(eventValue);
+            TDOnRegister(profileId, profile.ToString(), invitationCode, eventValueJson);
+#endif
+        }
+    }
+
+    public static void OnLogin(string profileId, TalkingDataProfile profile, Dictionary<string, object> eventValue)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                AndroidJavaObject eventValueMap = DictionaryToAndroidMap(eventValue);
+                talkingdataClass.CallStatic("onLogin", profileId, profile.javaObj, eventValueMap);
+                if (eventValueMap != null)
+                {
+                    eventValueMap.Dispose();
+                }
+            }
+#endif
+#if UNITY_IPHONE
+            string eventValueJson = DictionaryToJSONString(eventValue);
+            TDOnLogin(profileId, profile.ToString(), eventValueJson);
+#endif
+        }
+    }
+
+    public static void OnProfileUpdate(TalkingDataProfile profile)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onProfileUpdate", profile.javaObj);
+            }
+#endif
+#if  UNITY_IPHONE
+            TDOnProfileUpdate(profile.ToString());
+#endif
+        }
+    }
+    public static void OnCreateCard(string profileId, string method, string content)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onCreateCard", profileId, method, content);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnCreateCard(profileId, method, content);
+#endif
+        }
+    }
+
+    public static void OnFavorite(string category, string content, Dictionary<string, object> eventValue)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                AndroidJavaObject eventValueMap = DictionaryToAndroidMap(eventValue);
+                talkingdataClass.CallStatic("onFavorite", category, content, eventValueMap);
+                if (eventValueMap != null)
+                {
+                    eventValueMap.Dispose();
+                }
+            }
+#endif
+#if UNITY_IPHONE
+            string eventValueJson = DictionaryToJSONString(eventValue);
+            TDOnFavorite(category, content, eventValueJson);
+#endif
+        }
+    }
+
+    public static void OnShare(string profileId, string content, Dictionary<string, object> eventValue)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                AndroidJavaObject eventValueMap = DictionaryToAndroidMap(eventValue);
+                talkingdataClass.CallStatic("onShare", profileId, content, eventValueMap);
+                if (eventValueMap != null)
+                {
+                    eventValueMap.Dispose();
+                }
+            }
+#endif
+#if UNITY_IPHONE
+            string eventValueJson = DictionaryToJSONString(eventValue);
+            TDOnShare(profileId, content, eventValueJson);
+#endif
+        }
+    }
+
+    public static void OnPunch(string profileId, string punchId)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onPunch", profileId, punchId);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnPunch(profileId, punchId);
+#endif
+        }
+    }
+
+    public static void OnSearch(TalkingDataSearch search)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onSearch", search.javaObj);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnSearch(search.ToString());
+#endif
+        }
+    }
+
+#if TD_RETAIL || TD_FINANCE || TD_TOUR || TD_ONLINEEDU
+    public static void OnContact(string profileId, string content)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onContact", profileId, content);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnContact(profileId, content);
+#endif
+        }
+    }
+#endif
+
+#if TD_GAME || TD_TOUR || TD_ONLINEEDU || TD_READING || TD_OTHER
+    public static void OnPay(string profileId, string orderId, int amount, string currencyType, string paymentType, string itemId, int itemCount)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onPay", profileId, orderId, amount, currencyType, paymentType, itemId, itemCount);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnPay(profileId, orderId, amount, currencyType, paymentType, itemId, itemCount);
+#endif
+        }
+    }
+#endif
+
+#if TD_RETAIL || TD_FINANCE || TD_TOUR || TD_ONLINEEDU
+    public static void OnChargeBack(string profileId, string orderId, string reason, string type)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onChargeBack", profileId, orderId, reason, type);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnChargeBack(profileId, orderId, reason, type);
+#endif
+        }
+    }
+#endif
+
+#if TD_FINANCE || TD_ONLINEEDU
+    public static void OnReservation(string profileId, string reservationId, string category, int amount, string term)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onReservation", profileId, reservationId, category, amount, term);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnReservation(profileId, reservationId, category, amount, term);
+#endif
+        }
+    }
+#endif
+
+#if TD_RETAIL || TD_TOUR
+    public static void OnBooking(string profileId, string bookingId, string category, int amount, string content)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onBooking", profileId, bookingId, category, amount, content);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnBooking(profileId, bookingId, category, amount, content);
+#endif
+        }
+    }
+#endif
+
+#if TD_RETAIL
+    public static void OnViewItem(string itemId, string category, string name, int unitPrice, Dictionary<string, object> eventValue)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                AndroidJavaObject eventValueMap = DictionaryToAndroidMap(eventValue);
+                talkingdataClass.CallStatic("onViewItem", itemId, category, name, unitPrice, eventValueMap);
+                if (eventValueMap != null)
+                {
+                    eventValueMap.Dispose();
+                }
+            }
+#endif
+#if UNITY_IPHONE
+            string eventValueJson = DictionaryToJSONString(eventValue);
+            TDOnViewItem(itemId, category, name, unitPrice, eventValueJson);
+#endif
+        }
+    }
+
+    public static void OnAddItemToShoppingCart(string itemId, string category, string name, int unitPrice, int amount, Dictionary<string, object> eventValue)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                AndroidJavaObject eventValueMap = DictionaryToAndroidMap(eventValue);
+                talkingdataClass.CallStatic("onAddItemToShoppingCart", itemId, category, name, unitPrice, amount, eventValueMap);
+                if (eventValueMap != null)
+                {
+                    eventValueMap.Dispose();
+                }
+            }
+#endif
+#if UNITY_IPHONE
+            string eventValueJson = DictionaryToJSONString(eventValue);
+            TDOnAddItemToShoppingCart(itemId, category, name, unitPrice, amount, eventValueJson);
+#endif
+        }
+    }
+
+    public static void OnViewShoppingCart(TalkingDataShoppingCart shoppingCart)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onViewShoppingCart", shoppingCart.javaObj);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnViewShoppingCart(shoppingCart.ToString());
+#endif
+        }
+    }
+
+    public static void OnPlaceOrder(TalkingDataOrder order, string profileId, Dictionary<string, object> eventValue)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                AndroidJavaObject eventValueMap = DictionaryToAndroidMap(eventValue);
+                talkingdataClass.CallStatic("onPlaceOrder", order.javaObj, profileId, eventValueMap);
+                if (eventValueMap != null)
+                {
+                    eventValueMap.Dispose();
+                }
+            }
+#endif
+#if UNITY_IPHONE
+            string eventValueJson = DictionaryToJSONString(eventValue);
+            TDOnPlaceOrder(order.ToString(), profileId, eventValueJson);
+#endif
+        }
+    }
+
+    public static void OnOrderPaySucc(TalkingDataOrder order, string paymentType, string profileId)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onOrderPaySucc", order.javaObj, paymentType, profileId);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnOrderPaySucc(order.ToString(), paymentType, profileId);
+#endif
+        }
+    }
+
+    public static void OnCancelOrder(TalkingDataOrder order)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onCancelOrder", order.javaObj);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnCancelOrder(order.ToString());
+#endif
+        }
+    }
+#endif
+
+#if TD_FINANCE
+    public static void OnCredit(string profileId, int amount, string content)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onCredit", profileId, amount, content);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnCredit(profileId, amount, content);
+#endif
+        }
+    }
+
+    public static void OnTransaction(string profileId, TalkingDataTransaction transaction)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onTransaction", profileId, transaction.javaObj);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnTransaction(profileId, transaction.ToString());
+#endif
+        }
+    }
+#endif
+
+#if TD_GAME
+    public static void OnCreateRole(string name)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onCreateRole", name);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnCreateRole(name);
+#endif
+        }
+    }
+
+    public static void OnLevelPass(string profileId, string levelId)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onLevelPass", profileId, levelId);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnLevelPass(profileId, levelId);
+#endif
+        }
+    }
+
+    public static void OnGuideFinished(string profileId, string content)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onGuideFinished", profileId, content);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnGuideFinished(profileId, content);
+#endif
+        }
+    }
+#endif
+
+#if TD_ONLINEEDU
+    public static void OnLearn(string profileId, string course, long begin, int duration)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onLearn", profileId, course, begin, duration);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnLearn(profileId, course, begin, duration);
+#endif
+        }
+    }
+
+    public static void OnPreviewFinished(string profileId, string content)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onPreviewFinished", profileId, content);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnPreviewFinished(profileId, content);
+#endif
+        }
+    }
+#endif
+
+#if TD_READING
+    public static void OnRead(string profileId, string book, long begin, int duration)
+     {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onRead", profileId, book, begin, duration);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnRead(profileId, book, begin, duration);
+#endif
+        }
+    }
+
+    public static void OnFreeFinished(string profileId, string content)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onFreeFinished", profileId, content);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnFreeFinished(profileId, content);
+#endif
+        }
+    }
+#endif
+
+#if TD_GAME || TD_ONLINEEDU
+    public static void OnAchievementUnlock(string profileId, string achievementId)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onAchievementUnlock", profileId, achievementId);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnAchievementUnlock(profileId, achievementId);
+#endif
+        }
+    }
+#endif
+
+#if TD_FINANCE || TD_TOUR || TD_OTHER
+    public static void OnBrowse(string profileId, string content, long begin, int duration)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onBrowse", profileId, content, begin, duration);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnBrowse(profileId, content, begin, duration);
+#endif
+        }
+    }
+#endif
+
+#if TD_RETAIL || TD_FINANCE || TD_TOUR || TD_OTHER
+    public static void OnTrialFinished(string profileId, string content)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("onTrialFinished", profileId, content);
+            }
+#endif
+#if UNITY_IPHONE
+            TDOnTrialFinished(profileId, content);
+#endif
+        }
+    }
+#endif
+
+    public static void OnEvent(string eventId, Dictionary<string, object> parameters, Dictionary<string, object> eventValue)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                AndroidJavaObject parametersMap = DictionaryToAndroidMap(parameters);
+                AndroidJavaObject eventValueMap = DictionaryToAndroidMap(eventValue);
+                talkingdataClass.CallStatic("onEvent", GetCurrentActivity(), eventId, parametersMap, eventValueMap);
+                if (parametersMap != null)
+                {
+                    parametersMap.Dispose();
+                }
+                if (eventValueMap != null)
+                {
+                    eventValueMap.Dispose();
+                }
+            }
+#endif
+#if UNITY_IPHONE
+            string parametersJson = DictionaryToJSONString(parameters);
+            string eventValueJson = DictionaryToJSONString(eventValue);
+            TDOnEvent(eventId, parametersJson, eventValueJson);
+#endif
+        }
+    }
+
+    public static void SetGlobalKV(string key, object val)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                AndroidJavaObject valObject = typeof(string).IsInstanceOfType(val)
+                                            ? new AndroidJavaObject("java.lang.String", val)
+                                            : new AndroidJavaObject("java.lang.Double", "" + val);
+                talkingdataClass.CallStatic("setGlobalKV", key, valObject);
+            }
+#endif
+#if UNITY_IPHONE
+            if (val is string)
+            {
+                string tmp = System.Convert.ToString(val);
+                TDSetGlobalKV(key, tmp, 0);
+            }
+            else
+            {
+                double tmp = System.Convert.ToDouble(val);
+                TDSetGlobalKV(key, null, tmp);
+            }
+#endif
+        }
+    }
+
+    public static void RemoveGlobalKV(string key)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (talkingdataClass != null)
+            {
+                talkingdataClass.CallStatic("removeGlobalKV", key);
+            }
+#endif
+#if UNITY_IPHONE
+            TDRemoveGlobalKV(key);
+#endif
+        }
+    }
+}

+ 11 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataSDK.cs.meta

@@ -0,0 +1,11 @@
+fileFormatVersion: 2
+guid: CH9OsH6kUnN53Bo8dS2tEdORBWShDjUiXAGnyZTxnvGuXH/OhEVII2XPgkHN
+MonoImporter:
+  externalObjects: {}
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 80 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataSDKConfig.cs

@@ -0,0 +1,80 @@
+using UnityEngine;
+
+
+public class TalkingDataSDKConfig
+{
+    public AndroidJavaObject javaObj;
+
+    public static TalkingDataSDKConfig CreateConfig()
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+            TalkingDataSDKConfig config = new TalkingDataSDKConfig();
+#if UNITY_ANDROID
+            config.javaObj = new AndroidJavaObject("com.tendcloud.tenddata.TalkingDataSDKConfig");
+#endif
+            return config;
+        }
+        return null;
+    }
+
+    public TalkingDataSDKConfig SetIMEIAndMEIDEnabled(bool enabled)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            javaObj.Call<AndroidJavaObject>("setIMEIAndMEIDEnabled", enabled);
+#endif
+            return this;
+        }
+        return null;
+    }
+
+    public TalkingDataSDKConfig SetMACEnabled(bool enabled)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            javaObj.Call<AndroidJavaObject>("setMACEnabled", enabled);
+#endif
+            return this;
+        }
+        return null;
+    }
+
+    public TalkingDataSDKConfig SetAppListEnabled(bool enabled)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            javaObj.Call<AndroidJavaObject>("setAppListEnabled", enabled);
+#endif
+            return this;
+        }
+        return null;
+    }
+
+    public TalkingDataSDKConfig SetLocationEnabled(bool enabled)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            javaObj.Call<AndroidJavaObject>("setLocationEnabled", enabled);
+#endif
+            return this;
+        }
+        return null;
+    }
+
+    public TalkingDataSDKConfig SetWifiEnabled(bool enabled)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            javaObj.Call<AndroidJavaObject>("setWifiEnabled", enabled);
+#endif
+            return this;
+        }
+        return null;
+    }
+}

+ 11 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataSDKConfig.cs.meta

@@ -0,0 +1,11 @@
+fileFormatVersion: 2
+guid: WXtL5CmrBn6b7K/dXRdlliGWWHvMednLd2Hv9KXBkuCi+AfQp7huN8o2ora6
+MonoImporter:
+  externalObjects: {}
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 210 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataSearch.cs

@@ -0,0 +1,210 @@
+using UnityEngine;
+
+
+public class TalkingDataSearch
+{
+#if UNITY_ANDROID
+    public AndroidJavaObject javaObj;
+#endif
+
+#if UNITY_IPHONE
+    private string category;
+    private string content;
+#if TD_RETAIL
+    private string itemId;
+    private string itemLocationId;
+#endif
+#if TD_TOUR
+    private string destination;
+    private string origin;
+    private long startDate;
+    private long endDate;
+#endif
+#endif
+
+    public static TalkingDataSearch CreateSearch()
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+            TalkingDataSearch search = new TalkingDataSearch();
+#if UNITY_ANDROID
+            AndroidJavaClass javaClass = new AndroidJavaClass("com.tendcloud.tenddata.TalkingDataSearch");
+            search.javaObj = javaClass.CallStatic<AndroidJavaObject>("createSearch");
+#endif
+            return search;
+        }
+        return null;
+    }
+
+    // 搜索分类
+    public TalkingDataSearch SetCategory(string category)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setCategory", category);
+            }
+#endif
+#if UNITY_IPHONE
+            this.category = category;
+#endif
+        }
+        return this;
+    }
+
+    // 搜索内容
+    public TalkingDataSearch SetContent(string content)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setContent", content);
+            }
+#endif
+#if UNITY_IPHONE
+            this.content = content;
+#endif
+        }
+        return this;
+    }
+
+#if TD_RETAIL
+    // 商品 ID(eg.酒店/汽车);至多64字符,支持数字+字母
+    public TalkingDataSearch SetItemId(string itemId)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setItemId", itemId);
+            }
+#endif
+#if UNITY_IPHONE
+            this.itemId = itemId;
+#endif
+        }
+        return this;
+    }
+
+    // 商品位置 ID(eg.求职招聘/教育行业);至多64字符,支持数字+字母
+    public TalkingDataSearch SetItemLocationId(string itemLocationId)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setItemLocationId", itemLocationId);
+            }
+#endif
+#if UNITY_IPHONE
+            this.itemLocationId = itemLocationId;
+#endif
+        }
+        return this;
+    }
+#endif
+
+#if TD_TOUR
+    // 目的地城市 ID;至多64字符,支持数字+字母
+    public TalkingDataSearch SetDestination(string destination)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setDestination", destination);
+            }
+#endif
+#if UNITY_IPHONE
+            this.destination = destination;
+#endif
+        }
+        return this;
+    }
+
+    // 出发地城市 ID;至多64字符,支持数字+字母
+    public TalkingDataSearch SetOrigin(string origin)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setOrigin", origin);
+            }
+#endif
+#if UNITY_IPHONE
+            this.origin = origin;
+#endif
+        }
+        return this;
+    }
+
+    // 业务事件起始日期(eg.航班出发日期)
+    public TalkingDataSearch SetStartDate(long startDate)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setStartDate", startDate);
+            }
+#endif
+#if UNITY_IPHONE
+            this.startDate = startDate;
+#endif
+        }
+        return this;
+    }
+
+    // 业务事件截止日期(eg.航班返程日期)
+    public TalkingDataSearch SetEndDate(long endDate)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setEndDate", endDate);
+            }
+#endif
+#if UNITY_IPHONE
+            this.endDate = endDate;
+#endif
+        }
+        return this;
+    }
+#endif
+
+#if UNITY_IPHONE
+    public override string ToString()
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+            string searchStr = "{\"category\":\"" + category + "\""
+                             + ",\"content\":\"" + content + "\""
+#if TD_RETAIL
+                             + ",\"itemId\":\"" + itemId + "\""
+                             + ",\"itemLocationId\":\"" + itemLocationId + "\""
+#endif
+#if TD_TOUR
+                             + ",\"destination\":\"" + destination + "\""
+                             + ",\"origin\":\"" + origin + "\""
+                             + ",\"startDate\":" + startDate
+                             + ",\"endDate\":" + endDate
+#endif
+                             + "}";
+            return searchStr;
+        }
+        return null;
+    }
+#endif
+}

+ 11 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataSearch.cs.meta

@@ -0,0 +1,11 @@
+fileFormatVersion: 2
+guid: WXJNt3n8VCi/Y8BcyJD1D4QxcgOFoqHzR6elP/aiv5liSEs56XuwlO3+oe5K
+MonoImporter:
+  externalObjects: {}
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 63 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataShoppingCart.cs

@@ -0,0 +1,63 @@
+using UnityEngine;
+
+
+#if TD_RETAIL
+public class TalkingDataShoppingCart
+{
+#if UNITY_ANDROID
+    public AndroidJavaObject javaObj;
+#endif
+
+#if UNITY_IPHONE
+    private string items = "";
+#endif
+
+    public static TalkingDataShoppingCart CreateShoppingCart()
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+            TalkingDataShoppingCart shoppingCart = new TalkingDataShoppingCart();
+#if UNITY_ANDROID
+            AndroidJavaClass javaClass = new AndroidJavaClass("com.tendcloud.tenddata.TalkingDataShoppingCart");
+            shoppingCart.javaObj = javaClass.CallStatic<AndroidJavaObject>("createShoppingCart");
+#endif
+            return shoppingCart;
+        }
+        return null;
+    }
+
+    public TalkingDataShoppingCart AddItem(string itemId, string category, string name, int unitPrice, int amount)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("addItem", itemId, category, name, unitPrice, amount);
+            }
+#endif
+#if UNITY_IPHONE
+            string item = "{\"itemId\":\"" + itemId + "\",\"category\":\"" + category + "\",\"name\":\"" + name + "\",\"unitPrice\":" + unitPrice + ",\"amount\":" + amount + "}";
+            if (items.Length > 0)
+            {
+                items += ",";
+            }
+            items += item;
+#endif
+        }
+        return this;
+    }
+
+#if UNITY_IPHONE
+    public override string ToString()
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+            string orderStr = "{\"items\":[" + items + "]}";
+            return orderStr;
+        }
+        return null;
+    }
+#endif
+}
+#endif

+ 11 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataShoppingCart.cs.meta

@@ -0,0 +1,11 @@
+fileFormatVersion: 2
+guid: DShL4S2kAS73tH5SOApmSCIaDTpHPxDtpmPSdAcX7oZn6Mx1SVXhD0b0W4J0
+MonoImporter:
+  externalObjects: {}
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 220 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataTransaction.cs

@@ -0,0 +1,220 @@
+using UnityEngine;
+
+
+#if TD_FINANCE
+public class TalkingDataTransaction
+{
+#if UNITY_ANDROID
+    public AndroidJavaObject javaObj;
+#endif
+
+#if UNITY_IPHONE
+    private string transactionId;
+    private string category;
+    private int amount;
+    private string personA;
+    private string personB;
+    private long startDate;
+    private long endDate;
+    private string currencyType;
+    private string content;
+#endif
+
+    public static TalkingDataTransaction CreateTransaction()
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+            TalkingDataTransaction transaction = new TalkingDataTransaction();
+#if UNITY_ANDROID
+            AndroidJavaClass javaClass = new AndroidJavaClass("com.tendcloud.tenddata.TalkingDataTransaction");
+            transaction.javaObj = javaClass.CallStatic<AndroidJavaObject>("createTransaction");
+#endif
+            return transaction;
+        }
+        return null;
+    }
+
+    // 交易ID
+    public TalkingDataTransaction SetTransactionId(string transactionId)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setTransactionId", transactionId);
+            }
+#endif
+#if UNITY_IPHONE
+            this.transactionId = transactionId;
+#endif
+        }
+        return this;
+    }
+
+    // 交易分类
+    public TalkingDataTransaction SetCategory(string category)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setCategory", category);
+            }
+#endif
+#if UNITY_IPHONE
+            this.category = category;
+#endif
+        }
+        return this;
+    }
+
+    // 交易额
+    public TalkingDataTransaction SetAmount(int amount)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setAmount", amount);
+            }
+#endif
+#if UNITY_IPHONE
+            this.amount = amount;
+#endif
+        }
+        return this;
+    }
+
+    // 交易甲方
+    public TalkingDataTransaction SetPersonA(string personA)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setPersonA", personA);
+            }
+#endif
+#if UNITY_IPHONE
+            this.personA = personA;
+#endif
+        }
+        return this;
+    }
+
+    // 交易乙方
+    public TalkingDataTransaction SetPersonB(string personB)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setPersonB", personB);
+            }
+#endif
+#if UNITY_IPHONE
+            this.personB = personB;
+#endif
+        }
+        return this;
+    }
+
+    // 交易起始Unix时间戳。单位:毫秒
+    public TalkingDataTransaction SetStartDate(long startDate)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setStartDate", startDate);
+            }
+#endif
+#if UNITY_IPHONE
+            this.startDate = startDate;
+#endif
+        }
+        return this;
+    }
+
+    // 交易终止Unix时间戳。单位:毫秒
+    public TalkingDataTransaction SetEndDate(long endDate)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setEndDate", endDate);
+            }
+#endif
+#if UNITY_IPHONE
+            this.endDate = endDate;
+#endif
+        }
+        return this;
+    }
+
+    // 货币类型
+    public TalkingDataTransaction SetCurrencyType(string currencyType)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setCurrencyType", currencyType);
+            }
+#endif
+#if UNITY_IPHONE
+            this.currencyType = currencyType;
+#endif
+        }
+        return this;
+    }
+
+    // 交易详情
+    public TalkingDataTransaction SetContent(string content)
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+#if UNITY_ANDROID
+            if (javaObj != null)
+            {
+                javaObj.Call<AndroidJavaObject>("setContent", content);
+            }
+#endif
+#if UNITY_IPHONE
+            this.content = content;
+#endif
+        }
+        return this;
+    }
+
+#if UNITY_IPHONE
+    public override string ToString()
+    {
+        if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
+        {
+            string transactionStr = "{\"transactionId\":\"" + transactionId + "\""
+                                  + ",\"category\":\"" + category + "\""
+                                  + ",\"amount\":" + amount
+                                  + ",\"personA\":\"" + personA + "\""
+                                  + ",\"personB\":\"" + personB + "\""
+                                  + ",\"startDate\":" + startDate
+                                  + ",\"endDate\":" + endDate
+                                  + ",\"currencyType\":\"" + currencyType + "\""
+                                  + ",\"content\":\"" + content + "\""
+                                  + "}";
+            return transactionStr;
+        }
+        return null;
+    }
+#endif
+}
+#endif

+ 11 - 0
Assets/Scripts/ThirdParty/TalkingDataScripts/TalkingDataTransaction.cs.meta

@@ -0,0 +1,11 @@
+fileFormatVersion: 2
+guid: Bi8dvCyvVy5dVTCHE6ZvgxXMWE8Mw7Lqin3HmXqMWWu5Wmqq2iYJZ+h2l7if
+MonoImporter:
+  externalObjects: {}
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

文件差異過大導致無法顯示
+ 0 - 0
Assets/StreamingAssets/assetConfig.txt


+ 1 - 1
Assets/StreamingAssets/assetMD5.txt

@@ -1 +1 @@
-638978564742007607
+638986379954365424

+ 1 - 1
ProjectSettings/HybridCLRSettings.asset

@@ -12,7 +12,7 @@ MonoBehaviour:
   m_Script: {fileID: 11500000, guid: e189374413a3f00468e49d51d8b27a09, type: 3}
   m_Name: 
   m_EditorClassIdentifier: 
-  enable: 1
+  enable: 0
   useGlobalIl2cpp: 0
   hybridclrRepoURL: https://gitee.com/focus-creative-games/hybridclr
   il2cppPlusRepoURL: https://gitee.com/focus-creative-games/il2cpp_plus

+ 2 - 2
ProjectSettings/ProjectSettings.asset

@@ -303,7 +303,7 @@ PlayerSettings:
   AndroidEnableTango: 0
   androidEnableBanner: 1
   androidUseLowAccuracyLocation: 0
-  androidUseCustomKeystore: 1
+  androidUseCustomKeystore: 0
   m_AndroidBanners:
   - width: 320
     height: 180
@@ -805,7 +805,7 @@ PlayerSettings:
   webGLMemoryGeometricGrowthCap: 96
   webGLPowerPreference: 2
   scriptingDefineSymbols:
-    Android: KAMGAM_SKY_CLOUDS_URP;AMPLIFY_SHADER_EDITOR;Google;Ads
+    Android: KAMGAM_SKY_CLOUDS_URP;AMPLIFY_SHADER_EDITOR
     ArmLinux: KAMGAM_SKY_CLOUDS_URP
     ArmLinuxServer: KAMGAM_SKY_CLOUDS_URP
     EmbeddedLinux: KAMGAM_SKY_CLOUDS_URP

+ 269 - 51
UserSettings/Layouts/default-2022.dwlt

@@ -1,6 +1,54 @@
 %YAML 1.1
 %TAG !u! tag:yousandi.cn,2023:
 --- !u!114 &1
+MonoBehaviour:
+  m_ObjectHideFlags: 52
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 0}
+  m_Enabled: 1
+  m_EditorHideFlags: 0
+  m_Script: {fileID: 12004, guid: 0000000000000000e000000000000000, type: 0}
+  m_Name: 
+  m_EditorClassIdentifier: 
+  m_PixelRect:
+    serializedVersion: 2
+    x: -2438
+    y: 571
+    width: 1702
+    height: 645
+  m_ShowMode: 0
+  m_Title: Console
+  m_RootView: {fileID: 5}
+  m_MinSize: {x: 100, y: 121}
+  m_MaxSize: {x: 4000, y: 4021}
+  m_Maximized: 0
+--- !u!114 &2
+MonoBehaviour:
+  m_ObjectHideFlags: 52
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 0}
+  m_Enabled: 1
+  m_EditorHideFlags: 0
+  m_Script: {fileID: 12004, guid: 0000000000000000e000000000000000, type: 0}
+  m_Name: 
+  m_EditorClassIdentifier: 
+  m_PixelRect:
+    serializedVersion: 2
+    x: -2810
+    y: 694
+    width: 2560
+    height: 685
+  m_ShowMode: 0
+  m_Title: ' Hot Reload'
+  m_RootView: {fileID: 7}
+  m_MinSize: {x: 100, y: 121}
+  m_MaxSize: {x: 4000, y: 4021}
+  m_Maximized: 0
+--- !u!114 &3
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -19,12 +67,114 @@ MonoBehaviour:
     width: 2560
     height: 1349
   m_ShowMode: 4
-  m_Title: Hierarchy
-  m_RootView: {fileID: 2}
+  m_Title: Project
+  m_RootView: {fileID: 8}
   m_MinSize: {x: 875, y: 492}
   m_MaxSize: {x: 10000, y: 10000}
   m_Maximized: 1
---- !u!114 &2
+--- !u!114 &4
+MonoBehaviour:
+  m_ObjectHideFlags: 52
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 0}
+  m_Enabled: 1
+  m_EditorHideFlags: 0
+  m_Script: {fileID: 12006, guid: 0000000000000000e000000000000000, type: 0}
+  m_Name: ConsoleWindow
+  m_EditorClassIdentifier: 
+  m_Children: []
+  m_Position:
+    serializedVersion: 2
+    x: 0
+    y: 0
+    width: 1702
+    height: 645
+  m_MinSize: {x: 100, y: 121}
+  m_MaxSize: {x: 4000, y: 4021}
+  m_ActualView: {fileID: 18}
+  m_Panes:
+  - {fileID: 18}
+  m_Selected: 0
+  m_LastSelected: 0
+--- !u!114 &5
+MonoBehaviour:
+  m_ObjectHideFlags: 52
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 0}
+  m_Enabled: 1
+  m_EditorHideFlags: 0
+  m_Script: {fileID: 12010, guid: 0000000000000000e000000000000000, type: 0}
+  m_Name: 
+  m_EditorClassIdentifier: 
+  m_Children:
+  - {fileID: 4}
+  m_Position:
+    serializedVersion: 2
+    x: 0
+    y: 0
+    width: 1702
+    height: 645
+  m_MinSize: {x: 100, y: 121}
+  m_MaxSize: {x: 4000, y: 4021}
+  vertical: 0
+  controlID: 877
+  draggingID: 0
+--- !u!114 &6
+MonoBehaviour:
+  m_ObjectHideFlags: 52
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 0}
+  m_Enabled: 1
+  m_EditorHideFlags: 0
+  m_Script: {fileID: 12006, guid: 0000000000000000e000000000000000, type: 0}
+  m_Name: HotReloadWindow
+  m_EditorClassIdentifier: 
+  m_Children: []
+  m_Position:
+    serializedVersion: 2
+    x: 0
+    y: 0
+    width: 2560
+    height: 685
+  m_MinSize: {x: 100, y: 100}
+  m_MaxSize: {x: 4000, y: 4000}
+  m_ActualView: {fileID: 19}
+  m_Panes:
+  - {fileID: 19}
+  m_Selected: 0
+  m_LastSelected: 0
+--- !u!114 &7
+MonoBehaviour:
+  m_ObjectHideFlags: 52
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 0}
+  m_Enabled: 1
+  m_EditorHideFlags: 0
+  m_Script: {fileID: 12010, guid: 0000000000000000e000000000000000, type: 0}
+  m_Name: 
+  m_EditorClassIdentifier: 
+  m_Children:
+  - {fileID: 6}
+  m_Position:
+    serializedVersion: 2
+    x: 0
+    y: 0
+    width: 2560
+    height: 685
+  m_MinSize: {x: 100, y: 121}
+  m_MaxSize: {x: 4000, y: 4021}
+  vertical: 0
+  controlID: 174
+  draggingID: 0
+--- !u!114 &8
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -37,9 +187,9 @@ MonoBehaviour:
   m_Name: 
   m_EditorClassIdentifier: 
   m_Children:
-  - {fileID: 3}
-  - {fileID: 4}
-  - {fileID: 5}
+  - {fileID: 9}
+  - {fileID: 10}
+  - {fileID: 11}
   m_Position:
     serializedVersion: 2
     x: 0
@@ -52,7 +202,7 @@ MonoBehaviour:
   m_TopViewHeight: 30
   m_UseBottomView: 1
   m_BottomViewHeight: 20
---- !u!114 &3
+--- !u!114 &9
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -74,7 +224,7 @@ MonoBehaviour:
   m_MinSize: {x: 0, y: 0}
   m_MaxSize: {x: 0, y: 0}
   m_LastLoadedLayoutName: 
---- !u!114 &4
+--- !u!114 &10
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -87,10 +237,10 @@ MonoBehaviour:
   m_Name: 
   m_EditorClassIdentifier: 
   m_Children:
-  - {fileID: 6}
-  - {fileID: 7}
-  - {fileID: 8}
-  - {fileID: 9}
+  - {fileID: 12}
+  - {fileID: 13}
+  - {fileID: 14}
+  - {fileID: 15}
   m_Position:
     serializedVersion: 2
     x: 0
@@ -100,9 +250,9 @@ MonoBehaviour:
   m_MinSize: {x: 400, y: 100}
   m_MaxSize: {x: 32384, y: 16192}
   vertical: 0
-  controlID: 160
+  controlID: 77
   draggingID: 0
---- !u!114 &5
+--- !u!114 &11
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -123,7 +273,7 @@ MonoBehaviour:
     height: 20
   m_MinSize: {x: 0, y: 0}
   m_MaxSize: {x: 0, y: 0}
---- !u!114 &6
+--- !u!114 &12
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -136,8 +286,8 @@ MonoBehaviour:
   m_Name: 
   m_EditorClassIdentifier: 
   m_Children:
-  - {fileID: 10}
-  - {fileID: 11}
+  - {fileID: 16}
+  - {fileID: 17}
   m_Position:
     serializedVersion: 2
     x: 0
@@ -147,9 +297,9 @@ MonoBehaviour:
   m_MinSize: {x: 100, y: 100}
   m_MaxSize: {x: 8096, y: 16192}
   vertical: 1
-  controlID: 20
+  controlID: 30
   draggingID: 0
---- !u!114 &7
+--- !u!114 &13
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -170,12 +320,12 @@ MonoBehaviour:
     height: 1299
   m_MinSize: {x: 202, y: 221}
   m_MaxSize: {x: 4002, y: 4021}
-  m_ActualView: {fileID: 12}
+  m_ActualView: {fileID: 20}
   m_Panes:
-  - {fileID: 12}
+  - {fileID: 20}
   m_Selected: 0
   m_LastSelected: 0
---- !u!114 &8
+--- !u!114 &14
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -196,12 +346,12 @@ MonoBehaviour:
     height: 1299
   m_MinSize: {x: 232, y: 271}
   m_MaxSize: {x: 10002, y: 10021}
-  m_ActualView: {fileID: 14}
+  m_ActualView: {fileID: 22}
   m_Panes:
-  - {fileID: 14}
+  - {fileID: 22}
   m_Selected: 0
   m_LastSelected: 0
---- !u!114 &9
+--- !u!114 &15
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -222,12 +372,12 @@ MonoBehaviour:
     height: 1299
   m_MinSize: {x: 276, y: 71}
   m_MaxSize: {x: 4001, y: 4021}
-  m_ActualView: {fileID: 13}
+  m_ActualView: {fileID: 21}
   m_Panes:
-  - {fileID: 13}
+  - {fileID: 21}
   m_Selected: 0
   m_LastSelected: 0
---- !u!114 &10
+--- !u!114 &16
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -248,12 +398,12 @@ MonoBehaviour:
     height: 462
   m_MinSize: {x: 201, y: 221}
   m_MaxSize: {x: 4001, y: 4021}
-  m_ActualView: {fileID: 16}
+  m_ActualView: {fileID: 24}
   m_Panes:
-  - {fileID: 16}
+  - {fileID: 24}
   m_Selected: 0
   m_LastSelected: 0
---- !u!114 &11
+--- !u!114 &17
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -274,12 +424,80 @@ MonoBehaviour:
     height: 837
   m_MinSize: {x: 201, y: 221}
   m_MaxSize: {x: 4001, y: 4021}
-  m_ActualView: {fileID: 15}
+  m_ActualView: {fileID: 23}
   m_Panes:
-  - {fileID: 15}
+  - {fileID: 23}
   m_Selected: 0
   m_LastSelected: 0
---- !u!114 &12
+--- !u!114 &18
+MonoBehaviour:
+  m_ObjectHideFlags: 52
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 0}
+  m_Enabled: 1
+  m_EditorHideFlags: 0
+  m_Script: {fileID: 12003, guid: 0000000000000000e000000000000000, type: 0}
+  m_Name: 
+  m_EditorClassIdentifier: 
+  m_MinSize: {x: 100, y: 100}
+  m_MaxSize: {x: 4000, y: 4000}
+  m_TitleContent:
+    m_Text: Console
+    m_Image: {fileID: -4327648978806127646, guid: 0000000000000000d000000000000000, type: 0}
+    m_Tooltip: 
+  m_Pos:
+    serializedVersion: 2
+    x: -2438
+    y: 571
+    width: 1702
+    height: 624
+  m_SerializedDataModeController:
+    m_DataMode: 0
+    m_PreferredDataMode: 0
+    m_SupportedDataModes: 
+    isAutomatic: 1
+  m_ViewDataDictionary: {fileID: 0}
+  m_OverlayCanvas:
+    m_LastAppliedPresetName: Default
+    m_SaveData: []
+    m_OverlaysVisible: 1
+--- !u!114 &19
+MonoBehaviour:
+  m_ObjectHideFlags: 52
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 0}
+  m_Enabled: 1
+  m_EditorHideFlags: 0
+  m_Script: {fileID: 11500000, guid: f62a84c0b148b0a4582bdd9f1a69e6d3, type: 3}
+  m_Name: 
+  m_EditorClassIdentifier: 
+  m_MinSize: {x: 100, y: 100}
+  m_MaxSize: {x: 4000, y: 4000}
+  m_TitleContent:
+    m_Text: ' Hot Reload'
+    m_Image: {fileID: 0}
+    m_Tooltip: 
+  m_Pos:
+    serializedVersion: 2
+    x: -2810
+    y: 694
+    width: 2560
+    height: 664
+  m_SerializedDataModeController:
+    m_DataMode: 0
+    m_PreferredDataMode: 0
+    m_SupportedDataModes: 
+    isAutomatic: 1
+  m_ViewDataDictionary: {fileID: 0}
+  m_OverlayCanvas:
+    m_LastAppliedPresetName: Default
+    m_SaveData: []
+    m_OverlaysVisible: 1
+--- !u!114 &20
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -316,7 +534,7 @@ MonoBehaviour:
   m_SceneHierarchy:
     m_TreeViewState:
       scrollPos: {x: 0, y: 0}
-      m_SelectedIDs: 
+      m_SelectedIDs: 24e10000
       m_LastClickedID: 0
       m_ExpandedIDs: b8faffff
       m_RenameOverlay:
@@ -334,7 +552,7 @@ MonoBehaviour:
         m_IsRenaming: 0
         m_OriginalEventType: 11
         m_IsRenamingFilename: 0
-        m_ClientGUIView: {fileID: 7}
+        m_ClientGUIView: {fileID: 13}
       m_SearchString: 
     m_ExpandedScenes: []
     m_CurrenRootInstanceID: 0
@@ -342,7 +560,7 @@ MonoBehaviour:
       m_IsLocked: 0
     m_CurrentSortingName: TransformSorting
   m_WindowGUID: 04280301a53bc2049aa83a6b220683ba
---- !u!114 &13
+--- !u!114 &21
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -389,7 +607,7 @@ MonoBehaviour:
   m_LockTracker:
     m_IsLocked: 0
   m_PreviewWindow: {fileID: 0}
---- !u!114 &14
+--- !u!114 &22
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -424,7 +642,7 @@ MonoBehaviour:
     m_SaveData: []
     m_OverlaysVisible: 1
   m_SearchFilter:
-    m_NameFilter: GAMER
+    m_NameFilter: dbman
     m_ClassNames: []
     m_AssetLabels: []
     m_AssetBundleNames: []
@@ -434,24 +652,24 @@ MonoBehaviour:
     m_SkipHidden: 0
     m_SearchArea: 1
     m_Folders:
-    - Assets/Scripts/GameStart
+    - Assets/Epic Toon FX
     m_Globs: []
-    m_OriginalText: GAMER
+    m_OriginalText: dbman
     m_ImportLogFlags: 0
     m_FilterByTypeIntersection: 0
   m_ViewMode: 1
   m_StartGridSize: 16
   m_LastFolders:
-  - Assets/Scripts/GameStart
+  - Assets/Epic Toon FX
   m_LastFoldersGridSize: 16
-  m_LastProjectPath: D:\unityProject\XiuXianGame
+  m_LastProjectPath: D:\FB\XiuXianGame
   m_LockTracker:
     m_IsLocked: 0
   m_FolderTreeState:
     scrollPos: {x: 0, y: 0}
-    m_SelectedIDs: 68cb0000
-    m_LastClickedID: 52072
-    m_ExpandedIDs: 000000005ca8000066ca000068ca00006aca00006cca00006eca000070ca000072ca000074ca000076ca000078ca00007aca00007cca00007eca000080ca000082ca000084ca000086ca000088ca00008aca00008cca00008eca000090ca000092ca000094ca000096ca000098ca00009aca00009cca00009eca0000a0ca0000a2ca0000a4ca0000a6ca0000a8ca0000aaca0000acca0000e8ca000000ca9a3bffffff7f
+    m_SelectedIDs: ceca0000
+    m_LastClickedID: 51918
+    m_ExpandedIDs: 0000000094ca000096ca000098ca00009aca00009cca00009eca0000a0ca0000a2ca0000a4ca0000a6ca0000a8ca0000aaca0000acca0000aeca0000f2ca000000ca9a3b
     m_RenameOverlay:
       m_UserAcceptedRename: 0
       m_Name: 
@@ -479,7 +697,7 @@ MonoBehaviour:
     scrollPos: {x: 0, y: 0}
     m_SelectedIDs: 
     m_LastClickedID: 0
-    m_ExpandedIDs: 000000005ca8000066ca000068ca00006aca00006cca00006eca000070ca000072ca000074ca000076ca000078ca00007aca00007cca00007eca000080ca000082ca000084ca000086ca000088ca00008aca00008cca00008eca000090ca000092ca000094ca000096ca000098ca00009aca00009cca00009eca0000a0ca0000a2ca0000a4ca0000a6ca0000a8ca0000aaca0000acca0000
+    m_ExpandedIDs: 0000000094ca000096ca000098ca00009aca00009cca00009eca0000a0ca0000a2ca0000a4ca0000a6ca0000a8ca0000aaca0000acca0000aeca0000
     m_RenameOverlay:
       m_UserAcceptedRename: 0
       m_Name: 
@@ -523,7 +741,7 @@ MonoBehaviour:
       m_IsRenaming: 0
       m_OriginalEventType: 11
       m_IsRenamingFilename: 1
-      m_ClientGUIView: {fileID: 0}
+      m_ClientGUIView: {fileID: 14}
     m_CreateAssetUtility:
       m_EndAction: {fileID: 0}
       m_InstanceID: 0
@@ -535,7 +753,7 @@ MonoBehaviour:
     m_GridSize: 16
   m_SkipHiddenPackages: 0
   m_DirectoriesAreaWidth: 115
---- !u!114 &15
+--- !u!114 &23
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -633,7 +851,7 @@ MonoBehaviour:
   m_LowResolutionForAspectRatios: 01000001000000000000
   m_XRRenderMode: 0
   m_RenderTexture: {fileID: 0}
---- !u!114 &16
+--- !u!114 &24
 MonoBehaviour:
   m_ObjectHideFlags: 52
   m_CorrespondingSourceObject: {fileID: 0}
@@ -672,7 +890,7 @@ MonoBehaviour:
       collapsed: 0
       displayed: 1
       snapOffset: {x: 0, y: 0}
-      snapOffsetDelta: {x: -164, y: -26}
+      snapOffsetDelta: {x: -179, y: -26}
       snapCorner: 3
       id: Tool Settings
       index: 0

+ 1 - 0
XiuXianGame.sln.DotSettings.user

@@ -24,6 +24,7 @@
 	<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ACrasheyeLib_002Ecs_002Fl_003AC_0021_003FUsers_003Fck_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E2_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003F5d871a7d0a7c4e15870b62fc01af92731a00_003F61_003Fdc27fc5d_003FCrasheyeLib_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
 	<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ACultureInfo_002Ecs_002Fl_003AC_0021_003FUsers_003FAdministrator_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003F3789ee403a53437cbb6b5d9ab6311f51573620_003F69_003F81b4a42b_003FCultureInfo_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
 	<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ACustomRenderTexture_002Ecs_002Fl_003AC_0021_003FUsers_003Fck_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E2_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003F5c4a01f363eb46748231fc41bd9bdd8517e000_003F8f_003F8149d2e1_003FCustomRenderTexture_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
+	<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ADebug_002Ecs_002Fl_003AC_0021_003FUsers_003FAdministrator_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003F5c4a01f363eb46748231fc41bd9bdd8517e000_003Ffc_003Fb9b0fb28_003FDebug_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
 	<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ADictionary_00602_002Ecs_002Fl_003AC_0021_003FUsers_003FAdministrator_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003F3789ee403a53437cbb6b5d9ab6311f51573620_003Fc9_003Fe80e9cbf_003FDictionary_00602_002Ecs_002Fz_003A2_002D1/@EntryIndexedValue">ForceIncluded</s:String>
 	<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ADictionary_00602_002Ecs_002Fl_003AC_0021_003FUsers_003FAdministrator_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003F9c2967a135e648bdb993c5397a44991b573620_003Fad_003Fcb4b4f1f_003FDictionary_00602_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
 	<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ADictionary_00602_002Ecs_002Fl_003AC_0021_003FUsers_003FAdministrator_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003Fe4df6db7850b4c40b72002ff5da8188846ac00_003Fc8_003F6520f62d_003FDictionary_00602_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>

部分文件因文件數量過多而無法顯示