serverside generation of itemlist
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@3989 e016b1c5-ed68-44aa-a2f7-31cac88cffde
This commit is contained in:
@@ -146,6 +146,19 @@ void filterrichtext(char *dst, const char *src, int len)
|
||||
*dst = '\0';
|
||||
}
|
||||
|
||||
void filterservdesc(char *dst, const char *src, int len)
|
||||
{ // only colors and spaces allowed
|
||||
for(int c = *src; c; c = *++src)
|
||||
{
|
||||
c &= 0x7F; // 7-bit ascii
|
||||
if((!isspace(c) && isprint(c)) || c == ' ' || c == '\f')
|
||||
{
|
||||
*dst++ = c;
|
||||
if(!--len) break;
|
||||
}
|
||||
}
|
||||
*dst = '\0';
|
||||
}
|
||||
|
||||
const char *modefullnames[] =
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user