mirror of
https://github.com/smallfawn/QLScriptPublic.git
synced 2025-12-18 15:54:44 +08:00
Update gqcq.js
This commit is contained in:
23
gqcq.js
23
gqcq.js
@@ -20,7 +20,7 @@ const ckName = "gqcq_data";
|
|||||||
const Notify = 1; //0为关闭通知,1为打开通知,默认为1
|
const Notify = 1; //0为关闭通知,1为打开通知,默认为1
|
||||||
const notify = $.isNode() ? require('./sendNotify') : '';
|
const notify = $.isNode() ? require('./sendNotify') : '';
|
||||||
let envSplitor = ["@"]; //多账号分隔符
|
let envSplitor = ["@"]; //多账号分隔符
|
||||||
let msg; //let ck,msg
|
let msg;//声明通知变量
|
||||||
let userCookie = ($.isNode() ? process.env[ckName] : $.getdata(ckName)) || '';
|
let userCookie = ($.isNode() ? process.env[ckName] : $.getdata(ckName)) || '';
|
||||||
let userList = [];
|
let userList = [];
|
||||||
let userIdx = 0;
|
let userIdx = 0;
|
||||||
@@ -97,9 +97,10 @@ class UserInfo {
|
|||||||
"Accept-Language": "zh-CN,zh;q=0.9,en-US;q=0.8,en;q=0.7",
|
"Accept-Language": "zh-CN,zh;q=0.9,en-US;q=0.8,en;q=0.7",
|
||||||
"Content-Type": "application/x-www-form-urlencoded",
|
"Content-Type": "application/x-www-form-urlencoded",
|
||||||
}
|
}
|
||||||
|
this.randomTime1 = this.getRandomTime('1')
|
||||||
|
this.randomTime2 = this.getRandomTime('1')
|
||||||
|
|
||||||
|
|
||||||
this.randomTime1 = randomInt(2000,9000)
|
|
||||||
this.randomTime2 = randomInt(11000,19000)
|
|
||||||
|
|
||||||
}
|
}
|
||||||
getSign(ts, reqNonc) {
|
getSign(ts, reqNonc) {
|
||||||
@@ -119,6 +120,18 @@ class UserInfo {
|
|||||||
let text = add_comment_text_arr[ranNum]
|
let text = add_comment_text_arr[ranNum]
|
||||||
return text
|
return text
|
||||||
}
|
}
|
||||||
|
getRandomTime(type) {
|
||||||
|
let randomTime;
|
||||||
|
switch (type) {
|
||||||
|
case '1':
|
||||||
|
randomTime = randomInt(2000, 9000)
|
||||||
|
break;
|
||||||
|
case '2':
|
||||||
|
randomTime = randomInt(11000, 19000)
|
||||||
|
break
|
||||||
|
}
|
||||||
|
return randomTime;
|
||||||
|
}
|
||||||
async user_info() {//userinfo
|
async user_info() {//userinfo
|
||||||
try {
|
try {
|
||||||
let options = {
|
let options = {
|
||||||
@@ -172,7 +185,7 @@ class UserInfo {
|
|||||||
// console.log(result)
|
// console.log(result)
|
||||||
if (result.errorCode == 20000) {
|
if (result.errorCode == 20000) {
|
||||||
this.box = result.data
|
this.box = result.data
|
||||||
DoubleLog(`账号[${this.index}], 共有宝箱:${this.box.length}个!`)
|
DoubleLog(`账号[${this.index}] 共有宝箱:${this.box.length}个!`)
|
||||||
|
|
||||||
if (this.box.length > 0) {
|
if (this.box.length > 0) {
|
||||||
for (let i = 0; i < this.box.length; i++) {
|
for (let i = 0; i < this.box.length; i++) {
|
||||||
@@ -197,7 +210,7 @@ class UserInfo {
|
|||||||
let result = await httpRequest(options)
|
let result = await httpRequest(options)
|
||||||
// console.(result)
|
// console.(result)
|
||||||
if (result.errorCode == 20000) {
|
if (result.errorCode == 20000) {
|
||||||
DoubleLog(`账号[${this.index}], 开宝箱:${result.errorMessage} ,恭喜你获得 ${result.data.medalName} 奖品为 ${result.data.medalDescription}`)
|
DoubleLog(`账号[${this.index}] 开宝箱:${result.errorMessage} ,恭喜你获得 ${result.data.medalName} 奖品为 ${result.data.medalDescription}`)
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user