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

Orderbot Tags OnStop ?

ExMatt

Active Member
Joined
Jul 5, 2015
Messages
1,030
Reaction score
14
I have a few concerns about the fish tag I have been working on, both related to if you stop the bot manually by clicking the stop button.

1. You could be left with UseMount = false if you were using stealth in the profile.
2. I am adding an EventHandler to the GamelogManager.

I am handling these fine if OnDone is called, but not if the bot is just Stopped.

Any suggestions, or maybe we can get a method that Orderbot can call on the loaded Profile Behaviors if the stop button is pushed.
 
Something like this
Code:
        private BotEvent Cleanup;
        protected override void OnStart()
        {
            Cleanup = delegate(BotBase bot)
            {
                //Do cleanup stuff here
                TreeRoot.OnStop -= Cleanup;
            };
            TreeRoot.OnStop += Cleanup;
        }
        protected override void OnDone()
        {
            TreeRoot.OnStop -= Cleanup;
            //Cleanup again
        }
 
Back
Top