diff --git a/AndroidSDK/.idea/codeStyles/Project.xml b/AndroidSDK/.idea/codeStyles/Project.xml index ae78c113ff..fcf43b28d8 100644 --- a/AndroidSDK/.idea/codeStyles/Project.xml +++ b/AndroidSDK/.idea/codeStyles/Project.xml @@ -1,5 +1,30 @@ + + + + + + + + + + diff --git a/AndroidSDK/app/libs/PSDK/mhtsdk.aar b/AndroidSDK/app/libs/PSDK/mhtsdk.aar index 538a91f899..72dd4dc9fd 100644 Binary files a/AndroidSDK/app/libs/PSDK/mhtsdk.aar and b/AndroidSDK/app/libs/PSDK/mhtsdk.aar differ diff --git a/AndroidSDK/app/libs/PSDK/psdk.aar b/AndroidSDK/app/libs/PSDK/psdk.aar index 0d9e9f59d9..366247062c 100644 Binary files a/AndroidSDK/app/libs/PSDK/psdk.aar and b/AndroidSDK/app/libs/PSDK/psdk.aar differ diff --git a/AndroidSDK/app/libs/PSDK/psdk_mht.aar b/AndroidSDK/app/libs/PSDK/psdk_mht.aar index 6a6040e183..9df0589ec9 100644 Binary files a/AndroidSDK/app/libs/PSDK/psdk_mht.aar and b/AndroidSDK/app/libs/PSDK/psdk_mht.aar differ diff --git a/AndroidSDK/app/src/main/AndroidManifest.xml b/AndroidSDK/app/src/main/AndroidManifest.xml index 27c1f1d39d..636a28ca01 100644 --- a/AndroidSDK/app/src/main/AndroidManifest.xml +++ b/AndroidSDK/app/src/main/AndroidManifest.xml @@ -1,13 +1,13 @@ + package="com.mht"> - + @@ -18,7 +18,7 @@ - + diff --git a/AndroidSDK/app/src/main/java/com/bluewhale/androidutils/AndroidDeviceInfo.java b/AndroidSDK/app/src/main/java/com/bluewhale/androidutils/AndroidDeviceInfo.java index 7183798ff7..e648faaa4b 100644 --- a/AndroidSDK/app/src/main/java/com/bluewhale/androidutils/AndroidDeviceInfo.java +++ b/AndroidSDK/app/src/main/java/com/bluewhale/androidutils/AndroidDeviceInfo.java @@ -4,6 +4,12 @@ import android.annotation.SuppressLint; import android.content.ClipData; import android.content.ClipboardManager; import android.content.Context; +import android.content.pm.ApplicationInfo; +import android.content.pm.PackageInfo; +import android.content.pm.PackageManager; +import android.graphics.Bitmap; +import android.graphics.drawable.BitmapDrawable; +import android.graphics.drawable.Drawable; import android.net.ConnectivityManager; import android.net.NetworkInfo; import android.net.wifi.WifiInfo; @@ -160,5 +166,181 @@ public class AndroidDeviceInfo { return KTGameDeviceUtil.getDeviceID(mContext); } + + + /** + + * 获取应用程序名称 + + */ + + public static synchronized String getAppName() { + + try { + + PackageManager packageManager = mContext.getPackageManager(); + + PackageInfo packageInfo = packageManager.getPackageInfo( + + mContext.getPackageName(), 0); + + int labelRes = packageInfo.applicationInfo.labelRes; + + return mContext.getResources().getString(labelRes); + + } catch (Exception e) { + + e.printStackTrace(); + + } + + return null; + + } + + + + /** + + * [获取应用程序版本名称信息] + + * @return 当前应用的版本名称 + + */ + + public static synchronized String getVersionName() { + try { + + PackageManager packageManager = mContext.getPackageManager(); + + PackageInfo packageInfo = packageManager.getPackageInfo( + + mContext.getPackageName(), 0); + + return packageInfo.versionName; + + } catch (Exception e) { + + e.printStackTrace(); + + } + + return null; + + } + + + + + + /** + + * [获取应用程序版本名称信息] + + * @return 当前应用的版本名称 + + */ + + public static synchronized int getVersionCode() { + + try { + + PackageManager packageManager = mContext.getPackageManager(); + + PackageInfo packageInfo = packageManager.getPackageInfo( + + mContext.getPackageName(), 0); + + return packageInfo.versionCode; + + } catch (Exception e) { + + e.printStackTrace(); + + } + + return 0; + + } + + + + + + /** + + * [获取应用程序版本名称信息] + + * @return 当前应用的版本名称 + + */ + + public static synchronized String getPackageName() { + + try { + + PackageManager packageManager = mContext.getPackageManager(); + + PackageInfo packageInfo = packageManager.getPackageInfo( + + mContext.getPackageName(), 0); + + return packageInfo.packageName; + + } catch (Exception e) { + + e.printStackTrace(); + + } + + return null; + + } + + + + + + /** + + * 获取图标 bitmap + + */ + + public static synchronized Bitmap getBitmap() { + + PackageManager packageManager = null; + + ApplicationInfo applicationInfo = null; + + try { + + packageManager = mContext.getApplicationContext() + + .getPackageManager(); + + applicationInfo = packageManager.getApplicationInfo( + + mContext.getPackageName(), 0); + + } catch (PackageManager.NameNotFoundException e) { + + applicationInfo = null; + + } + + Drawable d = packageManager.getApplicationIcon(applicationInfo); //xxx根据自己的情况获取drawable + + BitmapDrawable bd = (BitmapDrawable) d; + + Bitmap bm = bd.getBitmap(); + + return bm; + + } + + + + } diff --git a/AndroidSDK/app/src/main/java/com/mht/tcxcsb/project/GameApplication.java b/AndroidSDK/app/src/main/java/com/mht/GameApplication.java similarity index 94% rename from AndroidSDK/app/src/main/java/com/mht/tcxcsb/project/GameApplication.java rename to AndroidSDK/app/src/main/java/com/mht/GameApplication.java index 1e204d4935..62eb852923 100644 --- a/AndroidSDK/app/src/main/java/com/mht/tcxcsb/project/GameApplication.java +++ b/AndroidSDK/app/src/main/java/com/mht/GameApplication.java @@ -1,4 +1,4 @@ -package com.mht.tcxcsb.project; +package com.mht; import android.app.Application; import android.content.res.Configuration; diff --git a/AndroidSDK/app/src/main/java/com/mht/tcxcsb/project/MhtActivity.java b/AndroidSDK/app/src/main/java/com/mht/MhtActivity.java similarity index 93% rename from AndroidSDK/app/src/main/java/com/mht/tcxcsb/project/MhtActivity.java rename to AndroidSDK/app/src/main/java/com/mht/MhtActivity.java index 7f9d58d048..9ace4661c6 100644 --- a/AndroidSDK/app/src/main/java/com/mht/tcxcsb/project/MhtActivity.java +++ b/AndroidSDK/app/src/main/java/com/mht/MhtActivity.java @@ -1,4 +1,4 @@ -package com.mht.tcxcsb.project; +package com.mht; import android.app.AlertDialog; import android.content.DialogInterface; @@ -41,6 +41,23 @@ public class MhtActivity extends IUnityPlayerActivity { } } + public void onRegister(int code) { + if (code == GameListener.SUCCESS) { + UnityPlayer.UnitySendMessage("SDK.SDKManager", "RegisterCallback", MhtActivity.this.SUCCESS); + showLog("注册成功"); + } else { + UnityPlayer.UnitySendMessage("SDK.SDKManager", "RegisterCallback", MhtActivity.this.FAILED); + showLog("注册失败"); + } + } + + public void onOrderNumber(int code, String msg) { + if (code == GameListener.SUCCESS) { + showLog("生成订单成功"); + } else { + showLog("生成订单失败"); + } + } @Override public void onLogin(int code, String msg) { if (code == GameListener.SUCCESS) { diff --git a/AndroidSDK/app/src/main/java/com/mht/dhyq/project/MhtMainActivity.java b/AndroidSDK/app/src/main/java/com/mht/dhyq/project/MhtMainActivity.java new file mode 100644 index 0000000000..b382a4ceff --- /dev/null +++ b/AndroidSDK/app/src/main/java/com/mht/dhyq/project/MhtMainActivity.java @@ -0,0 +1,6 @@ +package com.mht.dhyq.project; + +import com.mht.MhtActivity; + +public class MhtMainActivity extends MhtActivity { +} diff --git a/AndroidSDK/app/src/main/java/com/mht/tcxcsb/project/MhtMainActivity.java b/AndroidSDK/app/src/main/java/com/mht/tcxcsb/project/MhtMainActivity.java new file mode 100644 index 0000000000..f267be43a1 --- /dev/null +++ b/AndroidSDK/app/src/main/java/com/mht/tcxcsb/project/MhtMainActivity.java @@ -0,0 +1,6 @@ +package com.mht.tcxcsb.project; + +import com.mht.MhtActivity; + +public class MhtMainActivity extends MhtActivity { +} diff --git a/AssetBundles/version.txt b/AssetBundles/version.txt index f10a20f4c9..e7e73835a5 100644 --- a/AssetBundles/version.txt +++ b/AssetBundles/version.txt @@ -1 +1 @@ -{"buglyId":"b67b061643", "channel":"pc", "resUrl":"http://60.1.1.12/jieling_dl/dev/assetBundles/subChannal094-test/", "packageVersion":"0.2", "subChannel":"1", "version":"0.15.0", "serverUrl":"http://60.1.1.23:8080/"} \ No newline at end of file +{"subChannel":"1", "buglyId":"261348dcd3", "channel":"pc", "resUrl":"http://60.1.1.12/jieling_dl/dev/assetBundles/subChannal094-test/", "packageVersion":"0.2", "version":"0.15.0", "serverUrl":"http://60.1.1.23:8080/"} \ No newline at end of file diff --git a/AssetBundles/version_mht_test.txt b/AssetBundles/version_mht_test.txt index 6ad6e9fb8b..46bcbb4bdd 100644 --- a/AssetBundles/version_mht_test.txt +++ b/AssetBundles/version_mht_test.txt @@ -1 +1 @@ -{"buglyId":"b67b061643", "channel":"MHT", "resUrl":"http://cdn-jl.lanjingshidai.com/mht_test/", "packageVersion":"0.1", "subChannel":"1000", "version":"0.1.0", "serverUrl":"http://106.52.122.168:8080/"} +{"buglyId":"261348dcd3", "channel":"MHT", "resUrl":"http://cdn-jl.lanjingshidai.com/mht_test/", "packageVersion":"0.1", "subChannel":"1000", "version":"0.1.0", "serverUrl":"http://106.52.122.168:8080/"} diff --git a/AssetBundles/version_mht_tishen.txt b/AssetBundles/version_mht_tishen.txt index 36d5d7f9e5..463dcf3a63 100644 --- a/AssetBundles/version_mht_tishen.txt +++ b/AssetBundles/version_mht_tishen.txt @@ -1 +1 @@ -{"buglyId":"b67b061643", "channel":"MHT", "resUrl":"http://cdn-jl.lanjingshidai.com/mht_release/", "packageVersion":"0.1", "subChannel":"2000", "version":"0.1.0", "serverUrl":"http://106.52.122.168:8080/"} +{"buglyId":"261348dcd3", "channel":"MHT", "resUrl":"http://cdn-jl.lanjingshidai.com/mht_release/", "packageVersion":"0.1", "subChannel":"2000", "version":"0.1.0", "serverUrl":"http://106.52.122.168:8080/"} diff --git a/AssetBundles/version_test.txt b/AssetBundles/version_test.txt index aa5c220c10..e7e73835a5 100644 --- a/AssetBundles/version_test.txt +++ b/AssetBundles/version_test.txt @@ -1 +1 @@ -{"subChannel":"1", "buglyId":"b67b061643", "channel":"pc", "resUrl":"http://60.1.1.12/jieling_dl/dev/assetBundles/subChannal094-test/", "packageVersion":"0.2", "version":"0.15.0", "serverUrl":"http://60.1.1.23:8080/"} \ No newline at end of file +{"subChannel":"1", "buglyId":"261348dcd3", "channel":"pc", "resUrl":"http://60.1.1.12/jieling_dl/dev/assetBundles/subChannal094-test/", "packageVersion":"0.2", "version":"0.15.0", "serverUrl":"http://60.1.1.23:8080/"} \ No newline at end of file diff --git a/Assets/LuaFramework/Scenes/Logo.unity b/Assets/LuaFramework/Scenes/Logo.unity index b1e84494cd..f2d9d8d0e0 100644 --- a/Assets/LuaFramework/Scenes/Logo.unity +++ b/Assets/LuaFramework/Scenes/Logo.unity @@ -273,74 +273,13 @@ MonoBehaviour: settingInfo: logLevel: 0 isDebug: 0 - bundleMode: 0 - luaBundleMode: 0 - isUpdate: 0 - isSDK: 0 + bundleMode: 1 + luaBundleMode: 1 + isUpdate: 1 + isSDK: 1 isSDKLogin: 0 - isGuide: 0 - isOpenGM: 1 ---- !u!1001 &1534980096 -PrefabInstance: - m_ObjectHideFlags: 0 - serializedVersion: 2 - m_Modification: - m_TransformParent: {fileID: 0} - m_Modifications: - - target: {fileID: 118256, guid: 99b0fede6f9ae7946b30748aa8bfc627, type: 3} - propertyPath: m_Name - value: UIRoot - objectReference: {fileID: 0} - - target: {fileID: 118256, guid: 99b0fede6f9ae7946b30748aa8bfc627, type: 3} - propertyPath: m_IsActive - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4132084493212212, guid: 99b0fede6f9ae7946b30748aa8bfc627, type: 3} - propertyPath: m_LocalPosition.x - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4132084493212212, guid: 99b0fede6f9ae7946b30748aa8bfc627, type: 3} - propertyPath: m_LocalPosition.y - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4132084493212212, guid: 99b0fede6f9ae7946b30748aa8bfc627, type: 3} - propertyPath: m_LocalPosition.z - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4132084493212212, guid: 99b0fede6f9ae7946b30748aa8bfc627, type: 3} - propertyPath: m_LocalRotation.x - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4132084493212212, guid: 99b0fede6f9ae7946b30748aa8bfc627, type: 3} - propertyPath: m_LocalRotation.y - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4132084493212212, guid: 99b0fede6f9ae7946b30748aa8bfc627, type: 3} - propertyPath: m_LocalRotation.z - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4132084493212212, guid: 99b0fede6f9ae7946b30748aa8bfc627, type: 3} - propertyPath: m_LocalRotation.w - value: 1 - objectReference: {fileID: 0} - - target: {fileID: 4132084493212212, guid: 99b0fede6f9ae7946b30748aa8bfc627, type: 3} - propertyPath: m_RootOrder - value: 3 - objectReference: {fileID: 0} - - target: {fileID: 4132084493212212, guid: 99b0fede6f9ae7946b30748aa8bfc627, type: 3} - propertyPath: m_LocalEulerAnglesHint.x - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4132084493212212, guid: 99b0fede6f9ae7946b30748aa8bfc627, type: 3} - propertyPath: m_LocalEulerAnglesHint.y - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4132084493212212, guid: 99b0fede6f9ae7946b30748aa8bfc627, type: 3} - propertyPath: m_LocalEulerAnglesHint.z - value: 0 - objectReference: {fileID: 0} - m_RemovedComponents: [] - m_SourcePrefab: {fileID: 100100000, guid: 99b0fede6f9ae7946b30748aa8bfc627, type: 3} + isGuide: 1 + isOpenGM: 0 --- !u!4 &57277738265262265 Transform: m_ObjectHideFlags: 0 diff --git a/Assets/LuaFramework/Scripts/ConstDefine/AppConst.cs b/Assets/LuaFramework/Scripts/ConstDefine/AppConst.cs index 228499d3d9..484c86d82b 100644 --- a/Assets/LuaFramework/Scripts/ConstDefine/AppConst.cs +++ b/Assets/LuaFramework/Scripts/ConstDefine/AppConst.cs @@ -171,7 +171,8 @@ namespace GameLogic public static string SdkId; //SDK UId public static string OpenId; //开天SDK UId public static string TokenStr; //开天SDK Token - public static string SdkChannel; //SDK UId + public static string SdkChannel; //SDK 渠道 + public static string SdkPackageName; //SDK包名 public static int Url_JoinRoomID = 0; diff --git a/Assets/LuaFramework/Scripts/Manager/ThinkingAnalyticsManager.cs b/Assets/LuaFramework/Scripts/Manager/ThinkingAnalyticsManager.cs index 27facf9b32..5f73ed01f2 100644 --- a/Assets/LuaFramework/Scripts/Manager/ThinkingAnalyticsManager.cs +++ b/Assets/LuaFramework/Scripts/Manager/ThinkingAnalyticsManager.cs @@ -51,6 +51,13 @@ namespace GameLogic ThinkingAnalyticsAPI.EnableAutoTrack(AUTO_TRACK_EVENTS.ALL); } + // 校对时间 + public void CalibrateTime(long time) + { + ThinkingAnalyticsAPI.CalibrateTime(time); + } + + // 设置访客Id public void SetDistinctId(string distinctId) { diff --git a/Assets/LuaFramework/Scripts/SDK/MessageDef.cs b/Assets/LuaFramework/Scripts/SDK/MessageDef.cs index d3d7a6b00f..9df7679bf0 100644 --- a/Assets/LuaFramework/Scripts/SDK/MessageDef.cs +++ b/Assets/LuaFramework/Scripts/SDK/MessageDef.cs @@ -10,6 +10,7 @@ namespace SDK{ public const int MSG_PayCallback = 3; public const int MSG_SwitchAccountCallback = 4; public const int MSG_LogoutCallback = 5; + public const int MSG_RegisterCallback = 6; } } diff --git a/Assets/LuaFramework/Scripts/SDK/SDKManager.cs b/Assets/LuaFramework/Scripts/SDK/SDKManager.cs index 7e6dc106d9..90e7b3eacb 100644 --- a/Assets/LuaFramework/Scripts/SDK/SDKManager.cs +++ b/Assets/LuaFramework/Scripts/SDK/SDKManager.cs @@ -19,6 +19,9 @@ namespace SDK public delegate void InitLaunchAction(string data); public InitLaunchAction onInitLaunchCallback; + public delegate void RegisterAction(string data); + public RegisterAction onRegisterCallback; + public delegate void LoginAction(string data); public LoginAction onLoginCallback; @@ -77,6 +80,12 @@ namespace SDK onInitLaunchCallback(msg.data); } break; + case MessageDef.MSG_RegisterCallback: + if (null != onRegisterCallback) + { + onRegisterCallback(msg.data); + } + break; case MessageDef.MSG_LoginCallback: if (null != onLoginCallback) { @@ -165,6 +174,16 @@ namespace SDK data = data }); } + //sdk 注册 回调 + public void RegisterCallback(string data) + { + Debug.Log("Helper : RegisterCallback - data: " + data); + proxy.PushMessage(new Message + { + msgId = MessageDef.MSG_RegisterCallback, + data = data + }); + } //sdk login 回调 public void LoginCallback(string data) { diff --git a/Assets/LuaFramework/Scripts/SDK/Tools/AndroidDeviceInfo.cs b/Assets/LuaFramework/Scripts/SDK/Tools/AndroidDeviceInfo.cs index d6d9ee101f..0da2ca8231 100644 --- a/Assets/LuaFramework/Scripts/SDK/Tools/AndroidDeviceInfo.cs +++ b/Assets/LuaFramework/Scripts/SDK/Tools/AndroidDeviceInfo.cs @@ -147,6 +147,33 @@ public class AndroidDeviceInfo { return jo.CallStatic("GetIMEICode"); } + //sdk 获取app名 + public string GetAppName() + { + return jo.CallStatic("getAppName"); + } + + //sdk 获取版本名称 + public string GetVersionName() + { + return jo.CallStatic("getVersionName"); + } + + //sdk 获取版本号 + public int GetVersionCode() + { + return jo.CallStatic("getVersionCode"); + } + + //sdk 获取包名 + public string GetPackageName() + { + return jo.CallStatic("getPackageName"); + } + + + + //暂时存放--复制粘贴功能(本不隶属于此) public void SetCopyValue(string str) diff --git a/Assets/ManagedResources/DynamicAtlas/m_chsm_0035.png b/Assets/ManagedResources/DynamicAtlas/m_chsm_0035.png deleted file mode 100644 index d30319315d..0000000000 Binary files a/Assets/ManagedResources/DynamicAtlas/m_chsm_0035.png and /dev/null differ diff --git a/Assets/ManagedResources/DynamicAtlas/m_chsm_0035.png.meta b/Assets/ManagedResources/DynamicAtlas/m_chsm_0035.png.meta deleted file mode 100644 index b161700063..0000000000 --- a/Assets/ManagedResources/DynamicAtlas/m_chsm_0035.png.meta +++ /dev/null @@ -1,88 +0,0 @@ -fileFormatVersion: 2 -guid: cef97d40af40d01488b14ed27f2765ac -TextureImporter: - fileIDToRecycleName: {} - externalObjects: {} - serializedVersion: 9 - mipmaps: - mipMapMode: 0 - enableMipMap: 0 - sRGBTexture: 1 - linearTexture: 0 - fadeOut: 0 - borderMipMap: 0 - mipMapsPreserveCoverage: 0 - alphaTestReferenceValue: 0.5 - mipMapFadeDistanceStart: 1 - mipMapFadeDistanceEnd: 3 - bumpmap: - convertToNormalMap: 0 - externalNormalMap: 0 - heightScale: 0.25 - normalMapFilter: 0 - isReadable: 0 - streamingMipmaps: 0 - streamingMipmapsPriority: 0 - grayScaleToAlpha: 0 - generateCubemap: 6 - cubemapConvolution: 0 - seamlessCubemap: 0 - textureFormat: 1 - maxTextureSize: 2048 - textureSettings: - serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: 1 - wrapV: 1 - wrapW: 1 - nPOTScale: 0 - lightmap: 0 - compressionQuality: 50 - spriteMode: 1 - spriteExtrude: 1 - spriteMeshType: 1 - alignment: 0 - spritePivot: {x: 0.5, y: 0.5} - spritePixelsToUnits: 100 - spriteBorder: {x: 0, y: 0, z: 0, w: 0} - spriteGenerateFallbackPhysicsShape: 1 - alphaUsage: 1 - alphaIsTransparency: 1 - spriteTessellationDetail: -1 - textureType: 8 - textureShape: 1 - singleChannelComponent: 0 - maxTextureSizeSet: 0 - compressionQualitySet: 0 - textureFormatSet: 0 - platformSettings: - - serializedVersion: 2 - buildTarget: DefaultTexturePlatform - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 1 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - spriteSheet: - serializedVersion: 2 - sprites: [] - outline: [] - physicsShape: [] - bones: [] - spriteID: fbb4e34b24bda43469de0a70ea0bcc30 - vertices: [] - indices: - edges: [] - weights: [] - spritePackingTag: - pSDRemoveMatte: 0 - pSDShowRemoveMatteOption: 0 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/ManagedResources/DynamicAtlas/m_chsm_0035_png.png b/Assets/ManagedResources/DynamicAtlas/m_chsm_0035_png.png new file mode 100644 index 0000000000..0740d0fe2a Binary files /dev/null and b/Assets/ManagedResources/DynamicAtlas/m_chsm_0035_png.png differ diff --git a/Assets/ManagedResources/Spine/m_chsm_0035/m_chsm_0035_png.png.meta b/Assets/ManagedResources/DynamicAtlas/m_chsm_0035_png.png.meta similarity index 75% rename from Assets/ManagedResources/Spine/m_chsm_0035/m_chsm_0035_png.png.meta rename to Assets/ManagedResources/DynamicAtlas/m_chsm_0035_png.png.meta index 4edb6bf802..775532949d 100644 --- a/Assets/ManagedResources/Spine/m_chsm_0035/m_chsm_0035_png.png.meta +++ b/Assets/ManagedResources/DynamicAtlas/m_chsm_0035_png.png.meta @@ -1,7 +1,8 @@ fileFormatVersion: 2 -guid: 90460778e185bda4ca37b1b26a085530 +guid: cef97d40af40d01488b14ed27f2765ac TextureImporter: - fileIDToRecycleName: {} + fileIDToRecycleName: + 21300000: m_chsm_0035_png externalObjects: {} serializedVersion: 9 mipmaps: @@ -40,7 +41,7 @@ TextureImporter: nPOTScale: 0 lightmap: 0 compressionQuality: 50 - spriteMode: 0 + spriteMode: 2 spriteExtrude: 1 spriteMeshType: 1 alignment: 0 @@ -49,7 +50,7 @@ TextureImporter: spriteBorder: {x: 0, y: 0, z: 0, w: 0} spriteGenerateFallbackPhysicsShape: 1 alphaUsage: 1 - alphaIsTransparency: 0 + alphaIsTransparency: 1 spriteTessellationDetail: -1 textureType: 8 textureShape: 1 @@ -63,7 +64,7 @@ TextureImporter: maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 - textureCompression: 0 + textureCompression: 1 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 @@ -74,7 +75,7 @@ TextureImporter: maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 - textureCompression: 0 + textureCompression: 1 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 @@ -84,8 +85,8 @@ TextureImporter: buildTarget: Android maxTextureSize: 2048 resizeAlgorithm: 0 - textureFormat: 55 - textureCompression: 0 + textureFormat: 65 + textureCompression: 1 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 @@ -93,11 +94,31 @@ TextureImporter: androidETC2FallbackOverride: 0 spriteSheet: serializedVersion: 2 - sprites: [] + sprites: + - serializedVersion: 2 + name: m_chsm_0035_png + rect: + serializedVersion: 2 + x: 0 + y: 0 + width: 1024 + height: 1145 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: -1 + bones: [] + spriteID: f210f554c64aac447a2e9f0c3f63dbcb + vertices: [] + indices: + edges: [] + weights: [] outline: [] physicsShape: [] bones: [] - spriteID: + spriteID: fbb4e34b24bda43469de0a70ea0bcc30 vertices: [] indices: edges: [] diff --git a/Assets/ManagedResources/Spine/m_chsm_0035/m_chsm_0035_Material.mat b/Assets/ManagedResources/Spine/m_chsm_0035/m_chsm_0035_Material.mat index 357c01a42f..44d958cdfc 100644 --- a/Assets/ManagedResources/Spine/m_chsm_0035/m_chsm_0035_Material.mat +++ b/Assets/ManagedResources/Spine/m_chsm_0035/m_chsm_0035_Material.mat @@ -20,7 +20,7 @@ Material: serializedVersion: 3 m_TexEnvs: - _MainTex: - m_Texture: {fileID: 2800000, guid: 90460778e185bda4ca37b1b26a085530, type: 3} + m_Texture: {fileID: 2800000, guid: 58eb956e62475be41b19de1e6e714b13, type: 3} m_Scale: {x: 1, y: 1} m_Offset: {x: 0, y: 0} m_Floats: diff --git a/Assets/ManagedResources/Spine/m_chsm_0035/m_chsm_0035_png.png b/Assets/ManagedResources/Spine/m_chsm_0035/m_chsm_0035_png.png deleted file mode 100644 index cf5e7db25e..0000000000 Binary files a/Assets/ManagedResources/Spine/m_chsm_0035/m_chsm_0035_png.png and /dev/null differ diff --git a/Assets/ManagedResources/~Lua/Logic/Network.lua b/Assets/ManagedResources/~Lua/Logic/Network.lua index 6909e51b10..780ac7e2c7 100644 --- a/Assets/ManagedResources/~Lua/Logic/Network.lua +++ b/Assets/ManagedResources/~Lua/Logic/Network.lua @@ -76,7 +76,7 @@ end function Network:ReceiveClientHeartBeat(buffer) local time = buffer:ReadIntToByte() - --Log("-------ReceiveClientHeartBeat----- time: "..time) + Log("-------ReceiveClientHeartBeat----- time: "..time) Game.GlobalEvent:DispatchEvent(GameEvent.Network.OnReceiveHeartBeat, self, time) end diff --git a/Assets/ManagedResources/~Lua/Modules/Bag/BagManager.lua b/Assets/ManagedResources/~Lua/Modules/Bag/BagManager.lua index 1aa62a0585..b512bb1418 100644 --- a/Assets/ManagedResources/~Lua/Modules/Bag/BagManager.lua +++ b/Assets/ManagedResources/~Lua/Modules/Bag/BagManager.lua @@ -64,10 +64,12 @@ function this.UpdateBagData(_itemData, isNoSendNewItemEvent) end -- 货币数据 - ThinkingAnalyticsManager.SetSuperProperties({ - coins_amount = BagManager.GetItemCountById(14), - diamond_amount = BagManager.GetItemCountById(16), - }) + if itemdata.itemId == 14 or itemdata.itemId == 16 then + ThinkingAnalyticsManager.SetSuperProperties({ + coins_amount = BagManager.GetItemCountById(14), + diamond_amount = BagManager.GetItemCountById(16), + }) + end end diff --git a/Assets/ManagedResources/~Lua/Modules/DataCenterService/ThinkingAnalyticsManager.lua b/Assets/ManagedResources/~Lua/Modules/DataCenterService/ThinkingAnalyticsManager.lua index ae7f764242..2cebfe69a2 100644 --- a/Assets/ManagedResources/~Lua/Modules/DataCenterService/ThinkingAnalyticsManager.lua +++ b/Assets/ManagedResources/~Lua/Modules/DataCenterService/ThinkingAnalyticsManager.lua @@ -23,8 +23,24 @@ local function _DicToStr(data) end function this.Initialize() + + -- 监听赛季结束事件 + Game.GlobalEvent:AddEvent(GameEvent.Network.OnReceiveHeartBeat, function(network, time) + if network.type == SocketType.LOGIN then + this.CalibrateTime(time) + end + end) + end +-- 校对时间 +function this.CalibrateTime(time) + if AppConst.isSDK then + App.TAMgr:CalibrateTime(time*1000) + end +end + + -- 设置访客Id function this.SetDistinctId(distinctId) if AppConst.isSDK then diff --git a/Assets/ManagedResources/~Lua/Modules/Login/LoginManager.lua b/Assets/ManagedResources/~Lua/Modules/Login/LoginManager.lua index 4d3f862ba0..a40458e0b6 100644 --- a/Assets/ManagedResources/~Lua/Modules/Login/LoginManager.lua +++ b/Assets/ManagedResources/~Lua/Modules/Login/LoginManager.lua @@ -21,6 +21,11 @@ function this.Initialize() this.CurAccount=PlayerPrefs.GetString(this.GameName.."Account",'') this.CurSession=PlayerPrefs.GetString(this.GameName.."Session",'') + SDKMgr.onRegisterCallback = function() + -- Game.GlobalEvent:DispatchEvent(GameEvent.LoginSuccess.OnLoginSuccess,loginResp) + ThinkingAnalyticsManager.Track("create_account") + end + SDKMgr.onLoginCallback = function(loginResp) Game.GlobalEvent:DispatchEvent(GameEvent.LoginSuccess.OnLoginSuccess,loginResp) -- ThinkingAnalyticsManager.Track("app_login") diff --git a/Assets/ManagedResources/~Lua/Modules/Login/LoginPanel.lua b/Assets/ManagedResources/~Lua/Modules/Login/LoginPanel.lua index a78114f909..b581b1e226 100644 --- a/Assets/ManagedResources/~Lua/Modules/Login/LoginPanel.lua +++ b/Assets/ManagedResources/~Lua/Modules/Login/LoginPanel.lua @@ -237,6 +237,7 @@ function this.RefreshLoginStatus(loginResp) AppConst.OpenId = result[2] AppConst.TokenStr = result[4] AppConst.SdkChannel = result[5] + AppConst.SdkPackageName = AndroidDeviceInfo.Instance:GetPackageName() -- this.SetSDKExtensionParams(result[4]) Log(string.format("%sjl_loginserver/getServerList?openId=%s&channel=%s&plat=android&sub_channel=%s", LoginRoot_Url, AppConst.OpenId, LoginRoot_Channel, LoginRoot_SubChannel)) networkMgr:SendGetHttp(string.format("%sjl_loginserver/getServerList?openId=%s&channel=%s&plat=android&sub_channel=%s", LoginRoot_Url, AppConst.OpenId, LoginRoot_Channel, LoginRoot_SubChannel), @@ -388,7 +389,7 @@ function this.OnReceiveLogin(str) AppConst.UserId = data.uid AppConst.Token = data.token local openId = AppConst.isSDKLogin and AppConst.OpenId or PlayerPrefs.GetString(openIdkey) - NetManager.LoginRequest(openId, LoginManager.pt_pId, LoginManager.pt_gId, function() + NetManager.LoginRequest(openId, function() if not LoginManager.IsLogin then LoginManager.IsLogin = true this.ExecuteLoading() @@ -516,7 +517,7 @@ function this.OnConnect(network) .. "&platform=" .. 1 .. "&sub_channel=" .. LoginRoot_SubChannel .. "&pid=" .. AppConst.SdkChannel --LoginManager.pt_pId - .. "&gid=" .. "" --LoginManager.pt_gId + .. "&gid=" .. AppConst.SdkPackageName --LoginManager.pt_gId .. "&version=" .. LoginRoot_PackageVersion) networkMgr:SendGetHttp(LoginRoot_Url .. "jl_loginserver/getUserInfo?openId=" .. AppConst.OpenId @@ -525,7 +526,7 @@ function this.OnConnect(network) .. "&platform=" .. 1 .. "&sub_channel=" .. LoginRoot_SubChannel .. "&pid=" .. AppConst.SdkChannel --LoginManager.pt_pId - .. "&gid=" .. "" --LoginManager.pt_gId + .. "&gid=" .. AppConst.SdkPackageName --LoginManager.pt_gId .. "&version=" .. LoginRoot_PackageVersion, this.OnReceiveLogin, nil, nil, nil) else diff --git a/Assets/ManagedResources/~Lua/Modules/Net/NetManager.lua b/Assets/ManagedResources/~Lua/Modules/Net/NetManager.lua index e4d230ccac..cbe118c513 100644 --- a/Assets/ManagedResources/~Lua/Modules/Net/NetManager.lua +++ b/Assets/ManagedResources/~Lua/Modules/Net/NetManager.lua @@ -30,7 +30,7 @@ function this.IsConnect() end --请求登录 -function this.LoginRequest(openId, pt_pid, pt_gid, func) +function this.LoginRequest(openId, func) local data = PlayerInfoProto_pb.LoginRequest() data.device_id_s = AppConst.isSDK and AndroidDeviceInfo.Instance:GetDeviceID() or "" data.idfa_sOr_imei_s = AppConst.isSDK and AndroidDeviceInfo.Instance:GetIMEICode() or "" @@ -43,7 +43,7 @@ function this.LoginRequest(openId, pt_pid, pt_gid, func) data.ip_s = AppConst.isSDK and AndroidDeviceInfo.Instance:GetLocalIpAddress() or "" data.distinct_id = AppConst.isSDK and openId or "" data.openId = openId - data.channel_s = pt_pid.."#"..pt_gid + data.channel_s = AppConst.isSDK and AppConst.SdkChannel .. "#" .. AppConst.SdkPackageName or "" --pt_pid.."#"..pt_gid data.platform_s = AppConst.isSDK and "ADR" or "PC" local msg = data:SerializeToString() @@ -63,16 +63,14 @@ function this.LoginRequest(openId, pt_pid, pt_gid, func) end end AppConst.Token = msg.newToken - -- 打点 ThinkingAnalyticsManager.SetDistinctId(AppConst.OpenId) ThinkingAnalyticsManager.SetSuperProperties({ server_id = LoginManager.ServerId, account = AppConst.OpenId, - ["Bundle-id"] = "123", - xx_id = AppConst.isSDK and "ADR" or "PC" + ["Bundle-id"] = AppConst.SdkPackageName, + xx_id = AppConst.SdkChannel }) - TapDBManager.SetUser(openId) TapDBManager.SetServer(LoginManager.ServerId) end) end @@ -120,12 +118,14 @@ function this.PlayerInfoRequest(func) end -- 数据打点 + ThinkingAnalyticsManager.CalibrateTime(msg.player.serverTime) ThinkingAnalyticsManager.Login(PlayerManager.uid) ThinkingAnalyticsManager.SetSuperProperties({ role_id = PlayerManager.uid, role_name = PlayerManager.nickName, vip_level = msg.player.vipLevel, }) + TapDBManager.SetUser(PlayerManager.uid) TapDBManager.SetLevel(PlayerManager.level) -- diff --git a/Assets/ManagedResources/~Lua/Modules/Pay/PayManager.lua b/Assets/ManagedResources/~Lua/Modules/Pay/PayManager.lua index e20614abf8..96c7a37c3c 100644 --- a/Assets/ManagedResources/~Lua/Modules/Pay/PayManager.lua +++ b/Assets/ManagedResources/~Lua/Modules/Pay/PayManager.lua @@ -87,7 +87,9 @@ function this.RequestPay(context) -- ThinkingAnalyticsManager.Track("create_order", { goods_id = context.Id, + goods_name = context.Name, order_money_amount = context.Price, + ["Bundle-id"] = AppConst.SdkPackageName, }) end diff --git a/Assets/Plugins/Android/AndroidManifest.xml b/Assets/Plugins/Android/AndroidManifest.xml index 9f414899c5..ac2aab8b32 100644 --- a/Assets/Plugins/Android/AndroidManifest.xml +++ b/Assets/Plugins/Android/AndroidManifest.xml @@ -15,17 +15,17 @@ + android:name=".MhtMainActivity"> @@ -37,9 +37,11 @@ - + + + - + @@ -54,9 +56,9 @@ - + - + diff --git a/Assets/Plugins/Android/libs/PSDK/mhtsdk.aar b/Assets/Plugins/Android/libs/PSDK/mhtsdk.aar index a3039fae71..72dd4dc9fd 100644 Binary files a/Assets/Plugins/Android/libs/PSDK/mhtsdk.aar and b/Assets/Plugins/Android/libs/PSDK/mhtsdk.aar differ diff --git a/Assets/Plugins/Android/libs/PSDK/psdk.aar b/Assets/Plugins/Android/libs/PSDK/psdk.aar index 568f0e5d1c..366247062c 100644 Binary files a/Assets/Plugins/Android/libs/PSDK/psdk.aar and b/Assets/Plugins/Android/libs/PSDK/psdk.aar differ diff --git a/Assets/Plugins/Android/libs/PSDK/psdk_mht.aar b/Assets/Plugins/Android/libs/PSDK/psdk_mht.aar index 6a6040e183..9df0589ec9 100644 Binary files a/Assets/Plugins/Android/libs/PSDK/psdk_mht.aar and b/Assets/Plugins/Android/libs/PSDK/psdk_mht.aar differ diff --git a/Assets/Plugins/Android/libs/main.jar b/Assets/Plugins/Android/libs/main.jar index d69f051633..ec4da20a8d 100644 Binary files a/Assets/Plugins/Android/libs/main.jar and b/Assets/Plugins/Android/libs/main.jar differ diff --git a/Assets/Resources/version.txt b/Assets/Resources/version.txt index 09b219e9ec..e7e73835a5 100644 --- a/Assets/Resources/version.txt +++ b/Assets/Resources/version.txt @@ -1 +1 @@ -{"subChannel":"1000", "buglyId":"b67b061643", "channel":"MHT", "resUrl":"http://cdn-jl.lanjingshidai.com/mht_test/", "packageVersion":"0.1", "version":"0.1.0", "serverUrl":"http://106.52.122.168:8080/"} \ No newline at end of file +{"subChannel":"1", "buglyId":"261348dcd3", "channel":"pc", "resUrl":"http://60.1.1.12/jieling_dl/dev/assetBundles/subChannal094-test/", "packageVersion":"0.2", "version":"0.15.0", "serverUrl":"http://60.1.1.23:8080/"} \ No newline at end of file diff --git a/Assets/Source/Generate/AndroidDeviceInfoWrap.cs b/Assets/Source/Generate/AndroidDeviceInfoWrap.cs index 1112fe7641..944135653c 100644 --- a/Assets/Source/Generate/AndroidDeviceInfoWrap.cs +++ b/Assets/Source/Generate/AndroidDeviceInfoWrap.cs @@ -17,6 +17,10 @@ public class AndroidDeviceInfoWrap L.RegFunction("GetLocalIpAddress", GetLocalIpAddress); L.RegFunction("GetDeviceID", GetDeviceID); L.RegFunction("GetIMEICode", GetIMEICode); + L.RegFunction("GetAppName", GetAppName); + L.RegFunction("GetVersionName", GetVersionName); + L.RegFunction("GetVersionCode", GetVersionCode); + L.RegFunction("GetPackageName", GetPackageName); L.RegFunction("SetCopyValue", SetCopyValue); L.RegFunction("GetPastValue", GetPastValue); L.RegFunction("__tostring", ToLua.op_ToString); @@ -193,6 +197,74 @@ public class AndroidDeviceInfoWrap } } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] + static int GetAppName(IntPtr L) + { + try + { + ToLua.CheckArgsCount(L, 1); + AndroidDeviceInfo obj = (AndroidDeviceInfo)ToLua.CheckObject(L, 1); + string o = obj.GetAppName(); + LuaDLL.lua_pushstring(L, o); + return 1; + } + catch (Exception e) + { + return LuaDLL.toluaL_exception(L, e); + } + } + + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] + static int GetVersionName(IntPtr L) + { + try + { + ToLua.CheckArgsCount(L, 1); + AndroidDeviceInfo obj = (AndroidDeviceInfo)ToLua.CheckObject(L, 1); + string o = obj.GetVersionName(); + LuaDLL.lua_pushstring(L, o); + return 1; + } + catch (Exception e) + { + return LuaDLL.toluaL_exception(L, e); + } + } + + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] + static int GetVersionCode(IntPtr L) + { + try + { + ToLua.CheckArgsCount(L, 1); + AndroidDeviceInfo obj = (AndroidDeviceInfo)ToLua.CheckObject(L, 1); + int o = obj.GetVersionCode(); + LuaDLL.lua_pushinteger(L, o); + return 1; + } + catch (Exception e) + { + return LuaDLL.toluaL_exception(L, e); + } + } + + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] + static int GetPackageName(IntPtr L) + { + try + { + ToLua.CheckArgsCount(L, 1); + AndroidDeviceInfo obj = (AndroidDeviceInfo)ToLua.CheckObject(L, 1); + string o = obj.GetPackageName(); + LuaDLL.lua_pushstring(L, o); + return 1; + } + catch (Exception e) + { + return LuaDLL.toluaL_exception(L, e); + } + } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int SetCopyValue(IntPtr L) { diff --git a/Assets/Source/Generate/DelegateFactory.cs b/Assets/Source/Generate/DelegateFactory.cs index 77c0fbd78e..302ac4d67d 100644 --- a/Assets/Source/Generate/DelegateFactory.cs +++ b/Assets/Source/Generate/DelegateFactory.cs @@ -81,6 +81,7 @@ public class DelegateFactory dict.Add(typeof(System.Action), factory.System_Action_string); dict.Add(typeof(UnityEngine.Events.UnityAction), factory.UnityEngine_Events_UnityAction_string_UnityEngine_Object); dict.Add(typeof(SDK.SDKManager.InitLaunchAction), factory.SDK_SDKManager_InitLaunchAction); + dict.Add(typeof(SDK.SDKManager.RegisterAction), factory.SDK_SDKManager_RegisterAction); dict.Add(typeof(SDK.SDKManager.LoginAction), factory.SDK_SDKManager_LoginAction); dict.Add(typeof(SDK.SDKManager.PayAction), factory.SDK_SDKManager_PayAction); dict.Add(typeof(SDK.SDKManager.SwitchAccountAction), factory.SDK_SDKManager_SwitchAccountAction); @@ -162,6 +163,7 @@ public class DelegateFactory DelegateTraits>.Init(factory.System_Action_string); DelegateTraits>.Init(factory.UnityEngine_Events_UnityAction_string_UnityEngine_Object); DelegateTraits.Init(factory.SDK_SDKManager_InitLaunchAction); + DelegateTraits.Init(factory.SDK_SDKManager_RegisterAction); DelegateTraits.Init(factory.SDK_SDKManager_LoginAction); DelegateTraits.Init(factory.SDK_SDKManager_PayAction); DelegateTraits.Init(factory.SDK_SDKManager_SwitchAccountAction); @@ -243,6 +245,7 @@ public class DelegateFactory TypeTraits>.Init(factory.Check_System_Action_string); TypeTraits>.Init(factory.Check_UnityEngine_Events_UnityAction_string_UnityEngine_Object); TypeTraits.Init(factory.Check_SDK_SDKManager_InitLaunchAction); + TypeTraits.Init(factory.Check_SDK_SDKManager_RegisterAction); TypeTraits.Init(factory.Check_SDK_SDKManager_LoginAction); TypeTraits.Init(factory.Check_SDK_SDKManager_PayAction); TypeTraits.Init(factory.Check_SDK_SDKManager_SwitchAccountAction); @@ -324,6 +327,7 @@ public class DelegateFactory StackTraits>.Push = factory.Push_System_Action_string; StackTraits>.Push = factory.Push_UnityEngine_Events_UnityAction_string_UnityEngine_Object; StackTraits.Push = factory.Push_SDK_SDKManager_InitLaunchAction; + StackTraits.Push = factory.Push_SDK_SDKManager_RegisterAction; StackTraits.Push = factory.Push_SDK_SDKManager_LoginAction; StackTraits.Push = factory.Push_SDK_SDKManager_PayAction; StackTraits.Push = factory.Push_SDK_SDKManager_SwitchAccountAction; @@ -4157,6 +4161,63 @@ public class DelegateFactory ToLua.Push(L, o); } + class SDK_SDKManager_RegisterAction_Event : LuaDelegate + { + public SDK_SDKManager_RegisterAction_Event(LuaFunction func) : base(func) { } + public SDK_SDKManager_RegisterAction_Event(LuaFunction func, LuaTable self) : base(func, self) { } + + public void Call(string param0) + { + func.BeginPCall(); + func.Push(param0); + func.PCall(); + func.EndPCall(); + } + + public void CallWithSelf(string param0) + { + func.BeginPCall(); + func.Push(self); + func.Push(param0); + func.PCall(); + func.EndPCall(); + } + } + + public SDK.SDKManager.RegisterAction SDK_SDKManager_RegisterAction(LuaFunction func, LuaTable self, bool flag) + { + if (func == null) + { + SDK.SDKManager.RegisterAction fn = delegate(string param0) { }; + return fn; + } + + if(!flag) + { + SDK_SDKManager_RegisterAction_Event target = new SDK_SDKManager_RegisterAction_Event(func); + SDK.SDKManager.RegisterAction d = target.Call; + target.method = d.Method; + return d; + } + else + { + SDK_SDKManager_RegisterAction_Event target = new SDK_SDKManager_RegisterAction_Event(func, self); + SDK.SDKManager.RegisterAction d = target.CallWithSelf; + target.method = d.Method; + return d; + } + } + + bool Check_SDK_SDKManager_RegisterAction(IntPtr L, int pos) + { + return TypeChecker.CheckDelegateType(typeof(SDK.SDKManager.RegisterAction), L, pos); + } + + void Push_SDK_SDKManager_RegisterAction(IntPtr L, SDK.SDKManager.RegisterAction o) + { + ToLua.Push(L, o); + } + class SDK_SDKManager_LoginAction_Event : LuaDelegate { public SDK_SDKManager_LoginAction_Event(LuaFunction func) : base(func) { } diff --git a/Assets/Source/Generate/GameLogic_AppConstWrap.cs b/Assets/Source/Generate/GameLogic_AppConstWrap.cs index fa964753b5..d5ab3b1b16 100644 --- a/Assets/Source/Generate/GameLogic_AppConstWrap.cs +++ b/Assets/Source/Generate/GameLogic_AppConstWrap.cs @@ -58,6 +58,7 @@ public class GameLogic_AppConstWrap L.RegVar("OpenId", get_OpenId, set_OpenId); L.RegVar("TokenStr", get_TokenStr, set_TokenStr); L.RegVar("SdkChannel", get_SdkChannel, set_SdkChannel); + L.RegVar("SdkPackageName", get_SdkPackageName, set_SdkPackageName); L.RegVar("Url_JoinRoomID", get_Url_JoinRoomID, set_Url_JoinRoomID); L.RegConstant("AppID", 129213); L.RegVar("AppKey", get_AppKey, null); @@ -798,6 +799,20 @@ public class GameLogic_AppConstWrap } } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] + static int get_SdkPackageName(IntPtr L) + { + try + { + LuaDLL.lua_pushstring(L, GameLogic.AppConst.SdkPackageName); + return 1; + } + catch (Exception e) + { + return LuaDLL.toluaL_exception(L, e); + } + } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int get_Url_JoinRoomID(IntPtr L) { @@ -1837,6 +1852,21 @@ public class GameLogic_AppConstWrap } } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] + static int set_SdkPackageName(IntPtr L) + { + try + { + string arg0 = ToLua.CheckString(L, 2); + GameLogic.AppConst.SdkPackageName = arg0; + return 0; + } + catch (Exception e) + { + return LuaDLL.toluaL_exception(L, e); + } + } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int set_Url_JoinRoomID(IntPtr L) { diff --git a/Assets/Source/Generate/GameLogic_ThinkingAnalyticsManagerWrap.cs b/Assets/Source/Generate/GameLogic_ThinkingAnalyticsManagerWrap.cs index 9ecfaa1fa6..4bb605b864 100644 --- a/Assets/Source/Generate/GameLogic_ThinkingAnalyticsManagerWrap.cs +++ b/Assets/Source/Generate/GameLogic_ThinkingAnalyticsManagerWrap.cs @@ -8,6 +8,7 @@ public class GameLogic_ThinkingAnalyticsManagerWrap { L.BeginClass(typeof(GameLogic.ThinkingAnalyticsManager), typeof(GameCore.UnitySingleton)); L.RegFunction("GetDynamicSuperProperties", GetDynamicSuperProperties); + L.RegFunction("CalibrateTime", CalibrateTime); L.RegFunction("SetDistinctId", SetDistinctId); L.RegFunction("GetDistinctId", GetDistinctId); L.RegFunction("Login", Login); @@ -37,6 +38,23 @@ public class GameLogic_ThinkingAnalyticsManagerWrap } } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] + static int CalibrateTime(IntPtr L) + { + try + { + ToLua.CheckArgsCount(L, 2); + GameLogic.ThinkingAnalyticsManager obj = (GameLogic.ThinkingAnalyticsManager)ToLua.CheckObject(L, 1); + long arg0 = LuaDLL.tolua_checkint64(L, 2); + obj.CalibrateTime(arg0); + return 0; + } + catch (Exception e) + { + return LuaDLL.toluaL_exception(L, e); + } + } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int SetDistinctId(IntPtr L) { diff --git a/Assets/Source/Generate/SDK_SDKManagerWrap.cs b/Assets/Source/Generate/SDK_SDKManagerWrap.cs index 554db6ca1b..30f8d3fd3d 100644 --- a/Assets/Source/Generate/SDK_SDKManagerWrap.cs +++ b/Assets/Source/Generate/SDK_SDKManagerWrap.cs @@ -17,6 +17,7 @@ public class SDK_SDKManagerWrap L.RegFunction("GetPayOrderID", GetPayOrderID); L.RegFunction("CaptureShot", CaptureShot); L.RegFunction("InitCallback", InitCallback); + L.RegFunction("RegisterCallback", RegisterCallback); L.RegFunction("LoginCallback", LoginCallback); L.RegFunction("PayCallback", PayCallback); L.RegFunction("SwitchAccountCallback", SwitchAccountCallback); @@ -24,6 +25,7 @@ public class SDK_SDKManagerWrap L.RegFunction("__eq", op_Equality); L.RegFunction("__tostring", ToLua.op_ToString); L.RegVar("onInitLaunchCallback", get_onInitLaunchCallback, set_onInitLaunchCallback); + L.RegVar("onRegisterCallback", get_onRegisterCallback, set_onRegisterCallback); L.RegVar("onLoginCallback", get_onLoginCallback, set_onLoginCallback); L.RegVar("onPayCallback", get_onPayCallback, set_onPayCallback); L.RegVar("onSwitchAccountCallback", get_onSwitchAccountCallback, set_onSwitchAccountCallback); @@ -33,6 +35,7 @@ public class SDK_SDKManagerWrap L.RegFunction("SwitchAccountAction", SDK_SDKManager_SwitchAccountAction); L.RegFunction("PayAction", SDK_SDKManager_PayAction); L.RegFunction("LoginAction", SDK_SDKManager_LoginAction); + L.RegFunction("RegisterAction", SDK_SDKManager_RegisterAction); L.RegFunction("InitLaunchAction", SDK_SDKManager_InitLaunchAction); L.EndClass(); } @@ -202,6 +205,23 @@ public class SDK_SDKManagerWrap } } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] + static int RegisterCallback(IntPtr L) + { + try + { + ToLua.CheckArgsCount(L, 2); + SDK.SDKManager obj = (SDK.SDKManager)ToLua.CheckObject(L, 1); + string arg0 = ToLua.CheckString(L, 2); + obj.RegisterCallback(arg0); + return 0; + } + catch (Exception e) + { + return LuaDLL.toluaL_exception(L, e); + } + } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int LoginCallback(IntPtr L) { @@ -307,6 +327,25 @@ public class SDK_SDKManagerWrap } } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] + static int get_onRegisterCallback(IntPtr L) + { + object o = null; + + try + { + o = ToLua.ToObject(L, 1); + SDK.SDKManager obj = (SDK.SDKManager)o; + SDK.SDKManager.RegisterAction ret = obj.onRegisterCallback; + ToLua.Push(L, ret); + return 1; + } + catch(Exception e) + { + return LuaDLL.toluaL_exception(L, e, o, "attempt to index onRegisterCallback on a nil value"); + } + } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int get_onLoginCallback(IntPtr L) { @@ -421,6 +460,25 @@ public class SDK_SDKManagerWrap } } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] + static int set_onRegisterCallback(IntPtr L) + { + object o = null; + + try + { + o = ToLua.ToObject(L, 1); + SDK.SDKManager obj = (SDK.SDKManager)o; + SDK.SDKManager.RegisterAction arg0 = (SDK.SDKManager.RegisterAction)ToLua.CheckDelegate(L, 2); + obj.onRegisterCallback = arg0; + return 0; + } + catch(Exception e) + { + return LuaDLL.toluaL_exception(L, e, o, "attempt to index onRegisterCallback on a nil value"); + } + } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int set_onLoginCallback(IntPtr L) { @@ -605,6 +663,33 @@ public class SDK_SDKManagerWrap } } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] + static int SDK_SDKManager_RegisterAction(IntPtr L) + { + try + { + int count = LuaDLL.lua_gettop(L); + LuaFunction func = ToLua.CheckLuaFunction(L, 1); + + if (count == 1) + { + Delegate arg1 = DelegateTraits.Create(func); + ToLua.Push(L, arg1); + } + else + { + LuaTable self = ToLua.CheckLuaTable(L, 2); + Delegate arg1 = DelegateTraits.Create(func, self); + ToLua.Push(L, arg1); + } + return 1; + } + catch(Exception e) + { + return LuaDLL.toluaL_exception(L, e); + } + } + [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int SDK_SDKManager_InitLaunchAction(IntPtr L) { diff --git a/BuildABs/Android/files.unity3d b/BuildABs/Android/files.unity3d index 9bdca1da8b..445322e684 100644 Binary files a/BuildABs/Android/files.unity3d and b/BuildABs/Android/files.unity3d differ diff --git a/BuildABs/Android/lzma/luabytes.unity3d b/BuildABs/Android/lzma/luabytes.unity3d index 4f46e913ca..ba4a9437bc 100644 Binary files a/BuildABs/Android/lzma/luabytes.unity3d and b/BuildABs/Android/lzma/luabytes.unity3d differ diff --git a/BuildABs/Android/lzma/resconfigs.unity3d b/BuildABs/Android/lzma/resconfigs.unity3d index 66def6ff95..72063576c7 100644 Binary files a/BuildABs/Android/lzma/resconfigs.unity3d and b/BuildABs/Android/lzma/resconfigs.unity3d differ diff --git a/ProjectSettings/ProjectSettings.asset b/ProjectSettings/ProjectSettings.asset index 59e0b83757..3a91a4da4d 100644 --- a/ProjectSettings/ProjectSettings.asset +++ b/ProjectSettings/ProjectSettings.asset @@ -13,7 +13,7 @@ PlayerSettings: useOnDemandResources: 0 accelerometerFrequency: 60 companyName: Test - productName: "\u592A\u521D\u884C\u6D4B\u8BD5\u5305" + productName: "\u5185\u7F51\u6D4B\u8BD5\u5305" defaultCursor: {fileID: 0} cursorHotspot: {x: 0, y: 0} m_SplashScreenBackgroundColor: {r: 0, g: 0, b: 0, a: 1} @@ -155,7 +155,7 @@ PlayerSettings: androidSupportedAspectRatio: 1 androidMaxAspectRatio: 2.1 applicationIdentifier: - Android: com.mht.tcxcsb.project + Android: com.local.test Standalone: com.doudou.dwc Tizen: com.junfine.luaframework iOS: com.doudou.dwc diff --git a/ReadMe!/SDK接入相关文档/【戒灵】猕猴桃出包需求2020.7.23/PSDKV1.0.14_0723.zip b/ReadMe!/SDK接入相关文档/【戒灵】猕猴桃出包需求2020.7.23/PSDKV1.0.14_0723.zip new file mode 100644 index 0000000000..93793dfaa0 Binary files /dev/null and b/ReadMe!/SDK接入相关文档/【戒灵】猕猴桃出包需求2020.7.23/PSDKV1.0.14_0723.zip differ diff --git a/ReadMe!/SDK接入相关文档/【戒灵】猕猴桃出包需求2020.7.23/《戒灵》猕猴桃出包需求2020.7.23.xlsx b/ReadMe!/SDK接入相关文档/【戒灵】猕猴桃出包需求2020.7.23/《戒灵》猕猴桃出包需求2020.7.23.xlsx new file mode 100644 index 0000000000..7c69c327cd Binary files /dev/null and b/ReadMe!/SDK接入相关文档/【戒灵】猕猴桃出包需求2020.7.23/《戒灵》猕猴桃出包需求2020.7.23.xlsx differ diff --git a/ReadMe!/SDK接入相关文档/【戒灵】猕猴桃出包需求2020.7.23/正式包参数.txt b/ReadMe!/SDK接入相关文档/【戒灵】猕猴桃出包需求2020.7.23/正式包参数.txt new file mode 100644 index 0000000000..ccff2e1938 --- /dev/null +++ b/ReadMe!/SDK接入相关文档/【戒灵】猕猴桃出包需求2020.7.23/正式包参数.txt @@ -0,0 +1,5 @@ +游戏名称: 代号:源起 +appid:b5122eb744689d247d82eea37e9741f6 +rhappid:7bb5f604306ccd93fc19f05d3a374e84 +支付秘钥:5b980134872a8afa993f8a3b35a8efbd +channelid:MHT \ No newline at end of file diff --git a/ReadMe!/SDK接入相关文档/【戒灵】猕猴桃出包需求2020.7.23/测试包参数.txt b/ReadMe!/SDK接入相关文档/【戒灵】猕猴桃出包需求2020.7.23/测试包参数.txt new file mode 100644 index 0000000000..612c2315d4 --- /dev/null +++ b/ReadMe!/SDK接入相关文档/【戒灵】猕猴桃出包需求2020.7.23/测试包参数.txt @@ -0,0 +1,5 @@ +游戏名称: 太初行测试包 +appid:e4ecefecc8034cffaa69e81b2c044f2c +rhappid:d0265404f55536a5c8b0ec33a9da27d3 +支付秘钥:d69dfa85e5a703b911f4d08711b739a2 +channelid:MHT \ No newline at end of file