mirror of
https://github.com/MikuLeaks/KianaBH3.git
synced 2025-12-14 05:44:34 +01:00
Init enter game
This commit is contained in:
30
KcpSharp/Base/KcpReceiveWindowNotificationOptions.cs
Normal file
30
KcpSharp/Base/KcpReceiveWindowNotificationOptions.cs
Normal file
@@ -0,0 +1,30 @@
|
||||
namespace KianaBH.KcpSharp.Base;
|
||||
|
||||
/// <summary>
|
||||
/// Options for sending receive window size notification.
|
||||
/// </summary>
|
||||
public sealed class KcpReceiveWindowNotificationOptions
|
||||
{
|
||||
/// <summary>
|
||||
/// Create an instance of option object for receive window size notification functionality.
|
||||
/// </summary>
|
||||
/// <param name="initialInterval">The initial interval in milliseconds of sending window size notification.</param>
|
||||
/// <param name="maximumInterval">The maximum interval in milliseconds of sending window size notification.</param>
|
||||
public KcpReceiveWindowNotificationOptions(int initialInterval, int maximumInterval)
|
||||
{
|
||||
if (initialInterval <= 0) throw new ArgumentOutOfRangeException(nameof(initialInterval));
|
||||
if (maximumInterval < initialInterval) throw new ArgumentOutOfRangeException(nameof(maximumInterval));
|
||||
InitialInterval = initialInterval;
|
||||
MaximumInterval = maximumInterval;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The initial interval in milliseconds of sending window size notification.
|
||||
/// </summary>
|
||||
public int InitialInterval { get; }
|
||||
|
||||
/// <summary>
|
||||
/// The maximum interval in milliseconds of sending window size notification.
|
||||
/// </summary>
|
||||
public int MaximumInterval { get; }
|
||||
}
|
||||
Reference in New Issue
Block a user