diff --git a/src/MaaCore/Task/Miscellaneous/BattleProcessTask.cpp b/src/MaaCore/Task/Miscellaneous/BattleProcessTask.cpp index dc588b4958..9562c5aeaa 100644 --- a/src/MaaCore/Task/Miscellaneous/BattleProcessTask.cpp +++ b/src/MaaCore/Task/Miscellaneous/BattleProcessTask.cpp @@ -183,7 +183,7 @@ void asst::BattleProcessTask::notify_action(const battle::copilot::Action& actio { ActionType::BulletTime, "BulletTime" }, { ActionType::Output, "Output" }, }; - json::value info = basic_info_with_what("Action"); + json::value info = basic_info_with_what("CopilotAction"); info["details"] |= json::object { { "action", ActionNames.at(action.type) }, { "target", action.group_name }, @@ -324,9 +324,10 @@ void asst::BattleProcessTask::sleep_with_use_ready_skill(unsigned millisecond) LogTraceScope(__FUNCTION__ + std::to_string(millisecond)); using namespace std::chrono_literals; - auto start = std::chrono::steady_clock::now(); + const auto start = std::chrono::steady_clock::now(); + const auto delay = millisecond * 1ms; - while (!need_exit() && std::chrono::steady_clock::now() - start < millisecond * 1ms) { + while (!need_exit() && std::chrono::steady_clock::now() - start < delay) { use_all_ready_skill(); std::this_thread::yield(); } diff --git a/src/MaaWpfGui/Main/AsstProxy.cs b/src/MaaWpfGui/Main/AsstProxy.cs index 75f33cd89c..584f6dcb73 100644 --- a/src/MaaWpfGui/Main/AsstProxy.cs +++ b/src/MaaWpfGui/Main/AsstProxy.cs @@ -943,7 +943,7 @@ namespace MaaWpfGui copilotModel.AddLog(Localization.GetString("BattleFormationSelected") + subTaskDetails["selected"]); break; - case "BattleAction": + case "CopilotAction": { string doc = subTaskDetails["doc"].ToString(); if (doc.Length != 0) @@ -952,24 +952,14 @@ namespace MaaWpfGui copilotModel.AddLog(doc, color.Length == 0 ? UILogColor.Message : color); } - var action = subTaskDetails["action"].ToString(); - if (action.Length != 0) - { - copilotModel.AddLog(Localization.GetString("CurrentSteps") + action); - } + copilotModel.AddLog( + string.Format(Localization.GetString("CurrentSteps"), + subTaskDetails["action"].ToString(), + subTaskDetails["target"].ToString())); } break; - case "BattleActionDoc": - // { - // string title_color = subTaskDetails["title_color"].ToString(); - // copilotModel.AddLog(subTaskDetails["title"].ToString(), title_color.Length == 0 ? LogColor.Message : title_color); - // string details_color = subTaskDetails["details_color"].ToString(); - // copilotModel.AddLog(subTaskDetails["details"].ToString(), details_color.Length == 0 ? LogColor.Message : details_color); - // } - break; - case "UnsupportedLevel": copilotModel.AddLog(Localization.GetString("UnsupportedLevel"), UILogColor.Error); break; diff --git a/src/MaaWpfGui/Res/Localizations/en-us.xaml b/src/MaaWpfGui/Res/Localizations/en-us.xaml index c984f8ca42..2ef27fb2f2 100644 --- a/src/MaaWpfGui/Res/Localizations/en-us.xaml +++ b/src/MaaWpfGui/Res/Localizations/en-us.xaml @@ -451,7 +451,7 @@ Stage recognition error Start formation Selection of operator: - Current step: + Current step: {0} {1} Unsupported levels, please update the MAA, or check input file Identify results: Connection Failed diff --git a/src/MaaWpfGui/Res/Localizations/ja-jp.xaml b/src/MaaWpfGui/Res/Localizations/ja-jp.xaml index 5a9cc10dce..eb8f0c33cb 100644 --- a/src/MaaWpfGui/Res/Localizations/ja-jp.xaml +++ b/src/MaaWpfGui/Res/Localizations/ja-jp.xaml @@ -418,7 +418,7 @@ ステージ認識エラー 編成開始 オペレーターを選択: - 現在の手順: + 現在の手順:{0} {1} このステージはサポートされていません。MAAのバージョンをアップデートするか、攻略ファイルを確認してください 認識結果: 接続失敗 diff --git a/src/MaaWpfGui/Res/Localizations/ko-kr.xaml b/src/MaaWpfGui/Res/Localizations/ko-kr.xaml index 424a2ec3c0..7aede83571 100644 --- a/src/MaaWpfGui/Res/Localizations/ko-kr.xaml +++ b/src/MaaWpfGui/Res/Localizations/ko-kr.xaml @@ -450,7 +450,7 @@ 스테이지 인식 오류 편성 시작 오퍼레이터를 선택: - 현재 단계: + 현재 단계: {0} {1} 지원하지 않는 스테이지입니다. MAA를 업데이트하거나, 작업 파일을 확인하십시오. 인식 결과: 연결 실패 diff --git a/src/MaaWpfGui/Res/Localizations/zh-cn.xaml b/src/MaaWpfGui/Res/Localizations/zh-cn.xaml index 6b5faa7e41..993c58af39 100644 --- a/src/MaaWpfGui/Res/Localizations/zh-cn.xaml +++ b/src/MaaWpfGui/Res/Localizations/zh-cn.xaml @@ -451,7 +451,7 @@ 关卡识别错误 开始编队 选择干员: - 当前步骤: + 当前步骤:{0} {1} 不支持的关卡,请更新 MAA 软件版本,或检查作业文件 识别结果: 连接失败 diff --git a/src/MaaWpfGui/Res/Localizations/zh-tw.xaml b/src/MaaWpfGui/Res/Localizations/zh-tw.xaml index d777261905..13ae3a3de2 100644 --- a/src/MaaWpfGui/Res/Localizations/zh-tw.xaml +++ b/src/MaaWpfGui/Res/Localizations/zh-tw.xaml @@ -403,7 +403,7 @@ 關卡辨識錯誤 開始編隊 選擇幹員: - 當前步驟: + 當前步驟:{0} {1} 不支持的關卡,請更新 MAA 軟體版本,或檢查作業檔案 辨識結果: 連接失敗