mirror of
https://gitlab.com/Syroot/Worms.git
synced 2025-01-27 22:27:58 +03:00
Add StartSingleGame query and reply.
This commit is contained in:
parent
41991d6d78
commit
c33e1f7987
@ -163,6 +163,11 @@ namespace Syroot.Worms.OnlineWorms.Server
|
||||
SendPacket(new ChannelEnterFinishReply());
|
||||
}
|
||||
|
||||
public void HandleStartSingleGameQuery(StartSingleGameQuery packet)
|
||||
{
|
||||
SendPacket(new StartSingleGameReply());
|
||||
}
|
||||
|
||||
#if DEBUG
|
||||
public void HandleRaw(RawPacket packet) { }
|
||||
#endif
|
||||
|
@ -0,0 +1,29 @@
|
||||
using System;
|
||||
using Syroot.BinaryData;
|
||||
|
||||
namespace Syroot.Worms.OnlineWorms.Server.Net
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents the client request for a <see cref="StartSingleGameReply"/>.
|
||||
/// </summary>
|
||||
[Packet(PacketType.Channel, 0x38)]
|
||||
internal class StartSingleGameQuery : Packet
|
||||
{
|
||||
// ---- PROPERTIES ---------------------------------------------------------------------------------------------
|
||||
|
||||
public byte UnknownA { get; set; }
|
||||
public byte UnknownB { get; set; }
|
||||
public byte UnknownC { get; set; }
|
||||
|
||||
// ---- METHODS (INTERNAL) -------------------------------------------------------------------------------------
|
||||
|
||||
internal override void Deserialize(PacketStream stream)
|
||||
{
|
||||
UnknownA = stream.Read1Byte();
|
||||
UnknownB = stream.Read1Byte();
|
||||
UnknownC = stream.Read1Byte();
|
||||
}
|
||||
|
||||
internal override void Serialize(PacketStream stream) => throw new NotImplementedException();
|
||||
}
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
using System;
|
||||
using Syroot.BinaryData;
|
||||
|
||||
namespace Syroot.Worms.OnlineWorms.Server.Net
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents the server response to a <see cref="StartSingleGameQuery"/>.
|
||||
/// </summary>
|
||||
[Packet(PacketType.Channel, 0x39)]
|
||||
internal class StartSingleGameReply : Packet
|
||||
{
|
||||
// ---- PROPERTIES ---------------------------------------------------------------------------------------------
|
||||
|
||||
public bool Success { get; set; } = true;
|
||||
|
||||
// ---- METHODS (INTERNAL) -------------------------------------------------------------------------------------
|
||||
|
||||
internal override void Deserialize(PacketStream stream) => throw new NotImplementedException();
|
||||
|
||||
internal override void Serialize(PacketStream stream)
|
||||
{
|
||||
stream.WriteBoolean(Success, BooleanCoding.Word);
|
||||
}
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user