• Welcome to Valhalla Legends Archive.
 

getting started with c++

Started by Laff, April 18, 2003, 12:34 AM

Previous topic - Next topic

Laff

yeh so i've decided to do a VERY basic chat bot for my term project in my gui class this term.  by very basic i mean i want code to connect to the server, do minimal things, and slap an interface on it.  however i can't find anything that i can actually get to compile in vs.net.  anyone wanna help me out here?  please don't give me vb code, as i did that like 5 years ago and i don't need to see it again.  =/

thanks in advance!

laff

Skywing

Quote from: Laff on April 18, 2003, 12:34 AM
yeh so i've decided to do a VERY basic chat bot for my term project in my gui class this term.  by very basic i mean i want code to connect to the server, do minimal things, and slap an interface on it.  however i can't find anything that i can actually get to compile in vs.net.  anyone wanna help me out here?  please don't give me vb code, as i did that like 5 years ago and i don't need to see it again.  =/

thanks in advance!

laff
Are you using managed (.NET) C++, or standard C++?

The following assumes you're using Win32/standard C++:

Since these files are becoming increasingly difficult to find (Blizzard's cleared out GreetBot from their FTP after just over 5 years), I've decided to mirror them.

The original GreetBot, written by Scott Coleman in March of 1998.
Rabidmouse's MFC mod of GreetBot, written in May of 1998.

Since these can still be found without too much digging, I'd recommend you not just wholesale copy and paste code, but use them as a reference.

Laff

thanks but i can get neither of those to work.  greetbot never connects (assuming the log is correct) and winbot sits there and does nothing.  brings up the window and thats it.  anything else you can offer?

Skywing

Quote from: Laff on April 18, 2003, 11:04 AM
thanks but i can get neither of those to work.  greetbot never connects (assuming the log is correct) and winbot sits there and does nothing.  brings up the window and thats it.  anything else you can offer?
Battle.net no longer supports Guest logons, and the server address might be incorrect (you cannot log in as chat by connecting to "battle.net", try "exodus.battle.net" for compatibility -- Blizzard will have to support exodus.battle.net indefinitely, because it's the only hostname present in the server list for Starcraft/Diablo retail (1.00 from CD).

Laff

#4
well here's what i tried.  i made a new account on lordaeron (uswest) and put that info in as my login.  still did nothing.  i would try your exodus idea, although i don't have sc or diablo so i don't know how i'm supposed to get an account ;)

Skywing

Quote from: Laff on April 18, 2003, 11:41 AM
well here's what i tried.  i made a new account on lordaeron (uswest) and put that info in as my login.  still did nothing.  i would try your exodus idea, although i don't have sc or diablo so i don't know how i'm supposed to get an account ;)
You can't use Warcraft III accounts from a Chat connection.  The only valid username if you don't have an account is 'Anonymous'; however, the server doesn't prompt for a password for this account, so the 'password' you send will be treated as a normal text message by the server (try setting it to something like /whoami).

Laff

sweet it works with Anonymous, but how can i get an account.  why wouldn't the war3 accounts work if i'm connecting to uswest.battle.net?  what about a diablo2 account?  i could always just use my brothers sc to make an account on exodus i suppose...ideas?  thanks for the help too!

Skywing

Quote from: Laff on April 18, 2003, 12:01 PM
sweet it works with Anonymous, but how can i get an account.  why wouldn't the war3 accounts work if i'm connecting to uswest.battle.net?  what about a diablo2 account?  i could always just use my brothers sc to make an account on exodus i suppose...ideas?  thanks for the help too!
Warcraft III accounts cannot be used because they are on a seperate namespace.  Chat, Diablo, Starcraft, Brood War, Warcraft II: BNE, Diablo II, and Lord of Destruction all share the same namespace.

Laff

so what you're saying is i can use broodwar, make an account, then use it for my bot?

also another question: i've heard that bots can only be in public channels and blizzard tech support now.  true?  any way around that (i'm guessing that's what the 'binary bots' are that i'm hearing about, and that they supply the server with cdkey and all that goodness.  i'm betting that's a bitch and outside the scope of this project.  after all, it's a gui class not a networking class ;) )

Skywing

#9
Quote from: Laff on April 18, 2003, 02:12 PM
so what you're saying is i can use broodwar, make an account, then use it for my bot?
Yes.
Quote from: Laff on April 18, 2003, 02:12 PMalso another question: i've heard that bots can only be in public channels and blizzard tech support now.  true?
Yes, for non-sysop chatbots this is the case.
Quote from: Laff on April 18, 2003, 02:12 PMany way around that (i'm guessing that's what the 'binary bots' are that i'm hearing about, and that they supply the server with cdkey and all that goodness.
Yes.
Quote from: Laff on April 18, 2003, 02:12 PMi'm betting that's a bitch and outside the scope of this project.
Yes, unless you rip the vast majority of your code from somebody else, which would probably be frowned upon for a programming class project.
Quote from: Laff on April 18, 2003, 02:12 PMafter all, it's a gui class not a networking class ;) )

Laff

then it's all good being limited, because i already know how to do that ;)