printf("- NUM-LOBBIES 1\n"); if(ea_send(NULL, clntSock, "LLST", 0x00000000, "TID=3\n" "NUM-LOBBIES=1\n") < 0) goto quit; printf("- send\n"); printf("- PASSING 3564\n"); if(ea_send(NULL, clntSock, "LDAT", 0x00000000, "PASSING=3564\n" "NAME=bfbc2PC01\n" "LOCALE=en_US\n" "TID=3\n" "MAX-GAMES=10000\n" "NUM-GAMES=3564\n" "FAVORITE-GAMES=0\n" "FAVORITE-PLAYERS=0\n" "LID=257") < 0) goto quit; printf("- send\n"); printf("- PASSING 3584\n"); if(ea_send(NULL, clntSock, "LDAT", 0x00000000, "PASSING=3584\n" "NAME=bfbc2PC02\n" "LOCALE=en_US\n" "TID=3\n" "MAX-GAMES=10000\n" "NUM-GAMES=3584\n" "FAVORITE-GAMES=0\n" "FAVORITE-PLAYERS=0\n" "LID=257") < 0) goto quit; printf("- send\n"); } else if(TXN_CMP("4")) { printf("- LOBBY-NUM-GAMES 3564\n"); if(ea_send(NULL, clntSock, "GLST", 0x00000000, "TID=4\n" "LOBBY-NUM-GAMES=3564\n" "NUM-GAMES=1\n" "LID=257\n" "LOBBY-MAX-GAMES=10000\n", tids) < 0) goto quit; printf("- send\n"); printf("- Evil Source Test\n"); if(ea_send(NULL, clntSock, "GDAT", 0x00000000, "JP=0\n" "F=1\n" "HN=bfbc2.server.p\n" "B-U-level=Levels/MP_009\n" "B-U-sguid=1441225354\n" "N=\"evil source test\"\n" "B-U-Provider=10EFF65140DCA73469821EB23DF628484F443F5A0897965D\n" "I=24.21.184.6\n" "J=O\n" "HU=224444376\n" "B-U-Time=\n" "V=2.0\n" "B-U-gamemode=RUSH\n" "P=19567\n" "B-U-Hardcore=0\n" "B-U-hash=0E5FC634-A463-7641-407D-F93F429DE259\n" "B-U-Softcore=0\n" "B-numObservers=0\n" "TYPE=G\n" "LID=257\n" "B-version=ROMEPC537026\n" "B-U-QueueLength=0\n" "B-U-region=US\n" "B-U-HasPassword=0\n" "QP=0\n" "MP=32\n" "GID=101734\n" "B-U-public=1\n" "B-U-EA=0\n" "B-U-Punkbuster=1\n" "NF=0\n" "PL=PC\n" "B-U-elo=1000\n" "B-maxObservers=0\n" "PW=0\n" "TID=4\n" "AP=0\n", txn) < 0) goto quit; printf("- send\n"); else if(TXN_CMP("5")) { printf("- LOBBY-NUM-GAMES=3384\n"); if(ea_send(NULL, clntSock, "GLST", 0x00000000, "TID=5\n" "LOBBY-NUM-GAMES=3384\n" "NUM-GAMES=0\n" "LID=257\n" "LOBBY-MAX-GAMES=10000\n") < 0) goto quit; printf("- send\n"); } else if(TXN_CMP("6")) { printf("- LOBBY-NUM-GAMES=3384 #2\n"); if(ea_send(NULL, clntSock, "GLST", 0x00000000, "TID=6\n" "LOBBY-NUM-GAMES=3384\n" "NUM-GAMES=0\n" "LID=257\n" "LOBBY-MAX-GAMES=10000\n") < 0) goto quit; printf("- send\n"); printf("- Evil Source Test\n"); if(ea_send(NULL, clntSock, "GDAT", 0x00000000, "JP=0\n" "F=1\n" "HN=bfbc2.server.p\n" "B-U-level=Levels/MP_009\n" "B-U-sguid=1441225354\n" "N=\"evil source test\"\n" "B-U-Provider=10EFF65140DCA73469821EB23DF628484F443F5A0897965D\n" "I=24.21.184.6\n" "J=O\n" "HU=224444376\n" "B-U-Time=\n" "V=2.0\n" "B-U-gamemode=RUSH\n" "P=19567\n" "B-U-Hardcore=0\n" "B-U-hash=0E5FC634-A463-7641-407D-F93F429DE259\n" "B-U-Softcore=0\n" "B-numObservers=0\n" "TYPE=G\n" "LID=257\n" "B-version=ROMEPC537026\n" "B-U-QueueLength=0\n" "B-U-region=US\n" "B-U-HasPassword=0\n" "QP=0\n" "MP=32\n" "GID=101734\n" "B-U-public=1\n" "B-U-EA=0\n" "B-U-Punkbuster=1\n" "NF=0\n" "PL=PC\n" "B-U-elo=1000\n" "B-maxObservers=0\n" "PW=0\n" "TID=4\n" "AP=0\n", txn) < 0) goto quit; printf("- send\n"); } game = get_ea_value(buff, len,"GID"); if(!game) continue; #define GAM_CMP(X) (!stricmp(game, X) || !stricmp(game, "Nu"X)) if(GAM_CMP("101734")) { printf("- join Evil Source Test\n"); if(ea_send(NULL, clntSock, "GLST", 0x00000000, "TID=%s\n" "LOBBY-NUM-GAMES=3384\n" "NUM-GAMES=0\n" "LID=257\n" "LOBBY-MAX-GAMES=10000\n", tids) < 0) goto quit; printf("- send\n"); } game = get_ea_value(buff, len,"PTYPE"); if(!game) continue; #define GAM_CMP(X) (!stricmp(game, X) || !stricmp(game, "Nu"X)) if(GAM_CMP("P")) { printf("- join Evil Source Test #2\n"); if(ea_send(NULL, clntSock, "EGAM", 0x00000000, "TID=%s\n" "LID=257\n" "GID=101734\n", tids) < 0) goto quit; printf("- send\n"); printf("- join Evil Source Test #3\n"); if(ea_send(NULL, clntSock, "EGEG", 0x00000000, "PL=pc\n" "TICKET=-528277070\n" "PID=30\n" "P=19567\n" "HUID=224444376\n" "INT-PORT=19567\n" "EKEY=QuxSleYFGV2NoGrjTo4V+g\n" "INT-IP=24.21.184.6\n" "UGID=f2d96343-d17f-4051-ac8f-d51ea32c51bb\n" "I=24.21.184.6\n" "LID=257\n" "GID=101734\n", tids) < 0) goto quit; printf("- send\n"); } if(txn > 4) { game = get_ea_value(buff, len, "FILTER-FAV-ONLY"); if(GAM_CMP("0")) { printf("- LOBBY-NUM-GAMES 3564\n"); if(ea_send(NULL, clntSock, "GLST", 0x00000000, "TID=4\n" "LOBBY-NUM-GAMES=3564\n" "NUM-GAMES=1\n" "LID=257\n" "LOBBY-MAX-GAMES=10000\n", txn) < 0) goto quit; printf("- Evil Source Test\n"); if(ea_send(NULL, clntSock, "GDAT", 0x00000000, "JP=0\n" "F=1\n" "HN=bfbc2.server.p\n" "B-U-level=Levels/MP_009\n" "B-U-sguid=1441225354\n" "N=\"evil source test\"\n" "B-U-Provider=10EFF65140DCA73469821EB23DF628484F443F5A0897965D\n" "I=24.21.184.6\n" "J=O\n" "HU=224444376\n" "B-U-Time=\n" "V=2.0\n" "B-U-gamemode=RUSH\n" "P=19567\n" "B-U-Hardcore=0\n" "B-U-hash=0E5FC634-A463-7641-407D-F93F429DE259\n" "B-U-Softcore=0\n" "B-numObservers=0\n" "TYPE=G\n" "LID=257\n" "B-version=ROMEPC537026\n" "B-U-QueueLength=0\n" "B-U-region=US\n" "B-U-HasPassword=0\n" "QP=0\n" "MP=32\n" "GID=101734\n" "B-U-public=1\n" "B-U-EA=0\n" "B-U-Punkbuster=1\n" "NF=0\n" "PL=PC\n" "B-U-elo=1000\n" "B-maxObservers=0\n" "PW=0\n" "TID=4\n" "AP=0\n", txn) < 0) goto quit; } }