feat: implement multiplayer session state management and add invalid port exception
This commit is contained in:
+3
-2
@@ -1,6 +1,7 @@
|
||||
namespace Game.Features.Multiplayer.Contracts.Exceptions;
|
||||
|
||||
/// <summary>
|
||||
/// Thrown when trying to host or join while already connected to a session.
|
||||
/// Thrown when trying to host or join while connecting or already connected to a session.
|
||||
/// </summary>
|
||||
public sealed class MultiplayerAlreadyConnectedException() : MultiplayerException("Already connected to a session.");
|
||||
public sealed class MultiplayerAlreadyConnectedException()
|
||||
: MultiplayerException("Already connected to or connecting with a session.");
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
namespace Game.Features.Multiplayer.Contracts.Exceptions;
|
||||
|
||||
public sealed class MultiplayerInvalidPortException(int port)
|
||||
: MultiplayerException($"Invalid port {port}. Port must be between 1 and 65535.");
|
||||
@@ -0,0 +1 @@
|
||||
uid://d3n8p5w2y7c4h
|
||||
Reference in New Issue
Block a user