Client - Titles: add new function Titles_GetTextBody() to grab the body portion of a titles.txt entry
This commit is contained in:
parent
ed2d73106f
commit
7f55f1c868
1 changed files with 19 additions and 0 deletions
|
@ -82,6 +82,25 @@ Titles_Shutdown(void)
|
|||
g_titles_count = 0;
|
||||
}
|
||||
|
||||
string
|
||||
Titles_GetTextBody(string shortName)
|
||||
{
|
||||
int foundID = -1i;
|
||||
string compare = strtoupper(shortName);
|
||||
|
||||
for (int i = 0; i < g_titles_count; i++) {
|
||||
if (g_titles[i].m_strName == compare) {
|
||||
foundID = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (foundID >= 0)
|
||||
return g_titles[foundID].m_strMessage;
|
||||
|
||||
return compare;
|
||||
}
|
||||
|
||||
void
|
||||
Titles_Init(void)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue