public static SenderPackets readFromMessage(NetIncomingMessage msg) { string s = msg.ReadString(); SenderPackets packet = new SenderPackets(s); return(packet); }
/// <summary> /// Read this from an outgoing message. /// </summary> /// <param name="msg"></param> public static PacketInfo readFromMessage(NetIncomingMessage msg) { PacketInfo info = new PacketInfo(); info.sender = SenderPackets.readFromMessage(msg); info.clientPacket = ClientPacketTypes.readFromMessage(msg); info.serverPacket = ServerPacketTypes.readFromMessage(msg); return(info); }
public PacketInfo(SenderPackets Sender, Packets.ClientPacketTypes ClientPacket, Packets.Server.ServerPacketTypes ServerPacket) { this.sender = Sender; this.clientPacket = ClientPacket; this.serverPacket = ServerPacket; }