Skip to content

Update 微软积分商城签到.user.js #20

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 19 additions & 9 deletions 微软积分商城签到.user.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,10 @@ Config:
title: 微软必应App(每日签到 + 文章阅读)
type: checkbox
default: false
promo:
title: 每日活动+推广活动
type: checkbox
default: false
limit:
title: 限制搜索(每次运行只搜索 4-8 次)
type: checkbox
Expand Down Expand Up @@ -379,10 +383,12 @@ obj.getRewardsToken = function () {
obj.taskPromo = async function () {
if (obj.task.promo.end > 0) {
return true
} else if (obj.data.time.hoursNow < 12) {
obj.task.promo.end++
return true
} else if (obj.task.promo.times > 2) {
}
//else if (obj.data.time.hoursNow < 12) {
// obj.task.promo.end++
// return true
// }
else if (obj.task.promo.times > 2) {
obj.task.promo.end++
obj.pushMsg("活动推广🔴", "未知原因出错,本次活动推广结束!")
return true
Expand Down Expand Up @@ -739,7 +745,7 @@ return new Promise((resolve, reject) => {
obj.promoStart = async function () {
try {
const result = await obj.taskPromo()
result ? obj.taskEnd() : setTimeout(() => { obj.promoStart() }, obj.data.time.task)
result ? obj.taskEnd() : setTimeout(() => { obj.promoStart() }, obj.data.time.task)
} catch (e) {
reject(e)
}
Expand All @@ -760,9 +766,13 @@ return new Promise((resolve, reject) => {
obj.task.sign.end++
obj.task.read.end++
}
obj.promoStart()
obj.signStart()
obj.readStart()
obj.searchStart()
if(GM_getValue("Config.promo", false) == false){
obj.task.promo.end++
}

if (obj.task.sign.end == 0 || GM_getValue("task_sign", 0) == obj.data.time.dateNowNum) {obj.signStart()}
if (obj.task.read.end == 0 || GM_getValue("task_read", 0) == obj.data.time.dateNowNum) {obj.readStart()}
if (obj.task.promo.end == 0 || GM_getValue("task_promo", 0) == obj.data.time.dateNowNum) {obj.promoStart()}
if (obj.task.search.end == 0 || GM_getValue("task_search", 0) == obj.data.time.dateNowNum) {obj.searchStart()}
}()
})