Index: src/game/g_admin.c =================================================================== --- src/game/g_admin.c (revision 959) +++ src/game/g_admin.c (working copy) @@ -282,6 +282,7 @@ gclient_t *client; char testName[ MAX_NAME_LENGTH ] = {""}; char name2[ MAX_NAME_LENGTH ] = {""}; + int alphaCount = 0; G_SanitiseName( name, name2 ); @@ -309,6 +310,32 @@ return qfalse; } } + + if( '0' < name2[ 0 ] && name2[ 0 ] < '9' ) + { + Q_strncpyz( err, "Names cannot begin with a number. Please choose another.", len ); + return qfalse; + } + + for( i = 0; name2[ i ] !='\0'; i++) + { + if( Q_isalpha( name2[ i ] ) ) + alphaCount++; + if( name2[ i ] == '/' ) + { + if( name2[ i + 1 ] == '/' || name2[ i + 1 ] == '*' ) + { + Q_strncpyz( err, "Names cannot contain '//' or '/*'. Please choose another.", len ); + return qfalse; + } + } + } + + if( alphaCount == 0 ) + { + Q_strncpyz( err, va( "The name '%s^7' does not include at least one letter. Please choose another.", name ), len ); + return qfalse; + } if( !g_adminNameProtect.string[ 0 ] ) return qtrue; @@ -321,8 +348,8 @@ if( !Q_stricmp( name2, testName ) && Q_stricmp( ent->client->pers.guid, g_admin_admins[ i ]->guid ) ) { - Q_strncpyz( err, va( "The name '%s^7' belongs to an admin, " - "please use another name", name ), len ); + Q_strncpyz( err, va( "The name '%s^7' belongs to an admin. " + "Please choose another.", name ), len ); return qfalse; } }