Update INetChannel.

This commit is contained in:
Nicholas Hastings 2014-11-10 13:24:08 -05:00
parent c9c1b66154
commit 688e870937
2 changed files with 11 additions and 6 deletions

View File

@ -16,6 +16,7 @@
#include "tier1/netadr.h" #include "tier1/netadr.h"
class IDemoRecorder; class IDemoRecorder;
class IInstantReplayIntercept;
class INetMessage; class INetMessage;
class INetChannelHandler; class INetChannelHandler;
class INetChannelInfo; class INetChannelInfo;
@ -55,12 +56,14 @@ public:
virtual bool UnregisterMessage(INetMessageBinder *msg) = 0; virtual bool UnregisterMessage(INetMessageBinder *msg) = 0;
virtual void SetTimeout(float seconds, bool bForceExact = false) = 0; virtual void SetTimeout(float seconds, bool bForceExact = false) = 0;
virtual void SetDemoRecorder(IDemoRecorder *recorder) = 0; virtual void SetDemoRecorder(IDemoRecorder *recorder) = 0;
virtual void SetInstantReplayIntercept(IInstantReplayIntercept *intercept) = 0;
virtual void Reset( void ) = 0; virtual void Reset( void ) = 0;
virtual void Clear( void ) = 0; virtual void Clear( void ) = 0;
virtual void Shutdown(/* ENetworkDisconnectionReason */ int reason) = 0; virtual void Shutdown(/* ENetworkDisconnectionReason */ int reason) = 0;
virtual bool ProcessDemoPacket( struct netpacket_s* packet ) = 0; virtual bool ProcessDemoPacket( struct netpacket_s* packet ) = 0;
virtual bool InsertReplayMessage( INetMessage *msg ) = 0;
virtual void ProcessPacket( struct netpacket_s* packet, bool bHasHeader ) = 0; virtual void ProcessPacket( struct netpacket_s* packet, bool bHasHeader ) = 0;
virtual bool SendNetMsg(INetMessage &msg, bool bForceReliable = false, bool bVoice = false ) = 0; virtual bool SendNetMsg(INetMessage &msg, bool bForceReliable = false, bool bVoice = false ) = 0;
@ -115,6 +118,9 @@ public:
virtual void SetUsesMaxRoutablePlayload(bool useMax) = 0; virtual void SetUsesMaxRoutablePlayload(bool useMax) = 0;
virtual bool WasLastMessageReliable() const = 0; virtual bool WasLastMessageReliable() const = 0;
virtual void SetPendingDisconnect( int reason ) = 0;
virtual int GetPendingDisconnect() const = 0;
}; };

View File

@ -21,6 +21,8 @@
#define FLOW_INCOMING 1 #define FLOW_INCOMING 1
#define MAX_FLOWS 2 // in & out #define MAX_FLOWS 2 // in & out
struct SNetChannelLatencyStats;
class INetChannelInfo class INetChannelInfo
{ {
public: public:
@ -75,12 +77,9 @@ public:
virtual float GetTimeoutSeconds() const = 0; virtual float GetTimeoutSeconds() const = 0;
virtual float GetPeakLatency( int flow ) const = 0; virtual void ResetLatencyStats( int channel ) = 0;
virtual float GetTotalAvgLatency( int flow ) const = 0; virtual SNetChannelLatencyStats *GetLatencyStats( int channel ) const = 0;
virtual float GetTotalStdDevLatency(int flow ) const = 0; virtual void SetLatencyStats( int channel, const SNetChannelLatencyStats &stats ) = 0;
virtual int GetTotalDropped( int flow ) const = 0;
virtual int GetTotalChoked( int flow ) const = 0;
virtual int GetTotal( int flow ) const = 0;
}; };
#endif // INETCHANNELINFO_H #endif // INETCHANNELINFO_H