Move Lexicon*, Text (TextTokens, TextEscapes, Base64), Math/RadialGrid, Hash (MD5, XxHash32) and Cipher (Rijndael, XorBytes) into Source/Utility subfolders; update includes, guards, compile.json and CMakeLists.txt. Backfill // OFFSET: above every standalone // FUNCTION: block (89 IDs, addresses from the symbol database) and make it mandatory in CODING_RULES.md and AGENTS.md. Remove the MatchLexicon cast chain.
17 lines
595 B
C++
17 lines
595 B
C++
#include "Utility/Text/TextEscapes.h"
|
|
|
|
// OFFSET: 0x00AF41D0
|
|
// FUNCTION: fn_18244
|
|
void DecodeTextEscapes(std::string& text) {
|
|
for (std::size_t position = text.find("\\r"); position != std::string::npos; position = text.find("\\r")) {
|
|
text.replace(position, 2, "\r", 1);
|
|
}
|
|
|
|
for (std::size_t position = text.find("\\n"); position != std::string::npos; position = text.find("\\n")) {
|
|
text.replace(position, 2, "\n", 1);
|
|
}
|
|
|
|
for (std::size_t position = text.find("\\\""); position != std::string::npos; position = text.find("\\\"")) {
|
|
text.replace(position, 2, "\"", 1);
|
|
}
|
|
}
|