|
|
|
@ -91,12 +91,29 @@ public class Task_自动练兵 extends BaseTask {
|
|
|
|
|
macro.mouseLeftClick(viewRects2[1]);
|
|
|
|
|
macro.delay(1000);
|
|
|
|
|
|
|
|
|
|
Logger.info("点击兵营");
|
|
|
|
|
macro.mouseLeftClick(macro.of(268, 431));
|
|
|
|
|
macro.delay(1000);
|
|
|
|
|
|
|
|
|
|
Logger.info("点击训练");
|
|
|
|
|
macro.mouseLeftClick(macro.of(355, 632));
|
|
|
|
|
macro.delay(1000);
|
|
|
|
|
|
|
|
|
|
Logger.info("检测任意位置继续");
|
|
|
|
|
ViewRect 兵营_任意位置继续 = macro.waitAndMatchLegend("兵营_任意位置继续", 0.9, 2);
|
|
|
|
|
if (兵营_任意位置继续 != null) {
|
|
|
|
|
Logger.info("点击继续");
|
|
|
|
|
macro.mouseLeftClick(兵营_任意位置继续);
|
|
|
|
|
macro.delay(1500);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
ViewRect 兵营_训练 = macro.waitAndMatchLegend("兵营_训练", 0.9, 2);
|
|
|
|
|
if (兵营_训练 == null) {
|
|
|
|
|
Logger.error("训练失败,未检测到兵营训练");
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
Logger.info("确认训练");
|
|
|
|
|
macro.mouseLeftClick(macro.of(396, 885));
|
|
|
|
|
macro.mouseLeftClick(兵营_训练);
|
|
|
|
|
macro.delay(1000);
|
|
|
|
|
|
|
|
|
|
ViewRect 兵营_返回 = macro.matchLegend("兵营_返回", 0.9D);
|
|
|
|
@ -192,12 +209,29 @@ public class Task_自动练兵 extends BaseTask {
|
|
|
|
|
macro.mouseLeftClick(viewRects2[1]);
|
|
|
|
|
macro.delay(1000);
|
|
|
|
|
|
|
|
|
|
Logger.info("点击兵营");
|
|
|
|
|
macro.mouseLeftClick(macro.of(268, 431));
|
|
|
|
|
macro.delay(1000);
|
|
|
|
|
|
|
|
|
|
Logger.info("点击训练");
|
|
|
|
|
macro.mouseLeftClick(macro.of(355, 632));
|
|
|
|
|
macro.delay(1000);
|
|
|
|
|
|
|
|
|
|
Logger.info("检测任意位置继续");
|
|
|
|
|
ViewRect 兵营_任意位置继续 = macro.waitAndMatchLegend("兵营_任意位置继续", 0.9, 2);
|
|
|
|
|
if (兵营_任意位置继续 != null) {
|
|
|
|
|
Logger.info("点击继续");
|
|
|
|
|
macro.mouseLeftClick(兵营_任意位置继续);
|
|
|
|
|
macro.delay(1500);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
ViewRect 兵营_训练 = macro.waitAndMatchLegend("兵营_训练", 0.9, 2);
|
|
|
|
|
if (兵营_训练 == null) {
|
|
|
|
|
Logger.error("训练失败,未检测到兵营训练");
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
Logger.info("确认训练");
|
|
|
|
|
macro.mouseLeftClick(macro.of(396, 885));
|
|
|
|
|
macro.mouseLeftClick(兵营_训练);
|
|
|
|
|
macro.delay(1000);
|
|
|
|
|
|
|
|
|
|
ViewRect 兵营_返回 = macro.matchLegend("兵营_返回", 0.9D);
|
|
|
|
@ -293,12 +327,29 @@ public class Task_自动练兵 extends BaseTask {
|
|
|
|
|
macro.mouseLeftClick(viewRects2[1]);
|
|
|
|
|
macro.delay(1000);
|
|
|
|
|
|
|
|
|
|
Logger.info("点击兵营");
|
|
|
|
|
macro.mouseLeftClick(macro.of(268, 431));
|
|
|
|
|
macro.delay(1000);
|
|
|
|
|
|
|
|
|
|
Logger.info("点击训练");
|
|
|
|
|
macro.mouseLeftClick(macro.of(355, 632));
|
|
|
|
|
macro.delay(1000);
|
|
|
|
|
|
|
|
|
|
Logger.info("检测任意位置继续");
|
|
|
|
|
ViewRect 兵营_任意位置继续 = macro.waitAndMatchLegend("兵营_任意位置继续", 0.9, 2);
|
|
|
|
|
if (兵营_任意位置继续 != null) {
|
|
|
|
|
Logger.info("点击继续");
|
|
|
|
|
macro.mouseLeftClick(兵营_任意位置继续);
|
|
|
|
|
macro.delay(1500);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
ViewRect 兵营_训练 = macro.waitAndMatchLegend("兵营_训练", 0.9, 2);
|
|
|
|
|
if (兵营_训练 == null) {
|
|
|
|
|
Logger.error("训练失败,未检测到兵营训练");
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
Logger.info("确认训练");
|
|
|
|
|
macro.mouseLeftClick(macro.of(396, 885));
|
|
|
|
|
macro.mouseLeftClick(兵营_训练);
|
|
|
|
|
macro.delay(1000);
|
|
|
|
|
|
|
|
|
|
ViewRect 兵营_返回 = macro.matchLegend("兵营_返回", 0.9D);
|
|
|
|
|