mirror of
https://github.com/MaaAssistantArknights/MaaAssistantArknights.git
synced 2026-07-20 02:55:38 +08:00
Merge branch 'dev'
This commit is contained in:
@@ -1995,7 +1995,8 @@
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
"坚毅随和"
|
||||
"坚毅随和",
|
||||
"浮生得闲"
|
||||
],
|
||||
"desc": "进驻控制中枢时,控制中枢内每个鲤氏侦探所干员可使该派系干员额外恢复心情(心情每小时恢复+0.15),同时每人可使控制中枢内所有干员的心情每小时恢复+0.05",
|
||||
"template": "Bskill_ctrl_lda.png",
|
||||
@@ -2003,6 +2004,36 @@
|
||||
"all": 0.05
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
"世事洞明"
|
||||
],
|
||||
"desc": "进驻控制中枢时,会客室线索搜集速度+25%",
|
||||
"template": "Bskill_ctrl_c_spd.png",
|
||||
"efficient": {
|
||||
"all": 0.01
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
"杯莫停"
|
||||
],
|
||||
"desc": "进驻控制中枢时,消除当前控制中枢内所有岁干员自身心情消耗的影响",
|
||||
"template": "Bskill_ctrl_clear_sui.png",
|
||||
"efficient": {
|
||||
"all": 0.01
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
"“山河远阔”"
|
||||
],
|
||||
"desc": "\t进驻控制中枢时,当自身心情大于12时,人间烟火+15;当自身心情处于12以下时,感知信息+10",
|
||||
"template": "Bskill_ctrl_cost_bd1&bd2.png",
|
||||
"efficient": {
|
||||
"all": 0.01
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
"感染力"
|
||||
|
||||
@@ -3129,9 +3129,8 @@
|
||||
},
|
||||
"BattleStageName": {
|
||||
"algorithm": "OcrDetect",
|
||||
"text": [
|
||||
|
||||
],
|
||||
"cache": false,
|
||||
"text": [ ],
|
||||
"ocrReplace": [
|
||||
[
|
||||
".+兽小屋",
|
||||
@@ -3147,10 +3146,10 @@
|
||||
]
|
||||
],
|
||||
"roi": [
|
||||
255,
|
||||
263,
|
||||
785,
|
||||
328
|
||||
500,
|
||||
430,
|
||||
280,
|
||||
100
|
||||
]
|
||||
},
|
||||
"BattleUseOper": {
|
||||
@@ -3454,7 +3453,7 @@
|
||||
],
|
||||
"templThreshold": 0.95,
|
||||
"preDelay": 3000,
|
||||
"rearDelay": 5000
|
||||
"rearDelay": 3000
|
||||
},
|
||||
"BattleSkillReady": {
|
||||
"roi": [
|
||||
@@ -3490,7 +3489,6 @@
|
||||
"algorithm": "justReturn",
|
||||
"next": [
|
||||
"Roguelike1Start",
|
||||
"Roguelike1DropsFlag",
|
||||
"Roguelike1ExitThenAbandon",
|
||||
"Roguelike1Abandon"
|
||||
]
|
||||
@@ -3817,6 +3815,7 @@
|
||||
226,
|
||||
220
|
||||
],
|
||||
"rearDelay": 3000,
|
||||
"next": [
|
||||
"Roguelike1StageTraderInvestSystem",
|
||||
"Roguelike1StageTraderLeave"
|
||||
@@ -4102,8 +4101,12 @@
|
||||
],
|
||||
"rearDelay": 1000,
|
||||
"next": [
|
||||
"Roguelike1ChooseOper",
|
||||
"Roguelike1StageEncounterFree",
|
||||
"Roguelike1StageEncounterLeave",
|
||||
"Roguelike1StageEncounterUnknown",
|
||||
"Roguelike1StageEncounterGiveUpRecruit",
|
||||
"Roguelike1StageCambatDpsEnter",
|
||||
"Roguelike1StageEmergencyDpsEnter",
|
||||
"Roguelike1ClickToDrops"
|
||||
]
|
||||
},
|
||||
@@ -4327,6 +4330,7 @@
|
||||
"Roguelike1StageBoons",
|
||||
"Roguelike1StageCambatDps",
|
||||
"Roguelike1StageEmergencyDps",
|
||||
"Roguelike1StageEncounterGiveUpRecruit",
|
||||
"Roguelike1ClickToDrops"
|
||||
]
|
||||
},
|
||||
@@ -4349,7 +4353,11 @@
|
||||
"Roguelike1StageEncounter",
|
||||
"Roguelike1StageBoons",
|
||||
"Roguelike1StageCambatDps",
|
||||
"Roguelike1StageEmergencyDps"
|
||||
"Roguelike1StageEmergencyDps",
|
||||
"Roguelike1StageEncounterFree",
|
||||
"Roguelike1StageEncounterLeave",
|
||||
"Roguelike1StageEncounterUnknown",
|
||||
"Roguelike1StageEncounterGiveUpRecruit"
|
||||
]
|
||||
},
|
||||
"Roguelike1GetDrop1": {
|
||||
@@ -4437,7 +4445,7 @@
|
||||
],
|
||||
"next": [
|
||||
"Roguelike1GetDropLeaveConfirm",
|
||||
"Roguelike1Begin"
|
||||
"Roguelike1DropsFlag"
|
||||
]
|
||||
},
|
||||
"Roguelike1GetDropLeaveConfirm": {
|
||||
@@ -4450,7 +4458,7 @@
|
||||
138
|
||||
],
|
||||
"next": [
|
||||
"Roguelike1Begin"
|
||||
"Roguelike1DropsFlag"
|
||||
]
|
||||
},
|
||||
"Roguelike1MissionFailedFlag": {
|
||||
|
||||
BIN
resource/template/Bskill_ctrl_c_spd.png
Normal file
BIN
resource/template/Bskill_ctrl_c_spd.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.3 KiB |
BIN
resource/template/Bskill_ctrl_clear_sui.png
Normal file
BIN
resource/template/Bskill_ctrl_clear_sui.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.9 KiB |
BIN
resource/template/Bskill_ctrl_cost_bd1&bd2.png
Normal file
BIN
resource/template/Bskill_ctrl_cost_bd1&bd2.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.9 KiB |
@@ -151,7 +151,7 @@ bool asst::InfrastAbstractTask::click_confirm_button()
|
||||
{
|
||||
LogTraceFunction;
|
||||
|
||||
ProcessTask task(*this, { "InfrastConfirmButton" });
|
||||
ProcessTask task(*this, { "InfrastDormConfirmButton" });
|
||||
return task.run();
|
||||
}
|
||||
|
||||
|
||||
@@ -95,10 +95,10 @@ bool asst::InfrastDormTask::opers_choose()
|
||||
return true;
|
||||
}
|
||||
|
||||
bool asst::InfrastDormTask::click_confirm_button()
|
||||
{
|
||||
LogTraceFunction;
|
||||
|
||||
ProcessTask task(*this, { "InfrastDormConfirmButton" });
|
||||
return task.run();
|
||||
}
|
||||
//bool asst::InfrastDormTask::click_confirm_button()
|
||||
//{
|
||||
// LogTraceFunction;
|
||||
//
|
||||
// ProcessTask task(*this, { "InfrastDormConfirmButton" });
|
||||
// return task.run();
|
||||
//}
|
||||
|
||||
@@ -13,7 +13,7 @@ namespace asst
|
||||
|
||||
private:
|
||||
virtual bool _run() override;
|
||||
virtual bool click_confirm_button() override;
|
||||
//virtual bool click_confirm_button() override;
|
||||
|
||||
bool opers_choose();
|
||||
|
||||
|
||||
@@ -9,14 +9,14 @@ bool asst::InfrastPowerTask::_run()
|
||||
// 发电站只能造这一个
|
||||
set_product("Drone");
|
||||
|
||||
for (int i = 0; i != max_num_of_facilities(); ++i) {
|
||||
for (; m_cur_facility_index != max_num_of_facilities(); ++m_cur_facility_index) {
|
||||
if (need_exit()) {
|
||||
return false;
|
||||
}
|
||||
swipe_to_the_left_of_main_ui();
|
||||
|
||||
// 进不去说明设施数量不够
|
||||
if (!enter_facility(i)) {
|
||||
if (!enter_facility(m_cur_facility_index)) {
|
||||
break;
|
||||
}
|
||||
if (!enter_oper_list_page()) {
|
||||
|
||||
@@ -45,18 +45,15 @@ bool asst::InfrastProductionTask::shift_facility_list()
|
||||
MultiMatchImageAnalyzer locked_analyzer;
|
||||
locked_analyzer.set_task_info("InfrastOperLocked" + facility_name());
|
||||
|
||||
int index = 0;
|
||||
for (const Rect& tab : m_facility_list_tabs) {
|
||||
m_cur_facility_index = index;
|
||||
for (; m_cur_facility_index < m_facility_list_tabs.size(); ++m_cur_facility_index) {
|
||||
Rect tab = m_facility_list_tabs.at(m_cur_facility_index);
|
||||
if (need_exit()) {
|
||||
return false;
|
||||
}
|
||||
if (index != 0) {
|
||||
if (m_cur_facility_index != 0) {
|
||||
callback(AsstMsg::SubTaskExtraInfo, basic_info_with_what("EnterFacility"));
|
||||
}
|
||||
|
||||
++index;
|
||||
|
||||
Ctrler.click(tab);
|
||||
sleep(tab_task_ptr->rear_delay);
|
||||
|
||||
@@ -625,4 +622,4 @@ bool asst::InfrastProductionTask::facility_list_detect()
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -28,14 +28,16 @@ bool asst::RoguelikeBattleTaskPlugin::_run()
|
||||
{
|
||||
clear();
|
||||
|
||||
get_stage_info();
|
||||
bool getted_info = get_stage_info();
|
||||
|
||||
speed_up();
|
||||
|
||||
while (!need_exit()) {
|
||||
// 不在战斗场景,且已使用过了干员,说明已经打完了,就结束循环
|
||||
if (!auto_battle() && m_used_opers) {
|
||||
break;
|
||||
if (getted_info) {
|
||||
while (!need_exit()) {
|
||||
// 不在战斗场景,且已使用过了干员,说明已经打完了,就结束循环
|
||||
if (!auto_battle() && m_used_opers) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -46,12 +48,19 @@ bool asst::RoguelikeBattleTaskPlugin::get_stage_info()
|
||||
{
|
||||
LogTraceFunction;
|
||||
|
||||
const auto stage_name_task_ptr = Task.get("BattleStageName");
|
||||
sleep(stage_name_task_ptr->pre_delay);
|
||||
|
||||
const auto& tile = Resrc.tile();
|
||||
bool calced = false;
|
||||
for (int i = 0; i != m_retry_times; ++i) {
|
||||
OcrImageAnalyzer name_analyzer(Ctrler.get_image());
|
||||
name_analyzer.set_task_info("BattleStageName");
|
||||
name_analyzer.analyze();
|
||||
constexpr int StageNameRetryTimes = 50;
|
||||
for (int i = 0; i != StageNameRetryTimes; ++i) {
|
||||
cv::Mat image = Ctrler.get_image();
|
||||
OcrImageAnalyzer name_analyzer(image);
|
||||
name_analyzer.set_task_info(stage_name_task_ptr);
|
||||
if (!name_analyzer.analyze()) {
|
||||
continue;
|
||||
}
|
||||
|
||||
for (const auto& tr : name_analyzer.get_result()) {
|
||||
auto side_info = tile.calc(tr.text, true);
|
||||
@@ -60,13 +69,20 @@ bool asst::RoguelikeBattleTaskPlugin::get_stage_info()
|
||||
}
|
||||
m_side_tile_info = std::move(side_info);
|
||||
calced = true;
|
||||
Log.info("stage info getted, tiles_size", m_side_tile_info.size());
|
||||
auto cb_info = basic_info_with_what("StageInfo");
|
||||
auto& details = cb_info["details"];
|
||||
details["name"] = tr.text;
|
||||
details["size"] = m_side_tile_info.size();
|
||||
callback(AsstMsg::SubTaskExtraInfo, cb_info);
|
||||
break;
|
||||
}
|
||||
if (calced) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (!calced) {
|
||||
callback(AsstMsg::SubTaskExtraInfo, basic_info_with_what("StageInfoError"));
|
||||
}
|
||||
|
||||
return calced;
|
||||
}
|
||||
|
||||
@@ -2,5 +2,5 @@
|
||||
|
||||
namespace asst
|
||||
{
|
||||
constexpr static const char* Version = "v2.9.1";
|
||||
constexpr static const char* Version = "v2.9.3";
|
||||
}
|
||||
|
||||
@@ -294,9 +294,9 @@ namespace MeoAsstGui
|
||||
mainModel.AddLog("已放弃本次探索");
|
||||
break;
|
||||
|
||||
case "Roguelike1StartAction":
|
||||
mainModel.AddLog("开始战斗");
|
||||
break;
|
||||
//case "Roguelike1StartAction":
|
||||
// mainModel.AddLog("开始战斗");
|
||||
// break;
|
||||
|
||||
case "Roguelike1MissionCompletedFlag":
|
||||
mainModel.AddLog("战斗完成");
|
||||
@@ -444,6 +444,19 @@ namespace MeoAsstGui
|
||||
mainModel.AddLog("可用干员不足", "darkred");
|
||||
}
|
||||
break;
|
||||
|
||||
/* Roguelike */
|
||||
case "StageInfo":
|
||||
{
|
||||
mainModel.AddLog("开始战斗:" + subTaskDetails["name"]);
|
||||
}
|
||||
break;
|
||||
|
||||
case "StageInfoError":
|
||||
{
|
||||
mainModel.AddLog("关卡识别错误", "darkred");
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user