From 7030d81e73315ea504b0a6ad65892d99b50ef4b9 Mon Sep 17 00:00:00 2001 From: hzqst <113660872@qq.com> Date: Tue, 5 Aug 2025 16:19:26 +0800 Subject: [PATCH] Update CNetMessage, IRecipientFilter & INetChan (#313) Co-authored-by: GAMMACASE <31375974+GAMMACASE@users.noreply.github.com> --- public/inetchannel.h | 6 +++--- public/inetchannelinfo.h | 4 ++-- public/irecipientfilter.h | 3 +-- public/networksystem/netmessage.h | 4 +++- 4 files changed, 9 insertions(+), 8 deletions(-) diff --git a/public/inetchannel.h b/public/inetchannel.h index 5bbf6122..7c583533 100644 --- a/public/inetchannel.h +++ b/public/inetchannel.h @@ -122,6 +122,7 @@ public: virtual void SetInstantReplayIntercept( IInstantReplayIntercept *pInstantReplayIntercept ) = 0; virtual bool IsNull( void ) const = 0; virtual bool ProcessDemoPacket( NetPacket_t *packet ) = 0; + virtual void ProcessMessages() = 0; virtual void InstallMessageFilter( INetworkMessageProcessingPreFilter *pFilter ) = 0; virtual void UninstallMessageFilter( INetworkMessageProcessingPreFilter *pFilter ) = 0; @@ -138,11 +139,10 @@ public: virtual EResult SendRawMessage( const void *pData, uint32 cbData, int nSendFlags ) = 0; - virtual int GetCurrentNetMessageBits( void ) const = 0; - virtual int GetCurrentNetMessageInSequenceNr( void ) const = 0; - virtual void unk211() = 0; virtual void unk212() = 0; + virtual void unk213() = 0; + virtual void unk214() = 0; }; diff --git a/public/inetchannelinfo.h b/public/inetchannelinfo.h index af9b84e0..e2a65a27 100644 --- a/public/inetchannelinfo.h +++ b/public/inetchannelinfo.h @@ -72,8 +72,8 @@ public: virtual float GetAvgChoke(int flow) const = 0; virtual float GetAvgData( int flow ) const = 0; // data flow in bytes/sec - virtual float unk001( int flow ) const = 0; - + virtual float GetAvgPacketBytes( int flow ) const = 0; //avg packet bytes/sec // flow=0: m_flOutBytesPerSec //flow=0: m_flInBytesPerSec + virtual float GetAvgPackets( int flow ) const = 0; // avg packets/sec virtual int GetTotalData( int flow ) const = 0; // total flow in/out in bytes virtual int GetTotalPackets( int flow ) const = 0; diff --git a/public/irecipientfilter.h b/public/irecipientfilter.h index 17a92774..2efb3ef5 100644 --- a/public/irecipientfilter.h +++ b/public/irecipientfilter.h @@ -25,8 +25,7 @@ public: virtual NetChannelBufType_t GetNetworkBufType( void ) const = 0; virtual bool IsInitMessage( void ) const = 0; - virtual int GetRecipientCount( void ) const = 0; - virtual CPlayerSlot GetRecipientIndex( int slot ) const = 0; + virtual const CBitVec<64> &GetRecipients( void ) const = 0; }; #endif // IRECIPIENTFILTER_H diff --git a/public/networksystem/netmessage.h b/public/networksystem/netmessage.h index f1e90d9e..be2cbcce 100644 --- a/public/networksystem/netmessage.h +++ b/public/networksystem/netmessage.h @@ -41,7 +41,9 @@ public: } private: - char unk001[32]; + char unk001[24]; + float m_flMargin; + char unk002[12]; }; // AMNOTE: This is a stub class over real CNetMessagePB!