Development:Network:process trade items equip

From Ghoulwiki
Jump to: navigation, search

example packetlogs

parsed : buy&sell, tradegoods and equip:

-- packetlogs/buy.c // buy 10x nature>food>rlaan>nutripack for 141.46 each. credits afterwards: 12085.43
Packet({from=client,cmd=CMD_CARGOUPGRADE,head={{len=52,pri=1,flags=0x0},{cmd=41,serial=165,datalen=36,flags=0x0}}})
Packet({from=server,cmd=CMD_CREDITS,head={{len=21,pri=1,flags=0x7a},{cmd=42,serial=165,datalen=5,flags=0x0}}})
Packet({from=server,cmd=CMD_CARGOUPGRADE,head={{len=67,pri=1,flags=0x7a},{cmd=41,serial=165,datalen=51,flags=0x0}}})

-- packetlogs/sell.c // sell 10x nature>food>rlaan>nutripack for 141.46 each. credits afterwards: 13500
Packet({from=client,cmd=CMD_CARGOUPGRADE,head={{len=52,pri=1,flags=0x0},{cmd=41,serial=165,datalen=36,flags=0x0}}})
Packet({from=server,cmd=CMD_CREDITS,head={{len=21,pri=1,flags=0x7a},{cmd=42,serial=165,datalen=5,flags=0x0}}})
Packet({from=server,cmd=CMD_CARGOUPGRADE,head={{len=67,pri=1,flags=0x7a},{cmd=41,serial=165,datalen=51,flags=0x0}}})

-- packetlogs/buy-equip.c // buy equip: overdrive
Packet({from=client,cmd=CMD_CARGOUPGRADE,head={{len=59,pri=1,flags=0x0},{cmd=41,serial=165,datalen=43,flags=0x0}}})
Packet({from=client,cmd=CMD_CARGOUPGRADE,head={{len=59,pri=1,flags=0x0},{cmd=41,serial=165,datalen=43,flags=0x0}}})
Packet({from=server,cmd=CMD_CREDITS,head={{len=21,pri=1,flags=0x7a},{cmd=42,serial=165,datalen=5,flags=0x0}}})
Packet({from=server,cmd=CMD_CARGOUPGRADE,head={{len=74,pri=1,flags=0x7a},{cmd=41,serial=165,datalen=58,flags=0x0}}})
Packet({from=server,cmd=CMD_CREDITS,head={{len=21,pri=1,flags=0x7a},{cmd=42,serial=165,datalen=5,flags=0x0}}})

-- packetlogs/sell-equip.c // sell equip: overdrive
Packet({from=client,cmd=CMD_CARGOUPGRADE,head={{len=59,pri=1,flags=0x0},{cmd=41,serial=165,datalen=43,flags=0x0}}})
Packet({from=server,cmd=CMD_CREDITS,head={{len=21,pri=1,flags=0x7a},{cmd=42,serial=165,datalen=5,flags=0x0}}})
Packet({from=server,cmd=CMD_CARGOUPGRADE,head={{len=74,pri=1,flags=0x7a},{cmd=41,serial=165,datalen=58,flags=0x0}}})

wireshark : buy

// buy 10x nature>food>rlaan>nutripack for 141.46 each. credits afterwards: 12085.43
// peer0_0 = client > server
char peer0_0[] = {
0x00, 0x00, 0x00, 0x34, 0x01, 0x00, 0x00, 0x00 };
char peer0_1[] = {
0x29, 0x82, 0x00, 0xa5, 0x78, 0x2f, 0x91, 0xfd, 
0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, 0x00, 
0xbd, 0xbc, 0x00, 0xa5, 0xbd, 0xbc, 0x00, 0x00, 
0xbe, 0x00, 0x00, 0x00, 0x0a, 0x21, 0xbc, 0x00, 
0x09, 0x4e, 0x75, 0x74, 0x72, 0x69, 0x70, 0x61, 
0x63, 0x6b, 0xbe, 0x00, 0x00, 0x00, 0x00, 0xbe, 
0x00, 0x00, 0x00, 0x00 };
char peer1_0[] = {
0x00, 0x00, 0x00, 0x15, 0x01, 0x00, 0x7a, 0x09 };
char peer1_1[] = {
0x2a, 0x94, 0x00, 0xa5, 0x78, 0x2f, 0x92, 0x49, 
0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x70, 0x68, 
0x7b, 0x46, 0x3c, 0xd5, 0xb6, 0x00, 0x00, 0x00, 
0x43, 0x01, 0x00, 0x7a, 0x09, 0x29, 0x94, 0x00, 
0xa5, 0x78, 0x2f, 0x92, 0x49, 0x00, 0x00, 0x00, 
0x33, 0x00, 0x00, 0x6d, 0x0d, 0xbd, 0xbc, 0x00, 
0xa5, 0xbd, 0xbc, 0x00, 0x5a, 0xbe, 0x00, 0x00, 
0x00, 0x0a, 0x21, 0xbc, 0x00, 0x09, 0x4e, 0x75, 
0x74, 0x72, 0x69, 0x70, 0x61, 0x63, 0x6b, 0x7b, 
0x43, 0x0d, 0x75, 0x0f, 0x7b, 0x3f, 0x66, 0x66, 
0x66, 0x7b, 0x3f, 0x80, 0x00, 0x00, 0xbe, 0x00, 
0x00, 0x00, 0x00, 0xbe, 0x00, 0x00, 0x00, 0x00 };

wireshark : sell

// sell 10x nature>food>rlaan>nutripack for 141.46 each. credits afterwards: 13500
// peer0_0 = client > server
char peer0_0[] = {
0x00, 0x00, 0x00, 0x34, 0x01, 0x00, 0x00, 0x00 };
char peer0_1[] = {
0x29, 0x82, 0x00, 0xa5, 0x78, 0x35, 0x0d, 0x36, 
0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, 0x00, 
0xbd, 0xbc, 0x00, 0x00, 0xbd, 0xbc, 0x00, 0xa5, 
0xbe, 0x00, 0x00, 0x00, 0x0a, 0x21, 0xbc, 0x00, 
0x09, 0x4e, 0x75, 0x74, 0x72, 0x69, 0x70, 0x61, 
0x63, 0x6b, 0xbe, 0x00, 0x00, 0x00, 0x00, 0xbe, 
0x00, 0x00, 0x00, 0x00 };
char peer1_0[] = {
0x00, 0x00, 0x00, 0x15, 0x01, 0x00, 0x7a, 0x09 };
char peer1_1[] = {
0x2a, 0x94, 0x00, 0xa5, 0x78, 0x35, 0x0d, 0x85, 
0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x75, 0x63, 
0x7b, 0x46, 0x52, 0xf0, 0x00, 0x00, 0x00, 0x00, 
0x43, 0x01, 0x00, 0x7a, 0x09, 0x29, 0x94, 0x00, 
0xa5, 0x78, 0x35, 0x0d, 0x85, 0x00, 0x00, 0x00, 
0x33, 0x00, 0x00, 0x00, 0x00, 0xbd, 0xbc, 0x00, 
0x5a, 0xbd, 0xbc, 0x00, 0xa5, 0xbe, 0x00, 0x00, 
0x00, 0x0a, 0x21, 0xbc, 0x00, 0x09, 0x4e, 0x75, 
0x74, 0x72, 0x69, 0x70, 0x61, 0x63, 0x6b, 0x7b, 
0x43, 0x0d, 0x75, 0x0f, 0x7b, 0x3f, 0x66, 0x66, 
0x66, 0x7b, 0x3f, 0x80, 0x00, 0x00, 0xbe, 0x00, 
0x00, 0x00, 0x00, 0xbe, 0x00, 0x00, 0x00, 0x00 };