Valhalla Legends Forums Archive | Battle.net Bot Development | C++ bot requirments

AuthorMessageTime
MoNksBaNe_Agahnim
I know some C++, can do some stuff lol, what are some C++ knowledge requirements to make the simplest of the simple bot, like a public chatroom, chat only bot? lol...such as you need to know apstrings, arrays, pointers, ect... ect...
October 11, 2003, 1:13 AM
Grok
The simplest of simple bots would be notepad or some other text editor. It wouldn't be required to connect to anything, or even have multiple windows. You could just talk to yourself.
October 11, 2003, 1:58 AM
Adron
[quote author=MoNksBaNe_Agahnim link=board=17;threadid=3032;start=0#msg23732 date=1065834799]
I know some C++, can do some stuff lol, what are some C++ knowledge requirements to make the simplest of the simple bot, like a public chatroom, chat only bot? lol...such as you need to know apstrings, arrays, pointers, ect... ect...
[/quote]

Writing a "main", doing a tcp connection, processing strings (either C-style char arrays or some C++ string class, but something that can be read from/written to a tcp socket).

Not c++, but:

char login[] = "\x3username\npassword\n";

main()
{ int s = socket(AF_INET, SOCK_STREAM, 0);
struct sockaddr_in sin;
sin.sin_family = AF_INET;
sin.sin_port = htons(6112);
sin.sin_addr.s_addr = inet_addr("some.bnet.ip.address");
connect(s, &sin, sizeof sin);
send(s, login, sizeof login - 1, 0);
while(1) {
char c;
recv(s, &c, 1, 0);
putchar(c);
}
}
October 11, 2003, 2:07 AM
iago
I would read Yoni's post about a couple simple programs to write to learn winsock. If I knew where it was I'd reference it, but it's somewhere on this forum :)
October 11, 2003, 2:59 AM

Search