using System.IO;

namespace Crysome.Common.Network.Packets;

public class ChatMessagePacket : IPacket
{
	public string Message { get; set; } = "";

	public ChatMessagePacket()
	{
	}

	public ChatMessagePacket(string message)
	{
		Message = message ?? "";
	}

	public void Write(BinaryWriter w)
	{
		w.Write(Message ?? "");
	}

	public void Read(BinaryReader r)
	{
		Message = r.ReadString();
	}
}
