Valhalla Legends Archive

Programming => Battle.net Bot Development => Topic started by: Freeware on November 08, 2003, 05:06 PM

Title: Client Key? (GTC)
Post by: Freeware on November 08, 2003, 05:06 PM
I have really never understood what the Client Key (GTC) is. Using BNLS, BNLS returns the GTC for you to use. However, in some bots, the GTC is hardcoded as 'GTC = 2140859764'. Can anybody really explain what this is?
Title: Re:Client Key? (GTC)
Post by: CupHead on November 08, 2003, 05:20 PM
GTC means GetTickCount, which is a function in kernel32.  It returns a long value containing the number of milliseconds since the system was started.
Title: Re:Client Key? (GTC)
Post by: Freeware on November 08, 2003, 05:21 PM
Quote from: CupHead on November 08, 2003, 05:20 PM
GTC means GetTickCount, which is a function in kernel32.  It returns a long value containing the number of milliseconds since the system was started.

So you can use any random number in it and Battle.Net will still function?
Title: Re:Client Key? (GTC)
Post by: Tuberload on November 08, 2003, 05:34 PM
It would probably be better if you just made use of the GetTickCount() method.
Title: Re:Client Key? (GTC)
Post by: Spht on November 08, 2003, 05:43 PM
Quote from: Freeware on November 08, 2003, 05:21 PM
Quote from: CupHead on November 08, 2003, 05:20 PM
GTC means GetTickCount, which is a function in kernel32.  It returns a long value containing the number of milliseconds since the system was started.

So you can use any random number in it and Battle.Net will still function?

Yes, any random number between zero and 0xffffffff. You can use GetTickCount(), but then you're telling Battle.net your system's uptime. So you may want to use something like rand().
Title: Re:Client Key? (GTC)
Post by: iago on November 08, 2003, 05:47 PM
Quote from: Spht on November 08, 2003, 05:43 PM
Quote from: Freeware on November 08, 2003, 05:21 PM
Quote from: CupHead on November 08, 2003, 05:20 PM
GTC means GetTickCount, which is a function in kernel32.  It returns a long value containing the number of milliseconds since the system was started.

So you can use any random number in it and Battle.Net will still function?

Yes, any random number between zero and 0xffffffff. You can use GetTickCount(), but then you're telling Battle.net your system's uptime. So you may want to use something like rand().

So, any number between 0 and -1 ;)

It should be noted that you can use anything PROVIDED you are consistant throughout (ie, for 0x51 and for your password hash, etc.).  That should be common sense, but I just thought I'd mention it :)