diff options
Diffstat (limited to 'Impostor-dev/src/Impostor.Hazel/NewConnectionEventArgs.cs')
-rw-r--r-- | Impostor-dev/src/Impostor.Hazel/NewConnectionEventArgs.cs | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/Impostor-dev/src/Impostor.Hazel/NewConnectionEventArgs.cs b/Impostor-dev/src/Impostor.Hazel/NewConnectionEventArgs.cs new file mode 100644 index 0000000..be9e7a2 --- /dev/null +++ b/Impostor-dev/src/Impostor.Hazel/NewConnectionEventArgs.cs @@ -0,0 +1,24 @@ +using Impostor.Api.Net.Messages; + +namespace Impostor.Hazel +{ + public struct NewConnectionEventArgs + { + /// <summary> + /// The data received from the client in the handshake. + /// This data is yours. Remember to recycle it. + /// </summary> + public readonly IMessageReader HandshakeData; + + /// <summary> + /// The <see cref="Connection"/> to the new client. + /// </summary> + public readonly Connection Connection; + + public NewConnectionEventArgs(IMessageReader handshakeData, Connection connection) + { + this.HandshakeData = handshakeData; + this.Connection = connection; + } + } +} |