1
This commit is contained in:
@@ -18,6 +18,7 @@ namespace BITKit.Net
|
||||
{
|
||||
public class KCPNetServer:INetServer,INetProvider
|
||||
{
|
||||
public int TickRate { get; set; }
|
||||
public bool ManualTick { get; set; }
|
||||
public event Action<int> OnClientConnected;
|
||||
public event Action<int> OnClientDisconnected;
|
||||
@@ -80,6 +81,10 @@ namespace BITKit.Net
|
||||
{
|
||||
if (IsRunningServer is false)
|
||||
{
|
||||
if (TickRate > 0)
|
||||
{
|
||||
_timer.Interval = 1000f / TickRate;
|
||||
}
|
||||
OnStartServer?.Invoke();
|
||||
server.Start(port);
|
||||
_timer.Start();
|
||||
|
Reference in New Issue
Block a user