What's new
  • Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • Visit Resources
  • Visit Downloads
  • Visit Portal

Form = Honorbuddy stop?

HB5156P57

New Member
Joined
Jun 17, 2011
Messages
6
Reaction score
0
Hey guys,

im programming a status-window like that one in pirox.
But when i start the bot, and the window opens, HB stop's until i
close the window.

Anybody know how to fix that?
 
hey, i tried it, didn't work.. he close the threaded form instant.

public wSpy2()
{
BotEvents.OnBotStart += BotEvents_OnBotStart;
}
~wSpy2()
{
BotEvents.OnBotStart -= BotEvents_OnBotStart;
}

private void showForm()
{
wSpy form = new wSpy();
form.Show();
}

public void BotEvents_OnBotStart(EventArgs args)
{
System.Threading.Thread t = new System.Threading.Thread(new
System.Threading.ThreadStart(this.showForm));
t.Start();
}

this is my code to start the form in a new thread. any suggestions?
 
I cannot see why your code isn't working. Your code should launch a form using the thread. I have a guess that it may be that if a parent thread is terminated the child threads are also terminated. Maybe that is what is happening.
 
Hey guys,

im programming a status-window like that one in pirox.
But when i start the bot, and the window opens, HB stop's until i
close the window.

Anybody know how to fix that?
you're showing the GUI in the plugin/bot thread which gets terminated when hb is stopped.If you were using Form.ShowDialog() then it was blocking the thread until form was closed. Move you UI to the GUI thread (by placing your Form.Show()/Form.ShowDialog() in the 'OnButtonPress' override) and you won't have this issue.
 
you're showing the GUI in the plugin/bot thread which gets terminated when hb is stopped.If you were using Form.ShowDialog() then it was blocking the thread until form was closed. Move you UI to the GUI thread (by placing your Form.Show()/Form.ShowDialog() in the 'OnButtonPress' override) and you won't have this issue.

thanks, i will test it when im @home.
 
Back
Top