From 093702a70425c29082558ae2e65e3c88733e7131 Mon Sep 17 00:00:00 2001 From: Nimetu Date: Thu, 2 Sep 2021 23:56:12 +0300 Subject: [PATCH] Fix web link in item customtext being visible --- .../src/interface_v3/action_handler_help.cpp | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/ryzom/client/src/interface_v3/action_handler_help.cpp b/ryzom/client/src/interface_v3/action_handler_help.cpp index 3c5f47df6..4417966bb 100644 --- a/ryzom/client/src/interface_v3/action_handler_help.cpp +++ b/ryzom/client/src/interface_v3/action_handler_help.cpp @@ -1907,9 +1907,17 @@ void getItemText (CDBCtrlSheet *item, string &itemText, const CItemSheet*pIS) const CClientItemInfo &itemInfo = getInventory().getItemInfo(getInventory().getItemSlotId(item) ); if (!itemInfo.CustomText.empty()) { - strFindReplace(itemText, "%custom_text", "\n@{FFFF}" + itemInfo.CustomText.toUtf8() + "\n"); - string itemMFC = CI18N::get("uiItemTextMessageFromCrafter"); - strFindReplace(itemText, "%mfc", itemMFC); + std::string text = itemInfo.CustomText.toUtf8(); + if (text.size() > 3 && text[0]=='@' && ((text[1]=='W' && text[2]=='E' && text[3]=='B') || (text[1]=='L' && text[2]=='U' && text[3]=='A'))) + { + strFindReplace(itemText, "%custom_text", string() ); + } + else + { + strFindReplace(itemText, "%custom_text", "\n@{FFFF}" + itemInfo.CustomText.toUtf8() + "\n"); + string itemMFC = CI18N::get("uiItemTextMessageFromCrafter"); + strFindReplace(itemText, "%mfc", itemMFC); + } } else strFindReplace(itemText, "%custom_text", string() );