2024-11-03 16:42:23 +08:00
|
|
|
using kcp2k;
|
|
|
|
|
|
|
|
namespace BITKit.Net
|
|
|
|
{
|
|
|
|
public class KCPNet
|
|
|
|
{
|
|
|
|
public static readonly KcpConfig Config = new KcpConfig(
|
|
|
|
NoDelay: true,
|
|
|
|
DualMode: false,
|
2025-02-24 23:03:39 +08:00
|
|
|
Interval: 1, // 1ms so at interval code at least runs.
|
2024-11-03 16:42:23 +08:00
|
|
|
Timeout: 8000,
|
|
|
|
CongestionWindow: false
|
|
|
|
)
|
|
|
|
{
|
|
|
|
SendWindowSize = Kcp.WND_SND * 1000,
|
|
|
|
ReceiveWindowSize = Kcp.WND_RCV * 1000,
|
|
|
|
CongestionWindow= false,
|
|
|
|
MaxRetransmits = Kcp.DEADLINK * 2
|
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|