Bläddra i källkod

增加user/machine

zouyong 5 år sedan
förälder
incheckning
da0ab31bd3

+ 13 - 3
assets/script/game/data/AppData.ts

@@ -17,6 +17,11 @@ export class AppData {
     /** api版本 */
     public version: string = '1.0.0';
 
+    /** UserAgent */
+    UA = '';
+
+    IP = '';
+
     /** 李杨/悍国服的appId */
     // public appId: string = 'wxcf31f0e54f7fefda';
     /** 测试服/正式服的appId */
@@ -40,7 +45,8 @@ export class AppData {
         "imei": "",
         "mac": "",
         "oaid": "",
-        "umid": ""
+        "umid": "",
+        "UA": ""
     };
 
     /**
@@ -56,19 +62,23 @@ export class AppData {
         this.machineInfo.mac = this.mac = arr[3];
         this.machineInfo.oaid = arr[4];
         this.machineInfo.umid = arr[5];
+        this.machineInfo.UA = arr[11];
         this.tfChannel = arr[6];
         this.appVersion = arr[7];
-
+        
         /** 友盟渠道 */
         this.umengChannel = arr[8];
         /** 设备型号 */
         this.deviceType = arr[9];
         /** 安卓版本号 */
         this.androidVersion = arr[10];
-
+        this.IP = arr[12]
+        
         this.getDeviceInfoCompelete = true;
         console.log("===[this.tfChannel", this.tfChannel);
         console.log("===[this.appVersion", this.appVersion);
+
+
     }
 
     public init() {

+ 4 - 1
assets/script/game/data/LoginData.ts

@@ -237,7 +237,10 @@ export class LoginData {
             "encrypt": mk.encrypt.encrypt(JSON.stringify(aa), this.sessionKey, gData.appData.appId)
         };
 
-        let response = await mk.http.sendRequest('user', 'POST', JSON.stringify(data), false, false);
+        let response = await mk.http.sendData('user/machine',gData.appData.machineInfo);
+        mk.console.logSingle("user/machine:", response);
+
+        response = await mk.http.sendRequest('user', 'POST', JSON.stringify(data), false, false);
         if (response.errcode != 0) {
             if (response.errcode == -10003 || response.errcode == -20003) {
                 //清除缓存

BIN
build/jsb-link/assets/main/index.jsc


Filskillnaden har hållts tillbaka eftersom den är för stor
+ 0 - 0
build/jsb-link/assets/resources/config.json


BIN
build/jsb-link/frameworks/runtime-src/proj.android-studio/.idea/caches/build_file_checksums.ser


+ 12 - 2
build/jsb-link/js backups (useful for debugging)/main.index.js

@@ -2132,6 +2132,8 @@ this.appNameBugly = "3xiao";
 this.appVersion = "";
 this.tfChannel = "";
 this.version = "1.0.0";
+this.UA = "";
+this.IP = "";
 this.appId = "wxcf31f0e54f7fefda";
 this.umengChannel = "";
 this.deviceType = "";
@@ -2143,7 +2145,8 @@ idfa: "",
 imei: "",
 mac: "",
 oaid: "",
-umid: ""
+umid: "",
+UA: ""
 };
 this.updateState = o.None;
 }
@@ -2155,11 +2158,13 @@ this.machineInfo.imei = e[2];
 this.machineInfo.mac = this.mac = e[3];
 this.machineInfo.oaid = e[4];
 this.machineInfo.umid = e[5];
+this.machineInfo.UA = e[11];
 this.tfChannel = e[6];
 this.appVersion = e[7];
 this.umengChannel = e[8];
 this.deviceType = e[9];
 this.androidVersion = e[10];
+this.IP = e[12];
 this.getDeviceInfoCompelete = !0;
 console.log("===[this.tfChannel", this.tfChannel);
 console.log("===[this.appVersion", this.appVersion);
@@ -11521,9 +11526,14 @@ e = {
 uin: this.uin,
 encrypt: mk.encrypt.encrypt(JSON.stringify(t), this.sessionKey, gData.appData.appId)
 };
-return [ 4, mk.http.sendRequest("user", "POST", JSON.stringify(e), !1, !1) ];
+return [ 4, mk.http.sendData("user/machine", gData.appData.machineInfo) ];
 
 case 1:
+n = o.sent();
+mk.console.logSingle("user/machine:", n);
+return [ 4, mk.http.sendRequest("user", "POST", JSON.stringify(e), !1, !1) ];
+
+case 2:
 if (0 != (n = o.sent()).errcode) {
 -10003 != n.errcode && -20003 != n.errcode || this.reload();
 return [ 2 ];

+ 2 - 2
packages-hot-update/cfg.json

@@ -8,7 +8,7 @@
         "https://xcx-box.oss-cn-hangzhou.aliyuncs.com/hotgame/EasyEliminateTest/baseRemote/",
         "https://xcx-box.oss-cn-hangzhou.aliyuncs.com/hotgame/EasyEliminate/baseRemote/"
     ],
-    "buildTime": 1627033184930,
-    "genTime": 1627033184930,
+    "buildTime": 1627367028494,
+    "genTime": 1627367028494,
     "genVersion": null
 }

Vissa filer visades inte eftersom för många filer har ändrats