Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ MatchLongestWords()

int System.__DTString.MatchLongestWords ( string[] words,
ref int maxMatchStrLen )
inlinepackage

Definition at line 279 of file __DTString.cs.

280 {
281 int result = -1;
282 for (int i = 0; i < words.Length; i++)
283 {
284 string text = words[i];
285 int matchLength = text.Length;
286 if (MatchSpecifiedWords(text, checkWordBoundary: false, ref matchLength) && matchLength > maxMatchStrLen)
287 {
288 maxMatchStrLen = matchLength;
289 result = i;
290 }
291 }
292 return result;
293 }
bool MatchSpecifiedWords(string target, bool checkWordBoundary, ref int matchLength)

References System.__DTString.MatchSpecifiedWords(), and System.text.