Fixed opening trade window while using DBM or Questie addon (#1363)

* - Fixed opening trade window while using DBM or Questie addon

* - Added excluded prefixes for trade actions to config

* -Fixed config description
This commit is contained in:
kadeshar
2025-06-08 16:23:51 +02:00
committed by GitHub
parent d15ec79252
commit dfa87faf5e
4 changed files with 9 additions and 2 deletions

View File

@@ -10,13 +10,14 @@
#include "ItemCountValue.h"
#include "ItemVisitors.h"
#include "Playerbots.h"
#include <PlayerbotAIConfig.cpp>
bool TradeAction::Execute(Event event)
{
std::string const text = event.getParam();
// Table with prefixes to be excluded from analysis
static const std::vector<std::string> excludedPrefixes = {"RPLL_H_"};
std::vector<std::string> excludedPrefixes;
LoadListString<std::vector<std::string>>(sPlayerbotAIConfig->tradeActionExcludedPrefixes, excludedPrefixes);
// If text starts with any excluded prefix, don't process it further.
for (const auto& prefix : excludedPrefixes)