From dc8b48855d20d2d3d175e37d58a9aff4b47e0c46 Mon Sep 17 00:00:00 2001 From: Zack Middleton Date: Fri, 17 Aug 2012 19:05:40 +0000 Subject: [PATCH] More MISSIONPACK ifdeffery. --- code/cgame/cg_event.c | 2 ++ code/cgame/cg_local.h | 17 +++++++++++++---- code/cgame/cg_main.c | 6 +----- 3 files changed, 16 insertions(+), 9 deletions(-) diff --git a/code/cgame/cg_event.c b/code/cgame/cg_event.c index a8568705..275eceb0 100644 --- a/code/cgame/cg_event.c +++ b/code/cgame/cg_event.c @@ -1107,6 +1107,7 @@ void CG_EntityEvent( centity_t *cent, vec3_t position ) { } } break; +#ifdef MISSIONPACK case GTS_REDOBELISK_ATTACKED: // Overload: red obelisk is being attacked if (cgs.clientinfo[cg.clientNum].team == TEAM_RED) { CG_AddBufferedSound( cgs.media.yourBaseIsUnderAttackSound ); @@ -1117,6 +1118,7 @@ void CG_EntityEvent( centity_t *cent, vec3_t position ) { CG_AddBufferedSound( cgs.media.yourBaseIsUnderAttackSound ); } break; +#endif case GTS_REDTEAM_SCORED: CG_AddBufferedSound(cgs.media.redScoredSound); diff --git a/code/cgame/cg_local.h b/code/cgame/cg_local.h index 3ea10daf..dabb0f67 100644 --- a/code/cgame/cg_local.h +++ b/code/cgame/cg_local.h @@ -769,8 +769,10 @@ typedef struct { qhandle_t battleSuitShader; qhandle_t battleWeaponShader; qhandle_t hastePuffShader; +#ifdef MISSIONPACK qhandle_t redKamikazeShader; qhandle_t blueKamikazeShader; +#endif // weapon effect models qhandle_t bulletFlashModel; @@ -804,8 +806,8 @@ typedef struct { qhandle_t medkitUsageModel; qhandle_t dustPuffShader; qhandle_t heartShader; -#endif qhandle_t invulnerabilityPowerupModel; +#endif // scoreboard headers qhandle_t scoreboardName; @@ -910,7 +912,9 @@ typedef struct { sfxHandle_t flightSound; sfxHandle_t medkitSound; +#ifdef MISSIONPACK sfxHandle_t weaponHoverSound; +#endif // teamplay sounds sfxHandle_t captureAwardSound; @@ -929,13 +933,17 @@ typedef struct { sfxHandle_t redFlagReturnedSound; sfxHandle_t blueFlagReturnedSound; +#ifdef MISSIONPACK sfxHandle_t neutralFlagReturnedSound; +#endif sfxHandle_t enemyTookYourFlagSound; - sfxHandle_t enemyTookTheFlagSound; sfxHandle_t yourTeamTookEnemyFlagSound; - sfxHandle_t yourTeamTookTheFlagSound; sfxHandle_t youHaveFlagSound; +#ifdef MISSIONPACK + sfxHandle_t enemyTookTheFlagSound; + sfxHandle_t yourTeamTookTheFlagSound; sfxHandle_t yourBaseIsUnderAttackSound; +#endif sfxHandle_t holyShitSound; // tournament sounds @@ -962,10 +970,11 @@ typedef struct { sfxHandle_t doublerSound; sfxHandle_t guardSound; sfxHandle_t scoutSound; -#endif + qhandle_t cursor; qhandle_t selectCursor; qhandle_t sizeCursor; +#endif sfxHandle_t regenSound; sfxHandle_t protectSound; diff --git a/code/cgame/cg_main.c b/code/cgame/cg_main.c index 15b32ad3..3b1f77b7 100644 --- a/code/cgame/cg_main.c +++ b/code/cgame/cg_main.c @@ -604,9 +604,6 @@ static void CG_RegisterSounds( void ) { #else cgs.media.youHaveFlagSound = trap_S_RegisterSound( "sound/teamplay/voc_you_flag.wav", qtrue ); cgs.media.holyShitSound = trap_S_RegisterSound("sound/feedback/voc_holyshit.wav", qtrue); - cgs.media.neutralFlagReturnedSound = trap_S_RegisterSound( "sound/teamplay/flagreturn_opponent.wav", qtrue ); - cgs.media.yourTeamTookTheFlagSound = trap_S_RegisterSound( "sound/teamplay/voc_team_1flag.wav", qtrue ); - cgs.media.enemyTookTheFlagSound = trap_S_RegisterSound( "sound/teamplay/voc_enemy_1flag.wav", qtrue ); #endif } @@ -996,10 +993,9 @@ static void CG_RegisterGraphics( void ) { cgs.media.invulnerabilityJuicedModel = trap_R_RegisterModel( "models/powerups/shield/juicer.md3" ); cgs.media.medkitUsageModel = trap_R_RegisterModel( "models/powerups/regen.md3" ); cgs.media.heartShader = trap_R_RegisterShaderNoMip( "ui/assets/statusbar/selectedhealth.tga" ); - + cgs.media.invulnerabilityPowerupModel = trap_R_RegisterModel( "models/powerups/shield/shield.md3" ); #endif - cgs.media.invulnerabilityPowerupModel = trap_R_RegisterModel( "models/powerups/shield/shield.md3" ); cgs.media.medalImpressive = trap_R_RegisterShaderNoMip( "medal_impressive" ); cgs.media.medalExcellent = trap_R_RegisterShaderNoMip( "medal_excellent" ); cgs.media.medalGauntlet = trap_R_RegisterShaderNoMip( "medal_gauntlet" );