Nice
The trade hack I do a little differently, although I cant fully understand what you mean in your example so might be the same
the format of packet 0x1C is [num items to trade (1byte), [item id(4bytes), count(4bytes)], ...(list of item-count pairs)]
so, submit the first 0x1C packet containing any number of times (real packet)
[0x1c, 0x02, 0xaa, 0xaa, 0xaa, 0xaa, 0xbb, 0xbb, 0xbb, 0xbb, 0xcc, 0xcc, 0xcc, 0xcc, 0xdd, 0xdd, 0xdd, 0xdd]
a is item 1 id, b is item 1 count, c is item 2 id, d is item 2 count.
now submit the packet again, except with the first item being invalid (fake packet)
[0x1c, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xaa, 0xaa, 0xaa, 0xaa, 0xbb, 0xbb, 0xbb, 0xbb, 0xcc, 0xcc, 0xcc, 0xcc, 0xdd, 0xdd, 0xdd, 0xdd]
(i.e. the id and count of the first item are 0)
Other person sees items from first packet, but second packet invalidates the trade ^^