mirror of
https://github.com/Mauler125/r5sdk.git
synced 2025-02-09 19:15:03 +01:00
Add function for checking if there's still pending data in reliable waiting buffers
This commit is contained in:
parent
2ff35a94cd
commit
3c36b606f0
@ -157,6 +157,15 @@ bool CNetChan::SendNetMsg(INetMessage& msg, bool bForceReliable, bool bVoice)
|
||||
return true;
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose: check if there is still data in the reliable waiting buffers
|
||||
//-----------------------------------------------------------------------------
|
||||
bool CNetChan::HasPendingReliableData(void)
|
||||
{
|
||||
return (m_StreamReliable.GetNumBitsWritten() > 0)
|
||||
|| (m_WaitingList.Count() > 0);
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
void VNetChan::Attach() const
|
||||
{
|
||||
|
@ -123,6 +123,8 @@ public:
|
||||
inline const netadr_t& GetRemoteAddress(void) const { return remote_address; }
|
||||
inline bool IsOverflowed(void) const { return m_StreamReliable.IsOverflowed(); }
|
||||
|
||||
bool HasPendingReliableData(void);
|
||||
|
||||
inline bool CanPacket(void) const { return v_NetChan_CanPacket(this); }
|
||||
inline int SendDatagram(bf_write* pDatagram) { return v_NetChan_SendDatagram(this, pDatagram); }
|
||||
bool SendNetMsg(INetMessage& msg, bool bForceReliable, bool bVoice);
|
||||
|
Loading…
x
Reference in New Issue
Block a user