From e16ea21dc8a710237ade8413207f58d403c616a3 Mon Sep 17 00:00:00 2001 From: Joe Ludwig Date: Wed, 17 Jul 2013 18:26:59 -0700 Subject: * Added support for building shaders in your mod * Added nav mesh support * fixed many warnings and misc bugs * Fixed the create*projects scripts in mp * Added a bunch of stuff to .gitignore --- mp/src/game/shared/activitylist.cpp | 5 +++++ mp/src/game/shared/ai_activity.h | 7 +++++++ mp/src/game/shared/baseentity_shared.cpp | 16 ++++++++++++++++ mp/src/game/shared/multiplay_gamerules.cpp | 2 +- mp/src/game/shared/particle_property.cpp | 6 ++++++ mp/src/game/shared/playernet_vars.h | 4 ++-- mp/src/game/shared/teamplay_round_timer.h | 1 + mp/src/game/shared/teamplayroundbased_gamerules.cpp | 2 +- mp/src/game/shared/voice_status.cpp | 6 +++--- 9 files changed, 42 insertions(+), 7 deletions(-) (limited to 'mp/src/game/shared') diff --git a/mp/src/game/shared/activitylist.cpp b/mp/src/game/shared/activitylist.cpp index 1b61fb64..a69933c9 100644 --- a/mp/src/game/shared/activitylist.cpp +++ b/mp/src/game/shared/activitylist.cpp @@ -2265,6 +2265,11 @@ void ActivityList_RegisterSharedActivities( void ) REGISTER_SHARED_ACTIVITY( ACT_MP_RELOAD_AIRWALK_PRIMARY3_END ); REGISTER_SHARED_ACTIVITY( ACT_MP_RELOAD_SWIM_PRIMARY3 ); + REGISTER_SHARED_ACTIVITY( ACT_MP_THROW ); + REGISTER_SHARED_ACTIVITY( ACT_THROWABLE_VM_DRAW ); + REGISTER_SHARED_ACTIVITY( ACT_THROWABLE_VM_IDLE ); + REGISTER_SHARED_ACTIVITY( ACT_THROWABLE_VM_FIRE ); + AssertMsg( g_HighestActivity == LAST_SHARED_ACTIVITY - 1, "Not all activities from ai_activity.h registered in activitylist.cpp" ); } diff --git a/mp/src/game/shared/ai_activity.h b/mp/src/game/shared/ai_activity.h index 854da726..4e94fca8 100644 --- a/mp/src/game/shared/ai_activity.h +++ b/mp/src/game/shared/ai_activity.h @@ -2095,6 +2095,13 @@ typedef enum ACT_MP_RELOAD_AIRWALK_PRIMARY3_END, ACT_MP_RELOAD_SWIM_PRIMARY3, + // Throwable Animations + ACT_MP_THROW, + + ACT_THROWABLE_VM_DRAW, + ACT_THROWABLE_VM_IDLE, + ACT_THROWABLE_VM_FIRE, + // this is the end of the global activities, private per-monster activities start here. LAST_SHARED_ACTIVITY, } Activity; diff --git a/mp/src/game/shared/baseentity_shared.cpp b/mp/src/game/shared/baseentity_shared.cpp index 470b2d2e..949143b1 100644 --- a/mp/src/game/shared/baseentity_shared.cpp +++ b/mp/src/game/shared/baseentity_shared.cpp @@ -48,6 +48,11 @@ ConVar hl2_episodic( "hl2_episodic", "0", FCVAR_REPLICATED ); #include "prop_portal_shared.h" #endif +#ifdef TF_DLL +#include "tf_gamerules.h" +#include "tf_weaponbase.h" +#endif // TF_DLL + #include "rumble_shared.h" // memdbgon must be the last include file in a .cpp file!!! @@ -1746,6 +1751,17 @@ void CBaseEntity::FireBullets( const FireBulletsInfo_t &info ) { pShootThroughPortal = NULL; } +#elif TF_DLL + CTraceFilterIgnoreFriendlyCombatItems traceFilterCombatItem( this, COLLISION_GROUP_NONE, GetTeamNumber() ); + if ( TFGameRules() && TFGameRules()->GameModeUsesUpgrades() ) + { + CTraceFilterChain traceFilterChain( &traceFilter, &traceFilterCombatItem ); + AI_TraceLine(info.m_vecSrc, vecEnd, MASK_SHOT, &traceFilterChain, &tr); + } + else + { + AI_TraceLine(info.m_vecSrc, vecEnd, MASK_SHOT, &traceFilter, &tr); + } #else AI_TraceLine(info.m_vecSrc, vecEnd, MASK_SHOT, &traceFilter, &tr); #endif //#ifdef PORTAL diff --git a/mp/src/game/shared/multiplay_gamerules.cpp b/mp/src/game/shared/multiplay_gamerules.cpp index f933634c..2cbb6f61 100644 --- a/mp/src/game/shared/multiplay_gamerules.cpp +++ b/mp/src/game/shared/multiplay_gamerules.cpp @@ -1223,7 +1223,7 @@ ConVarRef suitcharger( "sk_suitcharger" ); { if ( bForceSpew || V_stricmp( szLastResult, pszResult) ) { - Msg( "Using map cycle file %s.\n", pszResult ); + Msg( "Using map cycle file '%s'.\n", pszResult ); V_strcpy_safe( szLastResult, pszResult ); } return; diff --git a/mp/src/game/shared/particle_property.cpp b/mp/src/game/shared/particle_property.cpp index b1ae32a7..18d278ad 100644 --- a/mp/src/game/shared/particle_property.cpp +++ b/mp/src/game/shared/particle_property.cpp @@ -26,6 +26,12 @@ // memdbgon must be the last include file in a .cpp file!!! #include "tier0/memdbgon.h" +#ifdef STAGING_ONLY +#ifdef TF_CLIENT_DLL +extern ConVar tf_unusual_effect_offset; +#endif +#endif + //----------------------------------------------------------------------------- // Save/load //----------------------------------------------------------------------------- diff --git a/mp/src/game/shared/playernet_vars.h b/mp/src/game/shared/playernet_vars.h index abb49765..9fdeec0f 100644 --- a/mp/src/game/shared/playernet_vars.h +++ b/mp/src/game/shared/playernet_vars.h @@ -77,10 +77,10 @@ struct fogplayerparams_t { m_hCtrl.Set( NULL ); m_flTransitionTime = -1.0f; - m_OldColor.r = m_OldColor.g = m_OldColor.b = m_OldColor.a = 0; + m_OldColor.r = m_OldColor.g = m_OldColor.g = m_OldColor.a = 0.0f; m_flOldStart = 0.0f; m_flOldEnd = 0.0f; - m_NewColor.r = m_NewColor.g = m_NewColor.b = m_NewColor.a = 0; + m_NewColor.r = m_NewColor.g = m_NewColor.g = m_NewColor.a = 0.0f; m_flNewStart = 0.0f; m_flNewEnd = 0.0f; } diff --git a/mp/src/game/shared/teamplay_round_timer.h b/mp/src/game/shared/teamplay_round_timer.h index 7826cf5b..470a5f16 100644 --- a/mp/src/game/shared/teamplay_round_timer.h +++ b/mp/src/game/shared/teamplay_round_timer.h @@ -79,6 +79,7 @@ public: void SetStopWatch( bool bState ) { m_bStopWatchTimer = bState; } bool IsStopWatchTimer( void ) { return m_bStopWatchTimer; } float GetStopWatchTotalTime( void ) { return m_flTotalTime; } + bool IsRoundMaxTimerSet( void ) { return m_nTimerMaxLength > 0; } private: diff --git a/mp/src/game/shared/teamplayroundbased_gamerules.cpp b/mp/src/game/shared/teamplayroundbased_gamerules.cpp index f737aecf..a843d134 100644 --- a/mp/src/game/shared/teamplayroundbased_gamerules.cpp +++ b/mp/src/game/shared/teamplayroundbased_gamerules.cpp @@ -38,7 +38,7 @@ #if defined(TF_CLIENT_DLL) || defined(TF_DLL) #include "tf_lobby.h" #ifdef GAME_DLL - #include "player_vs_environment/tf_populator.h" + #include "player_vs_environment/tf_population_manager.h" #include "../server/tf/tf_gc_server.h" #include "../server/tf/tf_objective_resource.h" #else diff --git a/mp/src/game/shared/voice_status.cpp b/mp/src/game/shared/voice_status.cpp index 4d295713..ed6c0f2f 100644 --- a/mp/src/game/shared/voice_status.cpp +++ b/mp/src/game/shared/voice_status.cpp @@ -425,7 +425,7 @@ void CVoiceStatus::UpdateServerState(bool bForce) void CVoiceStatus::HandleVoiceMaskMsg(bf_read &msg) { - unsigned long dw; + unsigned int dw; for(dw=0; dw < VOICE_MAX_PLAYERS_DW; dw++) { m_AudiblePlayers.SetDWord(dw, (unsigned long)msg.ReadLong()); @@ -434,8 +434,8 @@ void CVoiceStatus::HandleVoiceMaskMsg(bf_read &msg) if( voice_clientdebug.GetInt()) { Msg("CVoiceStatus::HandleVoiceMaskMsg\n"); - Msg(" - m_AudiblePlayers[%d] = %lu\n", dw, m_AudiblePlayers.GetDWord(dw)); - Msg(" - m_ServerBannedPlayers[%d] = %lu\n", dw, m_ServerBannedPlayers.GetDWord(dw)); + Msg(" - m_AudiblePlayers[%d] = %u\n", dw, m_AudiblePlayers.GetDWord(dw)); + Msg(" - m_ServerBannedPlayers[%d] = %u\n", dw, m_ServerBannedPlayers.GetDWord(dw)); } } -- cgit v1.2.3