Skip to content

Commit 2313528

Browse files
committed
Merge branch 'master' into v66_dev
2 parents 3047e57 + 10a4eb8 commit 2313528

19 files changed

+1005
-95
lines changed

src/common/commonConfig.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,4 +39,9 @@ const CommonConfig = [{
3939
]
4040
}];
4141

42-
export default CommonConfig;
42+
export default CommonConfig;
43+
44+
export const commonConfigVal = CommonConfig[0].config.reduce((acc, cur) => {
45+
acc[cur.name] = cur.default;
46+
return acc;
47+
}, {});

src/common/funcList/001_准备.ts

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,56 @@ export class Func001 implements IFuncOrigin {
3232
oper: [
3333
[left, 1280, 720, 37, 637, 86, 686, 1000]
3434
]
35+
}, { // 2 准备界面无左上角取点
36+
desc: [
37+
1280, 720,
38+
[
39+
[left, 42, 681, 0xe49780],
40+
[left, 49, 682, 0xfff9ef],
41+
[left, 124, 682, 0xfef1d8],
42+
[left, 150, 682, 0xfbdec5],
43+
[center, 438, 701, 0x231917],
44+
[right, 1188, 684, 0xa26f4d],
45+
]
46+
]
47+
}, { // 3 准备界面左上角取点
48+
desc: [
49+
1280, 720,
50+
[
51+
[left, 46, 33, 0xd9b589],
52+
[left, 106, 41, 0xd0a77b],
53+
[left, 168, 23, 0xd4ae84],
54+
[left, 180, 38, 0xcba073],
55+
]
56+
]
57+
}, { // 4 准备界面经典主题
58+
desc: [
59+
1280, 720,
60+
[
61+
[left, 41, 681, 0xdf8471],
62+
[left, 49, 680, 0xfff7ec],
63+
[left, 36, 567, 0x913157],
64+
[left, 122, 686, 0xfdead1],
65+
[center, 441, 645, 0x573c3c],
66+
[right, 1169, 672, 0xd5a86c],
67+
]
68+
]
3569
}];
3670
operatorFunc(thisScript: Script, thisOperator: IFuncOperator[]): boolean {
3771
const thisconf = thisScript.scheme.config['1'];
72+
if (thisScript.oper({
73+
id: 1,
74+
name: '准备界面识别',
75+
operator: [{ desc: thisOperator[2].desc }
76+
, { desc: thisOperator[4].desc }]
77+
}) && !thisScript.oper({
78+
name: '准备界面识别',
79+
operator: [thisOperator[3]]
80+
})) {
81+
thisScript.regionClick([thisOperator[0].oper[1]]);
82+
thisScript.myToast('战斗主题非简约主题,部分功能失效,请及时跟换', 10000);
83+
return true;
84+
}
3885
if (thisconf.exitBeforeReady) {
3986
return thisScript.oper({
4087
id: 1,

src/common/funcList/009_结界_勋章点击.ts

Lines changed: 40 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ import { IFuncOrigin, IFuncOperatorOrigin, IFuncOperator } from '@/interface/IFu
33

44
// const normal = -1; //定义常量
55
const left = 0;
6-
// const center = 1;
7-
// const right = 2;
6+
const center = 1;
7+
const right = 2;
88

99
export class Func009 implements IFuncOrigin {
1010
id = 9;
@@ -47,8 +47,46 @@ export class Func009 implements IFuncOrigin {
4747
// [left, 1280, 720, 0, 0, 1279, 719, 500]
4848
[left, 1280, 720, 147, 146, 465, 265, 500]
4949
]
50+
}, { // 2 解锁阵容
51+
desc: [
52+
1280, 720,
53+
[
54+
[center, 818, 599, 0xbdaef2],
55+
[center, 853, 599, 0xbab4f4],
56+
[center, 830, 595, 0x886d4a],
57+
[center, 830, 601, 0x836847],
58+
[center, 852, 601, 0xb6b6ff],
59+
[left, 74, 168, 0xd4bb9d],
60+
[left, 36, 456, 0x5e606b],
61+
]
62+
],
63+
oper: [
64+
[center, 1280, 720, 821, 593, 850, 609, 1000],
65+
]
66+
}, { // 3 解锁阵容_寮突破
67+
desc: [
68+
1280, 720,
69+
[
70+
[left, 198, 617, 0xbfaef2],
71+
[left, 233, 616, 0xbdb2e9],
72+
[left, 209, 613, 0x886e4b],
73+
[left, 210, 621, 0x846947],
74+
[left, 233, 618, 0xb6b6ff],
75+
[right, 1214, 284, 0x5e3c27],
76+
[right, 1211, 405, 0x8b5221],
77+
]
78+
],
79+
oper: [
80+
[center, 1280, 720, 202, 608, 227, 628, 1000],
81+
]
5082
}];
5183
operatorFunc(thisScript: Script, thisOperator: IFuncOperator[]): boolean {
84+
if (thisScript.oper({
85+
name: '突破界面_判断',
86+
operator: [thisOperator[2], thisOperator[3]]
87+
})) {
88+
return true;
89+
}
5290
if (thisScript.oper({
5391
name: '突破界面_判断',
5492
operator: [{ desc: thisOperator[0].desc }]

src/common/funcList/017_百鬼夜行.ts

Lines changed: 21 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,7 @@ export class Func017 implements IFuncOrigin {
9898
oper: [
9999
[center, 1280, 720, 468, 233, 624, 550, 500],
100100
[center, 1280, 720, 731, 229, 890, 563, 500],
101+
[center, 1280, 720, 516, 632, 749, 700, 1000],
101102
]
102103
}, { // 5
103104
desc: [1280, 720,
@@ -134,7 +135,8 @@ export class Func017 implements IFuncOrigin {
134135
[center, 1128, 594, 0x402f1f],
135136
[center, 1084, 202, 0xe7d4cf],
136137
[center, 554, 514, 0x846866],
137-
[center, 195, 156, 0xf9edee]]
138+
[center, 195, 156, 0xf9edee]
139+
]
138140
],
139141
oper: [
140142
[center, 1280, 720, 1084, 576, 1138, 628, 1500]
@@ -144,11 +146,26 @@ export class Func017 implements IFuncOrigin {
144146
const thisconf = thisScript.scheme.config['17'];
145147
if (thisScript.oper({
146148
id: 17,
147-
name: '百鬼夜行_杂项',
148-
operator: [thisOperator[3], thisOperator[6], {
149+
name: '百鬼夜行_杂项_前',
150+
operator: [thisOperator[3]]
151+
})) {
152+
return true
153+
}
154+
if (thisScript.oper({
155+
id: 17,
156+
name: '百鬼夜行_邀请好友',
157+
operator: [{
149158
desc: thisOperator[4].desc,
150159
oper: [thisOperator[4].oper[random(0, 1)]]
151-
}, thisOperator[7]]
160+
}]
161+
})) {
162+
thisScript.regionClick([thisOperator[4].oper[2]]);
163+
thisScript.keepScreen(false);
164+
}
165+
if (thisScript.oper({
166+
id: 17,
167+
name: '百鬼夜行_杂项_后',
168+
operator: [thisOperator[6], thisOperator[7]]
152169
})) {
153170
return true
154171
}
Lines changed: 143 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,143 @@
1+
import { Script } from '@/system/script';
2+
import { IFuncOrigin, IFuncOperatorOrigin, IFuncOperator } from '@/interface/IFunc';
3+
// const normal = -1; //定义常量
4+
// const left = 0;
5+
const center = 1;
6+
const right = 2;
7+
8+
export class Func019 implements IFuncOrigin {
9+
id = 19;
10+
name = '协同对弈';
11+
desc = '进行协同对弈开始或结束等操作';
12+
operator: IFuncOperatorOrigin[] = [{ // 自动上阵
13+
desc: [
14+
1280, 720,
15+
[
16+
[right, 994, 656, 0x826952],
17+
[right, 1064, 654, 0x826952],
18+
[right, 1021, 638, 0xffffff],
19+
[right, 1041, 641, 0xfdfdfd],
20+
[right, 1012, 626, 0xf2f2f1],
21+
[right, 1053, 630, 0xfefefe],
22+
[right, 1159, 619, 0xe6d5b5],
23+
]
24+
],
25+
oper: [
26+
[center, 1280, 720, 993, 621, 1058, 677, 1000],
27+
]
28+
}, { // 1 取消自动_战
29+
desc: [
30+
1280, 720,
31+
[
32+
[right, 1006, 630, 0xfbfafa],
33+
[right, 1022, 633, 0xffffff],
34+
[right, 1041, 634, 0xfafaf9],
35+
[right, 1020, 640, 0xf2f1f1],
36+
[right, 1043, 642, 0xf8f7f7],
37+
[right, 1064, 645, 0x826952],
38+
[right, 993, 642, 0x826952],
39+
[right, 1159, 619, 0xe6d5b5],
40+
]
41+
],
42+
oper: [
43+
[center, 1280, 720, 1152, 594, 1243, 648, 1000],
44+
]
45+
}, { // 2 特写
46+
desc: [
47+
1280, 720,
48+
[
49+
[right, 1067, 632, 0x5eafbf],
50+
[right, 1093, 617, 0xfbecd1],
51+
[right, 1100, 633, 0x5aaeb9],
52+
[right, 1165, 633, 0x733841],
53+
[right, 1189, 643, 0x3e2829],
54+
]
55+
],
56+
oper: [
57+
[center, 1280, 720, 491, 530, 721, 658, 1000],
58+
]
59+
}, { // 3 胜利
60+
desc: [
61+
1280, 720,
62+
[
63+
[center, 481, 94, 0x831a11],
64+
[center, 504, 126, 0x8e1a11],
65+
[center, 751, 124, 0xb19968],
66+
[center, 907, 114, 0xdac395],
67+
[center, 756, 165, 0x89653e],
68+
]
69+
],
70+
oper: [
71+
[center, 1280, 720, 491, 530, 721, 658, 1000],
72+
]
73+
}, { // 4 失败
74+
desc: [
75+
1280, 720,
76+
[
77+
[center, 470, 83, 0x514a5b],
78+
[center, 451, 120, 0x5a5164],
79+
[center, 499, 124, 0x5e5468],
80+
[center, 727, 108, 0xb5aea0],
81+
[center, 921, 115, 0xa79e8f],
82+
[center, 851, 164, 0x756a5c],
83+
[center, 781, 189, 0x62574a],
84+
]
85+
],
86+
oper: [
87+
[center, 1280, 720, 491, 530, 721, 658, 1000],
88+
]
89+
}, { // 5 番胜
90+
desc: [
91+
1280, 720,
92+
[
93+
[center, 521, 345, 0x671915],
94+
[center, 781, 352, 0xa2372c],
95+
[center, 497, 271, 0x9e9958],
96+
[center, 822, 284, 0xdd5440],
97+
[center, 521, 385, 0xc73527],
98+
]
99+
],
100+
oper: [
101+
[center, 1280, 720, 491, 530, 721, 658, 1000],
102+
]
103+
}, { // 6 开始前
104+
desc: [
105+
1280, 720,
106+
[
107+
[center, 778, 630, 0xa27c67],
108+
[center, 882, 637, 0xc8a77b],
109+
[right, 979, 650, 0x977461],
110+
[right, 1080, 641, 0xebd1a0],
111+
[right, 1169, 617, 0xe7d8bb],
112+
]
113+
]
114+
}]
115+
operatorFunc(thisScript: Script, thisOperator: IFuncOperator[]): boolean {
116+
if (thisScript.oper({
117+
name: '协同对弈_界面判断',
118+
operator: [thisOperator[0], thisOperator[2], thisOperator[3], thisOperator[4], thisOperator[5]]
119+
})) {
120+
return true;
121+
}
122+
let curCnt = 0;
123+
const maxCount = 3;
124+
while (thisScript.oper({
125+
id: 19,
126+
name: '协同对弈_开始',
127+
operator: [thisOperator[6], thisOperator[1]]
128+
})) {
129+
curCnt++;
130+
thisScript.keepScreen(false);
131+
if (curCnt >= maxCount) {
132+
thisScript.myToast('开始对弈前画面,脚本自动停止');
133+
sleep(2000);
134+
thisScript.doPush(thisScript, { text: `[${thisScript.schemeHistory.map(item => item.schemeName).join('、')}]已停止,请查看。` });
135+
thisScript.stop();
136+
sleep(2000);
137+
return false;
138+
}
139+
sleep(1000);
140+
}
141+
return false;
142+
}
143+
}

src/common/funcList/027_组队_创建或匹配.ts

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,13 +145,33 @@ export class Func027 implements IFuncOrigin {
145145
[center, 1280, 720, 413, 450, 574, 485, 700], // 魂土
146146
[center, 1280, 720, 414, 516, 571, 553, 700], // 魂王
147147
]
148+
}, { // 13 第二栏的全部字样
149+
desc: [1280, 720,
150+
[
151+
[left, 237, 219, 0x2c2924],
152+
[left, 230, 229, 0x272420],
153+
[left, 238, 229, 0x272420],
154+
[left, 275, 228, 0x443f38],
155+
]
156+
],
157+
oper: [
158+
[center, 1280, 720, 255, 230, 260, 235, 1000], // 副本上划起始
159+
[center, 1280, 720, 255, 155, 260, 160, 1000], // 副本上划结束
160+
]
148161
}]
149162
operatorFunc(thisScript: Script, thisOperator: IFuncOperator[]): boolean {
150163
const thisConf = thisScript.scheme.config['27'];
151164
if (!thisScript.global.first_create_team && thisScript.oper({
152165
name: '组队置顶',
153-
operator: [{ desc: thisOperator[12].desc }]
166+
operator: [{ desc: thisOperator[12].desc }, { desc: thisOperator[13].desc }]
154167
})) {
168+
if (thisScript.oper({
169+
name: '组队置顶',
170+
operator: [{ desc: thisOperator[13].desc }]
171+
})) {
172+
thisScript.regionBezierSwipe(thisOperator[13].oper[0], thisOperator[13].oper[1], [2000, 2050], 500);
173+
return true;
174+
}
155175
switch (thisConf.mission) {
156176
case '御魂':
157177
thisScript.regionClick([thisOperator[12].oper[0]]);

src/common/funcList/028_继续育成.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@ export class Func028 implements IFuncOrigin {
4141
[left, 44, 37, 0xf5e8a9],
4242
[center, 964, 631, 0xcbb9b2],
4343
[center, 919, 642, 0xf4b25f],
44-
[right, 1233, 45, 0xd7c5a2],
4544
[right, 1222, 161, 0xfbeddb],
4645
[center, 598, 674, 0x2b1f1b]]
4746
],

0 commit comments

Comments
 (0)