public static void ParsePacketFromHexString <PacketType>(string hex) { var msg = new Message(DateTime.Now, MessageDirection.ServerToClient, new ArraySegment <byte>(hex.ToByteArrayHex())); var fac = new MessageFactory(); var del = MessageFactory.Contructor <Func <TeraMessageReader, PacketType> >(); var reader = new TeraMessageReader(msg, null, fac, null); del.DynamicInvoke(reader); }