• Welcome to Valhalla Legends Archive.
 

Multi form bot

Started by Tazo, March 21, 2004, 03:28 PM

Previous topic - Next topic

Tazo

Quote from: Archangel on March 25, 2004, 06:38 AM
Quote
frmMain.sckbnet.SendData Chr(&HFF) & Chr(PacketID) & MakeWORD(Len(Buffer) + 4) & Buffer

I think thats your problem.
whats wrong with that? it always worked fine before..

Archangel

Quote from: laurion on March 25, 2004, 01:52 PM
Quote from: Archangel on March 25, 2004, 06:38 AM
Quote
frmMain.sckbnet.SendData Chr(&HFF) & Chr(PacketID) & MakeWORD(Len(Buffer) + 4) & Buffer

I think thats your problem.
whats wrong with that? it always worked fine before..

Ok you are now using MDIChild Forms, so try this (easy way):
Put Your packet buffer in ur MdiChild.
I'm not an Addict.

MyndFyre

Quote from: Archangel on March 25, 2004, 02:13 PM
Quote from: laurion on March 25, 2004, 01:52 PM
Quote from: Archangel on March 25, 2004, 06:38 AM
Quote
frmMain.sckbnet.SendData Chr(&HFF) & Chr(PacketID) & MakeWORD(Len(Buffer) + 4) & Buffer

I think thats your problem.
whats wrong with that? it always worked fine before..

Ok you are now using MDIChild Forms, so try this (easy way):
Put Your packet buffer in ur MdiChild.

No, put your Socket control in the MdiChild form.
QuoteEvery generation of humans believed it had all the answers it needed, except for a few mysteries they assumed would be solved at any moment. And they all believed their ancestors were simplistic and deluded. What are the odds that you are the first generation of humans who will understand reality?

After 3 years, it's on the horizon.  The new JinxBot, and BN#, the managed Battle.net Client library.

Quote from: chyea on January 16, 2009, 05:05 PM
You've just located global warming.

Tazo

#33
My socket is in the MDIChild form (frmMain)  :-\

edit::btw i tried putting packetbuffer in the MDI parent, it didnt help :/

Archangel

Quote from: laurion on March 25, 2004, 07:09 PM
My socket is in the MDIChild form (frmMain)  :-\

edit::btw i tried putting packetbuffer in the MDI parent, it didnt help :/

huh
did u did:
Me.sckbnet.SendData Chr(&HFF) & Chr(PacketID) & MakeWORD(Len(Buffer) + 4) & Buffer
?
I'm not an Addict.

MyndFyre

Quote from: laurion on March 25, 2004, 07:09 PM
My socket is in the MDIChild form (frmMain)  :-\

edit::btw i tried putting packetbuffer in the MDI parent, it didnt help :/

Why in God's name would you name your MDI child frmMain?!?  The point of naming it frmMain is that it is the main form!  It should exist only once throughout the duration of the program

Depending on the implementation, I have seen the PacketBuffer class as a module (IIRC).  You can run into issues of two separate events (threads) adding data to the PacketBuffer if you only run one global instance.  Ideally, you should have one instance of a Socket and once instance of a PacketBuffer in each form through which you are connecting to the server (each MDIChild).

Get better naming conventions though, man.  frmMain is not good to use as a frmChild.
QuoteEvery generation of humans believed it had all the answers it needed, except for a few mysteries they assumed would be solved at any moment. And they all believed their ancestors were simplistic and deluded. What are the odds that you are the first generation of humans who will understand reality?

After 3 years, it's on the horizon.  The new JinxBot, and BN#, the managed Battle.net Client library.

Quote from: chyea on January 16, 2009, 05:05 PM
You've just located global warming.

Tazo

QuotefrmMain is not good to use as a frmChild.
Oookkk...i dont see why not  ;D (im stubborn  :P)

Archangel

Quote from: laurion on March 26, 2004, 05:10 AM
QuotefrmMain is not good to use as a frmChild.
Oookkk...i dont see why not  ;D (im stubborn  :P)

But that shouldnt fix your problem.
I'm not an Addict.

MyndFyre

Quote from: laurion on March 26, 2004, 05:10 AM
QuotefrmMain is not good to use as a frmChild.
Oookkk...i dont see why not  ;D (im stubborn  :P)

Did you read the second sentence?  The point of naming it the main form is that it should exist singly throughout the entire lifetime of the application.  It is a common convention and you have it completely ass-backwards.  Do whatever you want, but if you want to ever take your experience somewhere else, I suggest you learn proper habits.

Bit as Archangel correctly pointed out, this won't fix your problem.
QuoteEvery generation of humans believed it had all the answers it needed, except for a few mysteries they assumed would be solved at any moment. And they all believed their ancestors were simplistic and deluded. What are the odds that you are the first generation of humans who will understand reality?

After 3 years, it's on the horizon.  The new JinxBot, and BN#, the managed Battle.net Client library.

Quote from: chyea on January 16, 2009, 05:05 PM
You've just located global warming.

Archangel

Well i think your problem is that you dont know how to use VB Functions and u are having troubles, i will tell u this once, start programming other things so later u can develop a bot.
I'm not an Addict.

Tazo

Quote from: Archangel on March 26, 2004, 02:14 PM
Well i think your problem is that you dont know how to use VB Functions and u are having troubles, i will tell u this once, start programming other things so later u can develop a bot.
um buddy ive made bots before, justnever wit mdi child/parent

Archangel

Quote from: laurion on March 26, 2004, 07:24 PM
Quote from: Archangel on March 26, 2004, 02:14 PM
Well i think your problem is that you dont know how to use VB Functions and u are having troubles, i will tell u this once, start programming other things so later u can develop a bot.
um buddy ive made bots before, justnever wit mdi child/parent
If u did your own bot, this shouldnt be hard to resolve.
I'm not an Addict.

SiMi

i released the source code to simi. It was also a client that loaded multiple clients, maybe you can learn from that. I dont know in which websites the source might be in, but its out there.

Tuberload

Quote from: laurion on March 26, 2004, 07:24 PM
Quote from: Archangel on March 26, 2004, 02:14 PM
Well i think your problem is that you dont know how to use VB Functions and u are having troubles, i will tell u this once, start programming other things so later u can develop a bot.
um buddy ive made bots before, justnever wit mdi child/parent

Doesn't VB ship with example source code? I remember when I had 5.0 it did. Anyways you can find examples of how to use MDI Forms on a sites like http://www.planetsourcecode.com. I hope that helps.
Quote"Pray not for lighter burdens, but for stronger backs." -- Teddy Roosevelt
"Your forefathers have given you freedom, so good luck, see you around, hope you make it" -- Unknown

|