diff --git a/source/cli/CustomAction/CustomAction.cpp b/source/cli/CustomAction/CustomAction.cpp index bce04f2..ca27ac3 100644 --- a/source/cli/CustomAction/CustomAction.cpp +++ b/source/cli/CustomAction/CustomAction.cpp @@ -4,9 +4,9 @@ CustomAction::CustomAction(const std::string& action_name, MaaBool (*action_run)(MaaSyncContextHandle sync_context, MaaStringView task_name, MaaStringView custom_action_param, MaaRectHandle cur_box, MaaStringView cur_rec_detail, MaaTransparentArg arg)) - : name_(action_name) + : _name(action_name) { - custom_action_.run = action_run; + _custom_action.run = action_run; } CustomAction::CustomAction(const std::string& action_name, @@ -14,18 +14,18 @@ CustomAction::CustomAction(const std::string& action_name, MaaStringView custom_action_param, MaaRectHandle cur_box, MaaStringView cur_rec_detail, MaaTransparentArg arg), void (*action_stop)(MaaTransparentArg arg)) - : name_(action_name) + : _name(action_name) { - custom_action_.run = action_run; - custom_action_.stop = action_stop; + _custom_action.run = action_run; + _custom_action.stop = action_stop; } std::string CustomAction::get_name() const { - return name_; + return _name; } MaaCustomActionAPI CustomAction::get_custom_action() const { - return custom_action_; + return _custom_action; } \ No newline at end of file diff --git a/source/cli/CustomAction/CustomAction.h b/source/cli/CustomAction/CustomAction.h index 6087d23..ff71f96 100644 --- a/source/cli/CustomAction/CustomAction.h +++ b/source/cli/CustomAction/CustomAction.h @@ -23,6 +23,6 @@ class CustomAction MaaCustomActionAPI get_custom_action() const; private: - std::string name_; - MaaCustomActionAPI custom_action_; + std::string _name; + MaaCustomActionAPI _custom_action; }; \ No newline at end of file diff --git a/source/cli/CustomAction/CustomActionRegistrar.cpp b/source/cli/CustomAction/CustomActionRegistrar.cpp index c883308..59f5524 100644 --- a/source/cli/CustomAction/CustomActionRegistrar.cpp +++ b/source/cli/CustomAction/CustomActionRegistrar.cpp @@ -5,7 +5,7 @@ void CustomActionRegistrar::add_action(const std::string& name, MaaStringView custom_action_param, MaaRectHandle cur_box, MaaStringView cur_rec_detail, MaaTransparentArg arg)) { - actions_.emplace_back(name, action_run); + _actions.emplace_back(name, action_run); } void CustomActionRegistrar::add_action(const std::string& name, @@ -14,15 +14,15 @@ void CustomActionRegistrar::add_action(const std::string& name, MaaStringView cur_rec_detail, MaaTransparentArg arg), void (*action_stop)(MaaTransparentArg arg)) { - actions_.emplace_back(name, action_run, action_stop); + _actions.emplace_back(name, action_run, action_stop); } void CustomActionRegistrar::register_actions(MaaInstanceHandle maa_handle) { - for (const auto& action : actions_) { + for (const auto& action : _actions) { std::shared_ptr custom_action = std::make_shared(action.get_custom_action()); - custom_actions_.push_back(custom_action); + _custom_actions.push_back(custom_action); MaaRegisterCustomAction(maa_handle, action.get_name().c_str(), custom_action.get(), nullptr); } } \ No newline at end of file diff --git a/source/cli/CustomAction/CustomActionRegistrar.h b/source/cli/CustomAction/CustomActionRegistrar.h index 31a8a17..4efc599 100644 --- a/source/cli/CustomAction/CustomActionRegistrar.h +++ b/source/cli/CustomAction/CustomActionRegistrar.h @@ -27,6 +27,6 @@ class CustomActionRegistrar void register_actions(MaaInstanceHandle maa_handle); private: - std::vector actions_; - std::vector> custom_actions_; + std::vector _actions; + std::vector> _custom_actions; }; \ No newline at end of file diff --git a/source/cli/CustomRecognizer/CustomRecognizer.cpp b/source/cli/CustomRecognizer/CustomRecognizer.cpp index a2e5756..a504ce2 100644 --- a/source/cli/CustomRecognizer/CustomRecognizer.cpp +++ b/source/cli/CustomRecognizer/CustomRecognizer.cpp @@ -6,17 +6,17 @@ CustomRecognizer::CustomRecognizer( MaaStringView task_name, MaaStringView custom_recognition_param, MaaTransparentArg recognizer_arg, MaaRectHandle out_box, MaaStringBufferHandle detail_buff)) - : name_(recognizer_name) + : _name(recognizer_name) { - custom_recognizer_.analyze = recognizer_analyze; + _custom_recognizer.analyze = recognizer_analyze; } std::string CustomRecognizer::get_name() const { - return name_; + return _name; } MaaCustomRecognizerAPI CustomRecognizer::get_custom_recognizer() const { - return custom_recognizer_; + return _custom_recognizer; } \ No newline at end of file diff --git a/source/cli/CustomRecognizer/CustomRecognizer.h b/source/cli/CustomRecognizer/CustomRecognizer.h index 5c56939..1d58614 100644 --- a/source/cli/CustomRecognizer/CustomRecognizer.h +++ b/source/cli/CustomRecognizer/CustomRecognizer.h @@ -19,6 +19,6 @@ class CustomRecognizer MaaCustomRecognizerAPI get_custom_recognizer() const; private: - std::string name_; - MaaCustomRecognizerAPI custom_recognizer_; + std::string _name; + MaaCustomRecognizerAPI _custom_recognizer; }; \ No newline at end of file diff --git a/source/cli/CustomRecognizer/CustomRecognizerRegistrar.cpp b/source/cli/CustomRecognizer/CustomRecognizerRegistrar.cpp index c1d2099..1526e91 100644 --- a/source/cli/CustomRecognizer/CustomRecognizerRegistrar.cpp +++ b/source/cli/CustomRecognizer/CustomRecognizerRegistrar.cpp @@ -7,15 +7,15 @@ void CustomRecognizerRegistrar::add_recognizer( MaaTransparentArg recognizer_arg, MaaRectHandle out_box, MaaStringBufferHandle detail_buff)) { - recognizers_.emplace_back(name, recognizer_analyze); + _recognizers.emplace_back(name, recognizer_analyze); } void CustomRecognizerRegistrar::register_recognizers(MaaInstanceHandle maa_handle) { - for (const auto& recognizer : recognizers_) { + for (const auto& recognizer : _recognizers) { std::shared_ptr custom_recognizer = std::make_shared(recognizer.get_custom_recognizer()); - custom_recognizers_.push_back(custom_recognizer); + _custom_recognizers.push_back(custom_recognizer); MaaRegisterCustomRecognizer(maa_handle, recognizer.get_name().c_str(), custom_recognizer.get(), nullptr); } } \ No newline at end of file diff --git a/source/cli/CustomRecognizer/CustomRecognizerRegistrar.h b/source/cli/CustomRecognizer/CustomRecognizerRegistrar.h index d06a99c..0f69f1d 100644 --- a/source/cli/CustomRecognizer/CustomRecognizerRegistrar.h +++ b/source/cli/CustomRecognizer/CustomRecognizerRegistrar.h @@ -24,6 +24,6 @@ class CustomRecognizerRegistrar void register_recognizers(MaaInstanceHandle maa_handle); private: - std::vector recognizers_; - std::vector> custom_recognizers_; + std::vector _recognizers; + std::vector> _custom_recognizers; }; \ No newline at end of file