mirror of
https://gitlab.com/Syroot/Worms.git
synced 2025-01-13 07:18:00 +03:00
Typo
This commit is contained in:
parent
e4104b8309
commit
cc84ed3d5f
@ -11,8 +11,11 @@ namespace Syroot.Worms.Mgame.GameServer
|
||||
{
|
||||
switch (packet.Data)
|
||||
{
|
||||
case StartSingleGameQueryData startSingleGameQuery:
|
||||
HandleWwpaChannelCmdStartGame(startSingleGameQuery);
|
||||
case StartSingleGameQueryData startSingleGame:
|
||||
HandleWwpaChannelCmdStartGame(startSingleGame);
|
||||
break;
|
||||
case Unknown6QueryData unknown6:
|
||||
HandleWwpaChannelCmdUnknown6(unknown6);
|
||||
break;
|
||||
}
|
||||
}
|
||||
@ -75,5 +78,13 @@ namespace Syroot.Worms.Mgame.GameServer
|
||||
}
|
||||
}));
|
||||
}
|
||||
|
||||
private void HandleWwpaChannelCmdUnknown6(Unknown6QueryData unknown6)
|
||||
{
|
||||
SendPacket(new CmdReply(new Unknown6ReplyData
|
||||
{
|
||||
Result = Unknown6Status.Disconnect
|
||||
}));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -52,7 +52,8 @@ namespace Syroot.Worms.Mgame.GameServer.Packets.WorldPartyAqua.Channel
|
||||
|
||||
internal enum Cmd : int
|
||||
{
|
||||
StartSingleGameQuery = 5
|
||||
StartSingleGameQuery = 5,
|
||||
Unknown6 = 6
|
||||
}
|
||||
|
||||
internal interface ICmdData
|
||||
|
@ -13,7 +13,8 @@ namespace Syroot.Worms.Mgame.GameServer.Packets.WorldPartyAqua.Channel
|
||||
|
||||
private static readonly Dictionary<Cmd, Type> _queryClasses = new Dictionary<Cmd, Type>
|
||||
{
|
||||
[Cmd.StartSingleGameQuery] = typeof(StartSingleGameQueryData)
|
||||
[Cmd.StartSingleGameQuery] = typeof(StartSingleGameQueryData),
|
||||
[Cmd.Unknown6] = typeof(Unknown6QueryData)
|
||||
};
|
||||
|
||||
// ---- METHODS (PROTECTED) ------------------------------------------------------------------------------------
|
||||
|
@ -13,7 +13,8 @@ namespace Syroot.Worms.Mgame.GameServer.Packets.WorldPartyAqua.Channel
|
||||
|
||||
private static readonly Dictionary<Cmd, Type> _replyClasses = new Dictionary<Cmd, Type>
|
||||
{
|
||||
[Cmd.StartSingleGameQuery] = typeof(StartSingleGameReplyData)
|
||||
[Cmd.StartSingleGameQuery] = typeof(StartSingleGameReplyData),
|
||||
[Cmd.Unknown6] = typeof(Unknown6ReplyData)
|
||||
};
|
||||
|
||||
// ---- CONSTRUCTORS & DESTRUCTOR ------------------------------------------------------------------------------
|
||||
|
@ -3,7 +3,7 @@
|
||||
namespace Syroot.Worms.Mgame.GameServer.Packets.WorldPartyAqua.Channel
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents the <see cref="ChannelCmdQuery"/> client request for a <see cref="StartSingleGameReplyData"/>.
|
||||
/// Represents the <see cref="CmdQuery"/> client request for a <see cref="StartSingleGameReplyData"/>.
|
||||
/// </summary>
|
||||
internal class StartSingleGameQueryData : ICmdData
|
||||
{
|
||||
|
@ -5,7 +5,7 @@ using Syroot.BinaryData.Memory;
|
||||
namespace Syroot.Worms.Mgame.GameServer.Packets.WorldPartyAqua.Channel
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents the <see cref="ChannelCmdQuery"/> server response to a <see cref="StartSingleGameQueryData"/>.
|
||||
/// Represents the <see cref="CmdQuery"/> server response to a <see cref="StartSingleGameQueryData"/>.
|
||||
/// </summary>
|
||||
internal class StartSingleGameReplyData : ICmdData
|
||||
{
|
||||
|
@ -0,0 +1,27 @@
|
||||
using System.Net;
|
||||
using Syroot.BinaryData.Memory;
|
||||
|
||||
namespace Syroot.Worms.Mgame.GameServer.Packets.WorldPartyAqua.Channel
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents the <see cref="ChannelCmdQuery"/> client request for a <see cref="Unknown6ReplyData"/>.
|
||||
/// </summary>
|
||||
internal class Unknown6QueryData : ICmdData
|
||||
{
|
||||
// ---- PROPERTIES ---------------------------------------------------------------------------------------------
|
||||
|
||||
public int UnknownA { get; set; } // Always 1
|
||||
|
||||
public IPAddress ClientIP { get; set; }
|
||||
|
||||
// ---- METHODS (PUBLIC) ---------------------------------------------------------------------------------------
|
||||
|
||||
public void Load(ref SpanReader reader)
|
||||
{
|
||||
UnknownA = reader.ReadInt32();
|
||||
ClientIP = IPAddress.Parse(reader.ReadString2());
|
||||
}
|
||||
|
||||
public void Save(ref SpanWriter writer) { }
|
||||
}
|
||||
}
|
@ -0,0 +1,35 @@
|
||||
using System;
|
||||
using Syroot.BinaryData.Memory;
|
||||
|
||||
namespace Syroot.Worms.Mgame.GameServer.Packets.WorldPartyAqua.Channel
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents the <see cref="CmdQuery"/> server response to a <see cref="Unknown6QueryData"/>.
|
||||
/// </summary>
|
||||
internal class Unknown6ReplyData : ICmdData
|
||||
{
|
||||
// ---- PROPERTIES ---------------------------------------------------------------------------------------------
|
||||
|
||||
public Unknown6Status Result { get; set; }
|
||||
|
||||
public ushort Port { get; set; } // Unknown2 = x + 6, Unknown3 = x
|
||||
|
||||
// ---- METHODS (PUBLIC) ---------------------------------------------------------------------------------------
|
||||
|
||||
public void Load(ref SpanReader reader) => throw new NotImplementedException();
|
||||
|
||||
public void Save(ref SpanWriter writer)
|
||||
{
|
||||
writer.WriteEnumSafe(Result);
|
||||
if (Result != Unknown6Status.Disconnect)
|
||||
writer.WriteUInt16(Port);
|
||||
}
|
||||
}
|
||||
|
||||
internal enum Unknown6Status : int
|
||||
{
|
||||
Unknown2 = 2,
|
||||
Unknown3 = 3,
|
||||
Disconnect = 4
|
||||
}
|
||||
}
|
@ -1,7 +1,7 @@
|
||||
namespace Syroot.Worms.Core
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents mathemtical helper utilities.
|
||||
/// Represents mathematical helper utilities.
|
||||
/// </summary>
|
||||
public static class Algebra
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user