diff options
author | M. Kristall <mkpdev@gmail.com> | 2012-07-16 01:38:21 +0000 |
---|---|---|
committer | Tim Angus <tim@ngus.net> | 2013-01-03 00:26:21 +0000 |
commit | c21fc9efb4694f66366645487a2add25abdf3590 (patch) | |
tree | 1fbee40f767a1bbd3f6a6426fb4b98473f583746 /src/cgame/cg_main.c | |
parent | c78e04f4c834d88dbada2e961e65b43c7bfbf424 (diff) |
* Simplify some weapon-related code (re r1431)
Diffstat (limited to 'src/cgame/cg_main.c')
-rw-r--r-- | src/cgame/cg_main.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/cgame/cg_main.c b/src/cgame/cg_main.c index fd2d258f..8680aeca 100644 --- a/src/cgame/cg_main.c +++ b/src/cgame/cg_main.c @@ -400,12 +400,9 @@ static void CG_SetUIVars( void ) *carriageCvar = 0; //determine what the player is carrying - for( i = WP_NONE + 1; i < WP_NUM_WEAPONS; i++ ) - { - if( BG_InventoryContainsWeapon( i, cg.snap->ps.stats ) && - BG_Weapon( i )->purchasable ) - strcat( carriageCvar, va( "W%d ", i ) ); - } + if( BG_Weapon( cg.snap->ps.stats[ STAT_WEAPON ] )->purchasable ) + strcat( carriageCvar, va( "W%d ", cg.snap->ps.stats[ STAT_WEAPON ] ) ); + for( i = UP_NONE + 1; i < UP_NUM_UPGRADES; i++ ) { if( BG_InventoryContainsUpgrade( i, cg.snap->ps.stats ) && |