コード例 #1
0
ファイル: Main.cs プロジェクト: baburukiri/AOSharp
        private int Send_Hook(IntPtr pConnection, uint unk, int len, byte[] buf)
        {
            try
            {
                if (_pluginProxy != null)
                {
                    _pluginProxy.SentPacket(buf);
                }
            }
            catch (Exception) { }

            return(Connection_t.Send(pConnection, unk, len, buf));
        }
コード例 #2
0
        public static unsafe void Send(byte[] payload)
        {
            IntPtr pClient = Client_t.GetInstanceIfAny();

            if (pClient == IntPtr.Zero)
            {
                return;
            }

            IntPtr pConnection = *(IntPtr *)(pClient + 0x84);

            if (pConnection == IntPtr.Zero)
            {
                return;
            }

            Connection_t.Send(pConnection, 0, payload.Length, payload);
        }