Make sure everythings init correctly on boot
This commit is contained in:
1 parent
f946ebef1e
commit
3464e93aee
3 files changed
+3
-4
No files matched your search
@@ -9,7 +9,7 @@ namespace Mistox.Client {
|
||||
|
||||
public string UserName { get; set; } = ""; // The remote players UserName
|
||||
public bool WithinRange { get; set; } = true; // Is the user close enough?
|
||||
public Vector3 Position { get; set; } // The remote location of the player
|
||||
public Vector3 Position { get; set; } = new Vector3(0, 0, 0); // The remote location of the player
|
||||
|
||||
private IPEndPoint _remoteHost { get; set; } // The remote IP Address
|
||||
private readonly SemaphoreSlim _sendLock = new SemaphoreSlim(1, 1);
|
||||
|
||||
@@ -15,12 +15,11 @@ namespace Mistox.Server {
|
||||
public string ConnectionKey { get; set; } = ""; // The connection key for the server
|
||||
public int ConnectionTimeoutSeconds { get; set; } = 10; // If no reply in time kill the connection
|
||||
public bool Alive { get; set; } = true; // Is the server running
|
||||
public ConcurrentDictionary<string, ServerConnection> Connections; // All the active connections. key is username
|
||||
public ConcurrentDictionary<string, ServerConnection> Connections = new(); // All the active connections. key is username
|
||||
|
||||
private readonly ServerListener Listener; // The Connection Listener singleton
|
||||
|
||||
public MistoxServer(IPEndPoint ListenerAddress, string serverName) {
|
||||
Connections = new ConcurrentDictionary<string, ServerConnection>();
|
||||
ServerName = serverName;
|
||||
Listener = new ServerListener(ListenerAddress, this);
|
||||
Console.WriteLine( "The Server is initilized and waiting for clients to connect at port : " + ListenerAddress.Port );
|
||||
|
||||
@@ -10,7 +10,7 @@ namespace Mistox.Server {
|
||||
|
||||
public string UserName { get; set; } = ""; // The Players UserName
|
||||
public bool IsAuthenticated { get; set; } = false; // Has the player authenticated
|
||||
public Vector3 Position { get; set; } // The ingame position of the player
|
||||
public Vector3 Position { get; set; } = new Vector3(0, 0, 0); // The ingame position of the player
|
||||
public bool Connected { get; set; } = true; // Is the connection valid
|
||||
|
||||
private readonly MistoxServer _parent;
|
||||
|
||||
Reference in new issue
Block a user