diff options
author | Tim Angus <tim@ngus.net> | 2009-10-09 22:24:05 +0000 |
---|---|---|
committer | Tim Angus <tim@ngus.net> | 2013-01-03 00:16:45 +0000 |
commit | a1f3d889f1eca9b3a670363dd386480ec2b48a76 (patch) | |
tree | 80452d051386e4ca98efed6d2cd6f762416b46e7 /src/game/bg_misc.c | |
parent | d28ad7411a91881d168d45d0846adf80a579a02f (diff) |
* (bug #3836) Add [SV|trap]_SetConfigstringRestrictions which prevents some
clients receiving a config string
* Move BG_ClientList* to Com_ClientList*
* Split CS_STAGES into CS_ALIEN_STAGES and CS_HUMAN_STAGES
Diffstat (limited to 'src/game/bg_misc.c')
-rw-r--r-- | src/game/bg_misc.c | 79 |
1 files changed, 0 insertions, 79 deletions
diff --git a/src/game/bg_misc.c b/src/game/bg_misc.c index 1be45648..f9cdb545 100644 --- a/src/game/bg_misc.c +++ b/src/game/bg_misc.c @@ -3849,85 +3849,6 @@ qboolean BG_BuildableIsAllowed( buildable_t buildable ) /* ============ -BG_ClientListTest -============ -*/ -qboolean BG_ClientListTest( clientList_t *list, int clientNum ) -{ - if( clientNum < 0 || clientNum >= MAX_CLIENTS || !list ) - return qfalse; - if( clientNum < 32 ) - return ( ( list->lo & ( 1 << clientNum ) ) != 0 ); - else - return ( ( list->hi & ( 1 << ( clientNum - 32 ) ) ) != 0 ); -} - -/* -============ -BG_ClientListAdd -============ -*/ -void BG_ClientListAdd( clientList_t *list, int clientNum ) -{ - if( clientNum < 0 || clientNum >= MAX_CLIENTS || !list ) - return; - if( clientNum < 32 ) - list->lo |= ( 1 << clientNum ); - else - list->hi |= ( 1 << ( clientNum - 32 ) ); -} - -/* -============ -BG_ClientListRemove -============ -*/ -void BG_ClientListRemove( clientList_t *list, int clientNum ) -{ - if( clientNum < 0 || clientNum >= MAX_CLIENTS || !list ) - return; - if( clientNum < 32 ) - list->lo &= ~( 1 << clientNum ); - else - list->hi &= ~( 1 << ( clientNum - 32 ) ); -} - -/* -============ -BG_ClientListString -============ -*/ -char *BG_ClientListString( clientList_t *list ) -{ - static char s[ 17 ]; - - s[ 0 ] = '\0'; - if( !list ) - return s; - Com_sprintf( s, sizeof( s ), "%08x%08x", list->hi, list->lo ); - return s; -} - -/* -============ -BG_ClientListParse -============ -*/ -void BG_ClientListParse( clientList_t *list, const char *s ) -{ - if( !list ) - return; - list->lo = 0; - list->hi = 0; - if( !s ) - return; - if( strlen( s ) != 16 ) - return; - sscanf( s, "%x%x", &list->hi, &list->lo ); -} - -/* -============ BG_PrimaryWeapon ============ */ |