Fixed packet transmission of EntHier every frame to every client (Mantis #999)

git-svn-id: https://unknownworlds.svn.cloudforge.com/ns1@36 67975925-1194-0748-b3d5-c16f83f1a3a1
This commit is contained in:
XP-Cagey 2005-04-06 01:42:45 +00:00
parent e5143747a5
commit 6fab15858a
1 changed files with 2 additions and 0 deletions

View File

@ -1966,6 +1966,8 @@ const int kPositionNetworkConstant = 25;
void NetMsg_UpdateEntityHierarchy( entvars_t* const pev, const MapEntityMap& NewItems, const EntityListType& OldItems )
{
const int kMaxUpdatesPerPacket = 30;
if( NewItems.empty() && OldItems.empty() ) { return; } //nothing to send!
MapEntityMap::const_iterator new_current, new_end = NewItems.end();
EntityListType::const_iterator old_current, old_end = OldItems.end();
int short_data, long_data, count = 1;