diff --git a/cl_dll/hl/hl_weapons.cpp b/cl_dll/hl/hl_weapons.cpp index 43485100..536392e3 100644 --- a/cl_dll/hl/hl_weapons.cpp +++ b/cl_dll/hl/hl_weapons.cpp @@ -1039,7 +1039,7 @@ void _DLLEXPORT HUD_PostRunCmd( struct local_state_s *from, struct local_state_s { g_runfuncs = runfuncs; -#if defined( CLIENT_WEAPONS ) +#if CLIENT_WEAPONS if( cl_lw && cl_lw->value ) { HUD_WeaponsPostThink( from, to, cmd, time, random_seed ); diff --git a/cl_dll/in_camera.cpp b/cl_dll/in_camera.cpp index e3ab4937..3934e272 100644 --- a/cl_dll/in_camera.cpp +++ b/cl_dll/in_camera.cpp @@ -459,7 +459,7 @@ void CAM_OutUp( void ) void CAM_ToThirdPerson( void ) { vec3_t viewangles; -#if !defined( _DEBUG ) +#if !_DEBUG //if( gEngfuncs.GetMaxClients() > 1 ) { // no thirdperson in multiplayer. diff --git a/dlls/3wave/threewave_gamerules.cpp b/dlls/3wave/threewave_gamerules.cpp index 96de6376..ff2067cb 100644 --- a/dlls/3wave/threewave_gamerules.cpp +++ b/dlls/3wave/threewave_gamerules.cpp @@ -56,7 +56,7 @@ extern unsigned short g_usCarried; extern edict_t *EntSelectSpawnPoint( CBaseEntity *pPlayer, bool bCheckDM ); extern edict_t *RuneSelectSpawnPoint( void ); -#ifndef NO_VOICEGAMEMGR +#if !NO_VOICEGAMEMGR class CThreeWaveGameMgrHelper : public IVoiceGameMgrHelper { public: @@ -80,7 +80,7 @@ const char *GetTeamName( int team ) CThreeWave::CThreeWave() { -#ifndef NO_VOICEGAMEMGR +#if !NO_VOICEGAMEMGR // CHalfLifeMultiplay already initialized it - just override its helper callback. m_VoiceGameMgr.SetHelper( &g_GameMgrHelper ); #endif @@ -130,7 +130,7 @@ extern cvar_t timeleft, fragsleft; void CThreeWave::Think( void ) { -#ifndef NO_VOICEGAMEMGR +#if !NO_VOICEGAMEMGR m_VoiceGameMgr.Update( gpGlobals->frametime ); #endif ///// Check game rules ///// @@ -271,7 +271,7 @@ extern void DropRune( CBasePlayer *pPlayer ); //========================================================= BOOL CThreeWave::ClientCommand( CBasePlayer *pPlayer, const char *pcmd ) { -#ifndef NO_VOICEGAMEMGR +#if !NO_VOICEGAMEMGR if( m_VoiceGameMgr.ClientCommand( pPlayer, pcmd ) ) return TRUE; #endif diff --git a/dlls/3wave/threewave_gamerules.h b/dlls/3wave/threewave_gamerules.h index b8732b5d..0769817d 100644 --- a/dlls/3wave/threewave_gamerules.h +++ b/dlls/3wave/threewave_gamerules.h @@ -19,7 +19,7 @@ #define BLUE 2 #define RED 1 -#ifndef NO_VOICEGAMEMGR +#if !NO_VOICEGAMEMGR #include "voice_gamemgr.h" #endif diff --git a/dlls/dmc/quake_gun.cpp b/dlls/dmc/quake_gun.cpp index 81163215..b51b6487 100644 --- a/dlls/dmc/quake_gun.cpp +++ b/dlls/dmc/quake_gun.cpp @@ -65,7 +65,7 @@ int CQuakeGun::GetItemInfo(ItemInfo *p) void CQuakeGun::DestroyEffect( void ) { -#ifndef CLIENT_DLL +#if !CLIENT_DLL if ( m_pBeam ) { UTIL_Remove( m_pBeam ); @@ -76,7 +76,7 @@ void CQuakeGun::DestroyEffect( void ) void CQuakeGun::CreateEffect( void ) { -#ifndef CLIENT_DLL +#if !CLIENT_DLL DestroyEffect(); m_pBeam = CBeam::BeamCreate( "sprites/laserbeam.spr", 40 ); @@ -94,7 +94,7 @@ void CQuakeGun::CreateEffect( void ) void CQuakeGun::UpdateEffect( void ) { -#if !defined( CLIENT_DLL ) +#if !CLIENT_DLL UTIL_MakeVectors( m_pPlayer->pev->v_angle + m_pPlayer->pev->punchangle ); Vector vecAiming = gpGlobals->v_forward; Vector vecSrc = m_pPlayer->GetGunPosition( ); @@ -123,14 +123,14 @@ void CQuakeGun::UpdateEffect( void ) } -#if !defined( CLIENT_DLL ) +#if !CLIENT_DLL BOOL CQuakeGun::Deploy( ) { m_pPlayer->pev->viewmodel = MAKE_STRING("models/v_crowbar.mdl"); m_pPlayer->pev->weaponmodel = MAKE_STRING("models/p_9mmhandgun.mdl"); m_pPlayer->m_pszAnimExtention = "onehanded"; -#ifdef CLIENT_DLL +#if CLIENT_DLL g_flLightTime = 0.0; #endif @@ -170,7 +170,7 @@ void CQuakeGun::PrimaryAttack( void ) iQuadSound = SuperDamageSound(); m_pPlayer->W_Attack( iQuadSound ); -#if !defined( CLIENT_DLL ) +#if !CLIENT_DLL if ( m_pPlayer->m_iQuakeWeapon == IT_LIGHTNING && m_pPlayer->pev->deadflag == DEAD_NO ) UpdateEffect(); #endif diff --git a/dlls/dmc/quake_weapons_all.cpp b/dlls/dmc/quake_weapons_all.cpp index 87370019..16a8566c 100644 --- a/dlls/dmc/quake_weapons_all.cpp +++ b/dlls/dmc/quake_weapons_all.cpp @@ -37,7 +37,7 @@ extern unsigned short g_usCarried; extern bool g_bIsThreeWave; -#ifdef CLIENT_DLL +#if CLIENT_DLL #include "cl_entity.h" struct cl_entity_s *GetViewEntity( void ); extern float g_flLightTime; @@ -229,13 +229,11 @@ void CBasePlayer::W_SetCurrentAmmo( int sendanim /* = 1 */ ) m_pCurrentAmmo = NULL; } -#if !defined( CLIENT_DLL ) - +#if !CLIENT_DLL pev->viewmodel = iszViewModel; pev->weaponmodel = iszWeaponModel; m_pszAnimExtention = szAnimExt; - #else { @@ -414,7 +412,7 @@ void CBasePlayer::W_ChangeWeapon( int iWeaponNumber ) m_iQuakeWeapon = iWeapon; W_SetCurrentAmmo(); -#ifdef CLIENT_DLL +#if CLIENT_DLL g_flLightTime = 0.0; #endif } @@ -632,7 +630,7 @@ void CBasePlayer::Q_FireBullets(int iShots, Vector vecDir, Vector vecSpread) ApplyMultiDamage( pev, pev ); } -#if !defined( CLIENT_DLL ) +#if !CLIENT_DLL // Quake Radius damage void Q_RadiusDamage( CBaseEntity *pInflictor, CBaseEntity *pAttacker, float flDamage, CBaseEntity *pIgnore ) { @@ -667,7 +665,7 @@ void Q_RadiusDamage( CBaseEntity *pInflictor, CBaseEntity *pAttacker, float flDa void LightningHit(CBaseEntity *pTarget, CBaseEntity *pAttacker, Vector vecHitPos, float flDamage, TraceResult *ptr, Vector vecDir ) { -#ifndef CLIENT_DLL +#if !CLIENT_DLL SpawnBlood( vecHitPos, BLOOD_COLOR_RED, flDamage * 1.5f ); if ( g_pGameRules->PlayerRelationship( pTarget, pAttacker ) != GR_TEAMMATE ) @@ -683,7 +681,7 @@ void LightningHit(CBaseEntity *pTarget, CBaseEntity *pAttacker, Vector vecHitPos // Lightning Damage void CBasePlayer::LightningDamage( Vector p1, Vector p2, CBaseEntity *pAttacker, float flDamage, Vector vecDir) { -#if !defined( CLIENT_DLL ) +#if !CLIENT_DLL TraceResult trace; Vector vecThru = (p2 - p1).Normalize(); vecThru.x = 0 - vecThru.y; @@ -749,7 +747,7 @@ void CBasePlayer::W_FireAxe() pEntity->TakeDamage( pev, pev, iDmg, DMG_GENERIC ); -#ifndef CLIENT_DLL +#if !CLIENT_DLL if ( g_pGameRules->PlayerRelationship( this, pEntity ) != GR_TEAMMATE ) SpawnBlood( vecOrg, BLOOD_COLOR_RED, iDmg * 4 ); // Make a lot of Blood! #endif @@ -775,7 +773,7 @@ void CBasePlayer::W_FireHook( void ) Throw_Grapple(); } -#ifdef CLIENT_DLL +#if CLIENT_DLL unsigned short g_usCable; unsigned short g_usHook; unsigned short g_usCarried; @@ -884,7 +882,7 @@ void CBasePlayer::W_FireLightning( int iQuadSound ) float flCellsBurnt = *m_pCurrentAmmo; *m_pCurrentAmmo = 0; W_SetCurrentAmmo(); -#if !defined( CLIENT_DLL ) +#if !CLIENT_DLL Q_RadiusDamage( this, this, 35 * flCellsBurnt, NULL ); #endif return; @@ -893,8 +891,7 @@ void CBasePlayer::W_FireLightning( int iQuadSound ) PLAYBACK_EVENT_FULL( FEV_NOTHOST, edict(), m_usLightning, 0, pev->origin, pev->angles, 0.0, 0.0, iQuadSound, 0, playsound, 0 ); -#if !defined( CLIENT_DLL ) - +#if !CLIENT_DLL if (gpGlobals->deathmatch != 4 ) *m_pCurrentAmmo -= 1; diff --git a/dlls/doors.cpp b/dlls/doors.cpp index 58ce6bb2..8ed993ff 100644 --- a/dlls/doors.cpp +++ b/dlls/doors.cpp @@ -628,7 +628,7 @@ void CBaseDoor::DoorGoUp( void ) Vector vecCenter( Center() ); PLAYBACK_EVENT_FULL( FEV_RELIABLE, NULL, m_usDoorGoUp, 0.0, vecCenter, g_vecZero, 0.0, 0.0, ( m_bMoveSnd << 8 ) | ( m_bStopSnd & 0xff ), 0, 0, 0 ); -#if defined ( OLD_SOUNDS ) +#if OLD_SOUNDS STOP_SOUND( ENT( pev ), CHAN_STATIC, (char*)STRING( pev->noiseMoving ) ); if( m_toggle_state != TS_GOING_UP && m_toggle_state != TS_GOING_DOWN ) EMIT_SOUND( ENT( pev ), CHAN_STATIC, (char*)STRING( pev->noiseMoving ), 1, ATTN_NORM ); @@ -681,7 +681,7 @@ void CBaseDoor::DoorHitTop( void ) PLAYBACK_EVENT_FULL( FEV_RELIABLE, NULL, m_usDoorHitTop, 0.0, vecCenter, g_vecZero, 0.0, 0.0, ( m_bMoveSnd << 8 ) | ( m_bStopSnd & 0xff ), 0, 0, 0 ); -#if defined ( OLD_SOUNDS ) +#if OLD_SOUNDS STOP_SOUND( ENT( pev ), CHAN_STATIC, (char*)STRING( pev->noiseMoving ) ); EMIT_SOUND( ENT( pev ), CHAN_STATIC, (char*)STRING( pev->noiseArrived ), 1, ATTN_NORM ); #endif @@ -731,7 +731,7 @@ void CBaseDoor::DoorGoDown( void ) Vector vecCenter( Center() ); PLAYBACK_EVENT_FULL( FEV_RELIABLE, NULL, m_usDoorGoDown, 0.0, vecCenter, g_vecZero, 0.0, 0.0, ( m_bMoveSnd << 8 ) | ( m_bStopSnd & 0xff ), 0, 0, 0 ); -#if defined ( OLD_SOUNDS ) +#if OLD_SOUNDS STOP_SOUND( ENT( pev ), CHAN_STATIC, (char*)STRING( pev->noiseMoving ) ); if( m_toggle_state != TS_GOING_UP && m_toggle_state != TS_GOING_DOWN ) EMIT_SOUND( ENT( pev ), CHAN_STATIC, (char*)STRING( pev->noiseMoving ), 1, ATTN_NORM ); @@ -763,7 +763,7 @@ void CBaseDoor::DoorHitBottom( void ) Vector vecCenter( Center() ); PLAYBACK_EVENT_FULL( FEV_RELIABLE, NULL, m_usDoorHitBottom, 0.0, vecCenter, g_vecZero, 0.0, 0.0, ( m_bMoveSnd << 8 ) | ( m_bStopSnd & 0xff ), 0, 0, 0 ); -#if defined ( OLD_SOUNDS ) +#if OLD_SOUNDS STOP_SOUND( ENT( pev ), CHAN_STATIC, (char*)STRING( pev->noiseMoving ) ); EMIT_SOUND( ENT( pev ), CHAN_STATIC, (char*)STRING( pev->noiseArrived ), 1, ATTN_NORM ); #endif diff --git a/pm_shared/pm_debug.c b/pm_shared/pm_debug.c index ce904760..d726e19a 100644 --- a/pm_shared/pm_debug.c +++ b/pm_shared/pm_debug.c @@ -49,7 +49,7 @@ static int PM_boxpnt[6][4] = void PM_ShowClipBox( void ) { -#if defined( _DEBUG ) +#if _DEBUG vec3_t org; vec3_t offset = { 0, 0, 0 }; diff --git a/pm_shared/pm_shared.c b/pm_shared/pm_shared.c index e4aeaf23..c16ad90e 100644 --- a/pm_shared/pm_shared.c +++ b/pm_shared/pm_shared.c @@ -2730,7 +2730,7 @@ void PM_Move( struct playermove_s *ppmove, int server ) pmove->friction = 1.0f; } -#ifdef CLIENT_DLL +#if CLIENT_DLL g_onground = ( pmove->onground != -1 ); g_inwater = ( pmove->waterlevel > 1 ); g_walking = ( pmove->movetype == MOVETYPE_WALK );