diff options
author | Lee Salzman <[email protected]> | 2020-04-04 12:30:54 -0400 |
---|---|---|
committer | Lee Salzman <[email protected]> | 2020-04-04 12:30:54 -0400 |
commit | 6991632abf1af161f332bf38bd8517c7c2834b58 (patch) | |
tree | 9cfb3a997a2ebe2d5ccbfe3d048b6ba7d4334b20 /include | |
parent | b4c427059aa39ce42ae4c82afcfe617dea255c4d (diff) | |
download | enet-6991632abf1af161f332bf38bd8517c7c2834b58.tar.gz enet-6991632abf1af161f332bf38bd8517c7c2834b58.zip |
accumulate fractional RTT values
Diffstat (limited to 'include')
-rw-r--r-- | include/enet/enet.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/include/enet/enet.h b/include/enet/enet.h index 4a704ee..174e062 100644 --- a/include/enet/enet.h +++ b/include/enet/enet.h @@ -216,7 +216,7 @@ enum ENET_HOST_DEFAULT_MAXIMUM_PACKET_SIZE = 32 * 1024 * 1024, ENET_HOST_DEFAULT_MAXIMUM_WAITING_DATA = 32 * 1024 * 1024, - ENET_PEER_DEFAULT_ROUND_TRIP_TIME = 500, + ENET_PEER_DEFAULT_ROUND_TRIP_TIME = 350, ENET_PEER_DEFAULT_PACKET_THROTTLE = 32, ENET_PEER_PACKET_THROTTLE_SCALE = 32, ENET_PEER_PACKET_THROTTLE_COUNTER = 7, @@ -250,6 +250,11 @@ typedef struct _ENetChannel ENetList incomingUnreliableCommands; } ENetChannel; +typedef enum _ENetPeerFlag +{ + ENET_PEER_FLAG_NEEDS_DISPATCH = (1 << 0) +} ENetPeerFlag; + /** * An ENet peer which data packets may be sent or received from. * @@ -311,7 +316,9 @@ typedef struct _ENetPeer ENetList outgoingReliableCommands; ENetList outgoingUnreliableCommands; ENetList dispatchedCommands; - int needsDispatch; + enet_uint16 flags; + enet_uint8 roundTripTimeRemainder; + enet_uint8 roundTripTimeVarianceRemainder; enet_uint16 incomingUnsequencedGroup; enet_uint16 outgoingUnsequencedGroup; enet_uint32 unsequencedWindow [ENET_PEER_UNSEQUENCED_WINDOW_SIZE / 32]; |