mirror of
https://github.com/unknownworlds/NS.git
synced 2024-11-26 14:30:56 +00:00
3.01 candidate
git-svn-id: https://unknownworlds.svn.cloudforge.com/ns1@2 67975925-1194-0748-b3d5-c16f83f1a3a1
This commit is contained in:
parent
8552ac617c
commit
02f0196da7
4 changed files with 15 additions and 4 deletions
BIN
main/dlls/ns.dll
BIN
main/dlls/ns.dll
Binary file not shown.
|
@ -4000,7 +4000,7 @@ void CBasePlayer :: ForceClientDllUpdate( void )
|
||||||
// Now force all the necessary messages
|
// Now force all the necessary messages
|
||||||
// to be sent.
|
// to be sent.
|
||||||
UpdateClientData();
|
UpdateClientData();
|
||||||
m_fWeapon = TRUE; // Force weapon send
|
// m_fWeapon = TRUE; // Force weapon send
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -4739,6 +4739,8 @@ void CBasePlayer :: UpdateClientData( void )
|
||||||
// New Weapon?
|
// New Weapon?
|
||||||
//
|
//
|
||||||
|
|
||||||
|
bool forceCurWeaponUpdate = false;
|
||||||
|
|
||||||
if (!m_fKnownItem)
|
if (!m_fKnownItem)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
@ -4759,6 +4761,10 @@ void CBasePlayer :: UpdateClientData( void )
|
||||||
|
|
||||||
// Send ALL the weapon info now
|
// Send ALL the weapon info now
|
||||||
this->SendWeaponUpdate();
|
this->SendWeaponUpdate();
|
||||||
|
|
||||||
|
// tankefugl: HACK force an full curweapon update after each bunch of weaponlists sent
|
||||||
|
forceCurWeaponUpdate = true;
|
||||||
|
// :tankefugl
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -4767,9 +4773,13 @@ void CBasePlayer :: UpdateClientData( void )
|
||||||
// Update all the items
|
// Update all the items
|
||||||
for ( int i = 0; i < MAX_ITEM_TYPES; i++ )
|
for ( int i = 0; i < MAX_ITEM_TYPES; i++ )
|
||||||
{
|
{
|
||||||
|
if (forceCurWeaponUpdate == true)
|
||||||
|
m_fWeapon = FALSE;
|
||||||
if ( thePlayerToUseForWeaponUpdates->m_rgpPlayerItems[i] ) // each item updates it's successors
|
if ( thePlayerToUseForWeaponUpdates->m_rgpPlayerItems[i] ) // each item updates it's successors
|
||||||
thePlayerToUseForWeaponUpdates->m_rgpPlayerItems[i]->UpdateClientData( thePlayerToUseForWeaponUpdates );
|
thePlayerToUseForWeaponUpdates->m_rgpPlayerItems[i]->UpdateClientData( thePlayerToUseForWeaponUpdates );
|
||||||
}
|
}
|
||||||
|
if (forceCurWeaponUpdate == true)
|
||||||
|
m_fWeapon = TRUE;
|
||||||
|
|
||||||
// Cache and client weapon change
|
// Cache and client weapon change
|
||||||
m_pClientActiveItem = thePlayerToUseForWeaponUpdates->m_pActiveItem;
|
m_pClientActiveItem = thePlayerToUseForWeaponUpdates->m_pActiveItem;
|
||||||
|
@ -4816,6 +4826,7 @@ void CBasePlayer::SendWeaponUpdate()
|
||||||
WRITE_BYTE(II.iFlags); // byte Flags
|
WRITE_BYTE(II.iFlags); // byte Flags
|
||||||
MESSAGE_END();
|
MESSAGE_END();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//=========================================================
|
//=========================================================
|
||||||
|
|
|
@ -1192,7 +1192,7 @@ int CBasePlayerWeapon::UpdateClientData( CBasePlayer *pPlayer )
|
||||||
m_iClientWeaponState = state;
|
m_iClientWeaponState = state;
|
||||||
// puzl: 497 - remember the old enabled state
|
// puzl: 497 - remember the old enabled state
|
||||||
m_iClientEnableState = m_iEnabled;
|
m_iClientEnableState = m_iEnabled;
|
||||||
// pPlayer->m_fWeapon = TRUE;
|
pPlayer->m_fWeapon = TRUE;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4499,7 +4499,7 @@ void AvHPlayer::HandleTopDownInput()
|
||||||
AvHObservatory* theObs = dynamic_cast<AvHObservatory*>(theEntity);
|
AvHObservatory* theObs = dynamic_cast<AvHObservatory*>(theEntity);
|
||||||
if ( theObs )
|
if ( theObs )
|
||||||
{
|
{
|
||||||
if ( theObs->GetIsTechnologyAvailable(BUILD_SCAN) == false )
|
if ( (theObs->GetIsTechnologyAvailable(BUILD_SCAN)) == false && (theMessageID == BUILD_SCAN) )
|
||||||
theCanBuild = false;
|
theCanBuild = false;
|
||||||
}
|
}
|
||||||
if(!theObs && theMessageID == BUILD_SCAN) {
|
if(!theObs && theMessageID == BUILD_SCAN) {
|
||||||
|
@ -10962,4 +10962,4 @@ bool AvHPlayer::JoinTeamCooledDown(float inCoolDownTime) {
|
||||||
else
|
else
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
// :tankefugl
|
// :tankefugl
|
||||||
|
|
Loading…
Reference in a new issue