mirror of
https://github.com/mapbase-source/source-sdk-2013.git
synced 2025-04-09 11:10:05 +03:00
Merge branch 'master' of https://github.com/ValveSoftware/source-sdk-2013 into mapbase-mp-2025
# Conflicts: # CONTRIBUTING # src/game/server/SkyCamera.cpp # src/game/server/player.cpp
This commit is contained in:
commit
c88468ff16
@ -6052,7 +6052,7 @@ void C_TFPlayer::ClientThink()
|
||||
//
|
||||
// Passtime ask for ball button
|
||||
//
|
||||
if ( m_nButtons & IN_ATTACK3 )
|
||||
if ( m_afButtonPressed & IN_ATTACK3 )
|
||||
{
|
||||
engine->ClientCmd("voicemenu 1 8");
|
||||
}
|
||||
|
@ -218,6 +218,12 @@ void CSkyCamera::Activate( )
|
||||
}
|
||||
#endif
|
||||
|
||||
// matches the behavior of fog controller
|
||||
if ( GameRules()->IsOfficialMap() )
|
||||
{
|
||||
m_skyboxData.fog.radial = true;
|
||||
}
|
||||
|
||||
#ifdef MAPBASE
|
||||
if (HasSpawnFlags( SF_SKY_MASTER ))
|
||||
g_hActiveSkybox = this;
|
||||
|
@ -8982,11 +8982,10 @@ void CLogicPlayerInfo::GetPlayerInfo( CBasePlayer *pPlayer )
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
void SendProxy_CropFlagsToPlayerFlagBitsLength( const SendProp *pProp, const void *pStruct, const void *pVarData, DVariant *pOut, int iElement, int objectID)
|
||||
void SendProxy_CropFlagsToPlayerFlagBitsLength( const SendProp* pProp, const void* pStruct, const void* pVarData, DVariant* pOut, int iElement, int objectID )
|
||||
{
|
||||
int mask = (1<<PLAYER_FLAG_BITS) - 1;
|
||||
int data = *(int *)pVarData;
|
||||
int mask = ( 1 << PLAYER_FLAG_BITS ) - 1;
|
||||
int data = *( int* )pVarData;
|
||||
|
||||
pOut->m_Int = ( data & mask );
|
||||
}
|
||||
|
@ -2626,7 +2626,7 @@ void CPopulationManager::AllocateBots()
|
||||
Warning( "%d bots were already allocated some how before CPopulationManager::AllocateBots was called\n", botVector.Count() );
|
||||
}
|
||||
|
||||
for ( int i = nNumEnemyBots; i < MVM_INVADERS_TEAM_SIZE; ++i )
|
||||
for ( int i = nNumEnemyBots; i < tf_mvm_max_invaders.GetInt(); ++i )
|
||||
{
|
||||
CTFBot* newBot = NextBotCreatePlayerBot< CTFBot >( "TFBot", false );
|
||||
if ( newBot )
|
||||
|
@ -137,8 +137,6 @@ public:
|
||||
bool IsBonusRound() const { return m_bBonusRound; }
|
||||
CBaseCombatCharacter* GetBonusBoss() const { return m_hBonusBoss; }
|
||||
|
||||
enum { MVM_INVADERS_TEAM_SIZE = 22 };
|
||||
|
||||
static bool GetWavesUseReadyBetween() { return true; }
|
||||
|
||||
void SetDefaultEventChangeAttributesName( const char* pszDefaultEventChangeAttributesName ) { m_defaultEventChangeAttributesName = pszDefaultEventChangeAttributesName; }
|
||||
|
@ -1014,7 +1014,7 @@ bool CTFBotSpawner::Spawn( const Vector &rawHere, EntityHandleVector_t *result )
|
||||
|
||||
nNumEnemyBots = botVector.Count();
|
||||
|
||||
if ( nNumEnemyBots >= CPopulationManager::MVM_INVADERS_TEAM_SIZE )
|
||||
if ( nNumEnemyBots >= tf_mvm_max_invaders.GetInt() )
|
||||
{
|
||||
// no room for more
|
||||
if ( tf_populator_debug.GetBool() )
|
||||
@ -1023,10 +1023,10 @@ bool CTFBotSpawner::Spawn( const Vector &rawHere, EntityHandleVector_t *result )
|
||||
}
|
||||
|
||||
// extra guard if we're over full on bots
|
||||
if ( nNumEnemyBots > CPopulationManager::MVM_INVADERS_TEAM_SIZE )
|
||||
if ( nNumEnemyBots > tf_mvm_max_invaders.GetInt() )
|
||||
{
|
||||
// Kick bots until we are at the proper number starting with spectator bots
|
||||
int iNumberToKick = nNumEnemyBots - CPopulationManager::MVM_INVADERS_TEAM_SIZE;
|
||||
int iNumberToKick = nNumEnemyBots - tf_mvm_max_invaders.GetInt();
|
||||
int iKickedBots = 0;
|
||||
|
||||
// loop through spectators and invaders in that order
|
||||
|
@ -741,7 +741,7 @@ bool CMissionPopulator::UpdateMission( CTFBot::MissionType mission )
|
||||
// are there enough free slots?
|
||||
int currentEnemyCount = GetGlobalTeam( TF_TEAM_PVE_INVADERS )->GetNumPlayers();
|
||||
|
||||
if ( currentEnemyCount + m_desiredCount > CPopulationManager::MVM_INVADERS_TEAM_SIZE )
|
||||
if ( currentEnemyCount + m_desiredCount > tf_mvm_max_invaders.GetInt() )
|
||||
{
|
||||
// not enough slots yet
|
||||
if ( tf_populator_debug.GetBool() )
|
||||
@ -1578,7 +1578,7 @@ void CWaveSpawnPopulator::Update( void )
|
||||
|
||||
int currentEnemyCount = GetGlobalTeam( TF_TEAM_PVE_INVADERS )->GetNumPlayers();
|
||||
|
||||
if ( currentEnemyCount + m_spawnCount + m_reservedPlayerSlotCount > CPopulationManager::MVM_INVADERS_TEAM_SIZE )
|
||||
if ( currentEnemyCount + m_spawnCount + m_reservedPlayerSlotCount > tf_mvm_max_invaders.GetInt() )
|
||||
{
|
||||
// no space right now
|
||||
return;
|
||||
|
@ -875,6 +875,7 @@ ConVar tf_raid_allow_overtime( "tf_raid_allow_overtime", "0"/*, FCVAR_CHEAT*/ );
|
||||
|
||||
ConVar tf_mvm_defenders_team_size( "tf_mvm_defenders_team_size", "6", FCVAR_REPLICATED | FCVAR_NOTIFY, "Maximum number of defenders in MvM" );
|
||||
ConVar tf_mvm_max_connected_players( "tf_mvm_max_connected_players", "10", FCVAR_GAMEDLL, "Maximum number of connected real players in MvM" );
|
||||
ConVar tf_mvm_max_invaders( "tf_mvm_max_invaders", "22", FCVAR_GAMEDLL, "Maximum number of invaders in MvM" );
|
||||
|
||||
ConVar tf_mvm_min_players_to_start( "tf_mvm_min_players_to_start", "3", FCVAR_REPLICATED | FCVAR_NOTIFY, "Minimum number of players connected to start a countdown timer" );
|
||||
ConVar tf_mvm_respec_enabled( "tf_mvm_respec_enabled", "1", FCVAR_CHEAT | FCVAR_REPLICATED, "Allow players to refund credits spent on player and item upgrades." );
|
||||
|
@ -97,6 +97,7 @@ class CMannVsMachineUpgrades;
|
||||
//extern ConVar tf_populator_damage_multiplier;
|
||||
|
||||
extern ConVar tf_mvm_defenders_team_size;
|
||||
extern ConVar tf_mvm_max_invaders;
|
||||
|
||||
const int kLadder_TeamSize_6v6 = 6;
|
||||
const int kLadder_TeamSize_9v9 = 9;
|
||||
|
@ -12110,6 +12110,13 @@ bool CTFPlayer::CanJump() const
|
||||
if ( m_Shared.InCond( TF_COND_TAUNTING ) )
|
||||
return false;
|
||||
|
||||
CTFWeaponBase *pActiveWeapon = m_Shared.GetActiveTFWeapon();
|
||||
if ( pActiveWeapon )
|
||||
{
|
||||
if ( !pActiveWeapon->OwnerCanJump() )
|
||||
return false;
|
||||
}
|
||||
|
||||
int iNoJump = 0;
|
||||
CALL_ATTRIB_HOOK_INT( iNoJump, no_jump );
|
||||
|
||||
|
@ -654,19 +654,7 @@ void CTFCompoundBow::SetArrowAlight( bool bAlight )
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
//-----------------------------------------------------------------------------
|
||||
void CTFCompoundBow::SetInternalChargeBeginTime( float flChargeBeginTime )
|
||||
bool CTFCompoundBow::OwnerCanJump( void )
|
||||
{
|
||||
#ifdef GAME_DLL
|
||||
float flCurrentChargeBeginTime = GetInternalChargeBeginTime();
|
||||
if ( flCurrentChargeBeginTime == 0.f && flChargeBeginTime > 0.f )
|
||||
{
|
||||
DisableJump();
|
||||
}
|
||||
else if ( flCurrentChargeBeginTime > 0.f && flChargeBeginTime == 0.f )
|
||||
{
|
||||
EnableJump();
|
||||
}
|
||||
#endif // GAME_DLL
|
||||
|
||||
BaseClass::SetInternalChargeBeginTime( flChargeBeginTime );
|
||||
return GetInternalChargeBeginTime() == 0.f;
|
||||
}
|
||||
|
@ -89,8 +89,7 @@ public:
|
||||
|
||||
void SetArrowAlight( bool bAlight );
|
||||
|
||||
protected:
|
||||
virtual void SetInternalChargeBeginTime( float flChargeBeginTime ) OVERRIDE;
|
||||
bool OwnerCanJump( void );
|
||||
|
||||
private:
|
||||
#ifdef CLIENT_DLL
|
||||
|
@ -335,6 +335,7 @@ class CTFWeaponBase : public CBaseCombatWeapon, public IHasOwner, public IHasGen
|
||||
void EnableDuck();
|
||||
void DisableDuck();
|
||||
|
||||
virtual bool OwnerCanJump( void ) { return true; }
|
||||
virtual bool OwnerCanTaunt( void ) { return true; }
|
||||
virtual bool CanBeCritBoosted( void );
|
||||
bool CanHaveRevengeCrits( void );
|
||||
|
@ -163,7 +163,7 @@
|
||||
#define FL_INWATER (1<<10) // In water
|
||||
|
||||
// NOTE if you move things up, make sure to change this value
|
||||
#define PLAYER_FLAG_BITS 11
|
||||
#define PLAYER_FLAG_BITS 32
|
||||
|
||||
#define FL_FLY (1<<11) // Changes the SV_Movestep() behavior to not need to be on ground
|
||||
#define FL_SWIM (1<<12) // Changes the SV_Movestep() behavior to not need to be on ground (but stay in water)
|
||||
|
Loading…
x
Reference in New Issue
Block a user