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

Make a new instance upon encountering difficult mobs (All-Seeing Eye, Rima, etc)

sabe

New Member
Joined
Jun 26, 2012
Messages
9
Reaction score
0
Is there a way to do the above? Perhaps a combat routine?
 
Yes, this is possible with a plugin, I'll make an example in a bit and post it here after testing so you have something that works. Gotta handle a few other threads first though.
 
Thanks, looking forward to it. At the moment botting on Invasion is risky because of some of these OP random bosses.
 
Make a new folder in your Plugins directory called AvoidBaddies. Create a new file, AvoidBaddies.cs in that folder and paste this code. You can add/edit the names as you need.

AvoidBaddies.cs
Code:
using System;
using System.Diagnostics;
using System.Linq;
using log4net;
using Loki.Game;
using Loki.Utilities;
using Loki.Utilities.Plugins;

namespace AvoidBaddies
{
    /// <summary> </summary>
    public class AvoidBaddies
 : IPlugin
    {
        #region Implementation of IEquatable<IPlugin>

        /// <summary>
        ///     Indicates whether the current object is equal to another object of the same type.
        /// </summary>
        /// <returns>
        ///     true if the current object is equal to the <paramref name="other" /> parameter; otherwise, false.
        /// </returns>
        /// <param name="other">An object to compare with this object.</param>
        public bool Equals(IPlugin other)
        {
            return Name.Equals(other.Name);
        }

        #endregion

        private static readonly ILog Log = Logger.GetLoggerInstanceForType();

        #region Implementation of IPlugin

        /// <summary> </summary>
        public string Author { get { return "pushedx"; } }

        /// <summary> </summary>
        public Version Version { get { return new Version(0, 1, 0, 0); } }

        /// <summary> </summary>
        public string Name { get { return "AvoidBaddies"; } }

        /// <summary> </summary>
        public string Description { get { return "This plugin shows an example of bailing out on a bot run when a dangerous mob is detected."; } }

        /// <summary> Executes the start action. This is called when the bot starts. </summary>
        public void OnStart()
        {
        }

        /// <summary> Executes the stop action. This is called when the bot is stopped. </summary>
        public void OnStop()
        {
        }

        private static string[] NamesToProcess =
        {
            "Hailrake", // Just an example
            // Add lines for each name, spelling and case matters!
        };

        private static Stopwatch baddieCheckStopwatch = Stopwatch.StartNew();

        /// <summary> Executes the pulse action. This is called every "tick" of the bot. </summary>
        public void OnPulse()
        {
            if (LokiPoe.ObjectManager.Me.IsInTown)
                return;

            if (baddieCheckStopwatch.ElapsedMilliseconds > 1000)
            {
                baddieCheckStopwatch.Restart();

                // Check to see if any of the baddie names are found.
                if (LokiPoe.ObjectManager.Objects.Any(o => NamesToProcess.Contains(o.Name)))
                {
                    // This will request the bot abandon the current bot run. However, it must finish combat, and
                    // a few other things first. It's possible you can combat chain your way into the boss you're
                    // trying to avoid, so logging out might be the better approach for Hardcore.
                    //Registry.AbandonCurrentBotRun();

                    // Alternatively, you can chicken out which will ensure you don't get close to it at all.
                    // We check the return value, because we can't force the client to logout at times.
                    if (LokiPoe.Gui.Logout(false)) // pass false to logout to login screen (much safer!)
                    {
                        // Force the bot logic to start over.
                        throw new Exception("Abandoning the current bot run.");
                    }
                }
            }
        }

        /// <summary>
        ///     Executes the initialize action. This is called at initial bot startup. (When the bot itself is started, not
        ///     when Start() is called)
        /// </summary>
        public void OnInitialize()
        {
        }

        /// <summary> Executes the shutdown action. This is called when the bot is shutting down. (Not when Stop() is called) </summary>
        public void OnShutdown()
        {
        }

        /// <summary> Executes the enabled action. This is called when the user has enabled this specific plugin via the GUI. </summary>
        public void OnEnabled()
        {
        }

        /// <summary> Executes the disabled action. This is called whent he user has disabled this specific plugin via the GUI. </summary>
        public void OnDisabled()
        {
        }

        /// <summary> Executes the config action. This is called when the user clicks on the config button.</summary>
        public void OnConfig()
        {
        }

        #endregion
    }
}

Now launch Exilebuddy, then click on the "Plugins" tab at the top and enable the "AvoidBaddies" plugin by placing a check mark in the box. You should probably test it some to make sure it's working as expected, but it should. You just have to make sure you get the names correct for the bosses you want to avoid.

When it triggers, you should see something like this in the bot window:
Code:
Now logging out to Login Screen.
Exception while pulsing plugin AvoidBaddies: System.Exception: Abandoning the current bot run.
   at AvoidBaddies.AvoidBaddies.OnPulse()
   at Loki.Utilities.Plugins.PluginManager.PulsePlugin(IPlugin plugin)

That's all there is to do for this!
 
Invasion Bosses & Rogue Exiles from the PoE Wiki



Code:
        private static string[] NamesToProcess =
        {

                // Invasion Bosses
                "Alpha Paradisae",
                "Balus Stoneskull",
                "Bladeback Guardian",
                "Bladetooth",
                "Blood Morpher",
                "Blood Stasis",
                "Cintiq, the Inescapable",
                "Coniraya, Shadow of Malice",
                "Corpsestitch",
                "Corrector Draconides",
                "Droolscar",
                "Evocata Apocalyptica",
                "Genesis Paradisae",
                "Glassmaul",
                "Granitecrush",
                "Grath",
                "Guardian of the Mound",
                "Harbinger of Elements",
                "Haviri, Vaal Metalsmith",
                "Inti of the Blood Moon",
                "Jikeji",
                "Judgement Apparatus",
                "Junglemare",
                "Kall Foxfly",
                "Konu, Maker of Wind",
                "Kutec, Vaal Fleshsmith",
                "M'gaska, the Living Pyre",
                "Mammothcage",
                "Mother of the Swarm",
                "Nighteater",
                "Ossecati, Boneshaper",
                "Pewterfang",
                "Rancor",
                "Rima, Deep Temptress",
                "Sheaq, Maker of Floods",
                "Shivershell",
                "Spinesnap",
                "Strangledrift",
                "Tailsinger",
                "The Bolt Juggler",
                "The Book Burner",
                "The Duchess",
                "The Firestarter",
                "The Raging Mask",
                "The Revenant",
                "Thornrunner",
                "Wiraqucha, Ancient Guardian",
                "Wonderwalker",
                
                // Rogue Exiles
                "Antalie Napora",
                "Armios Bell",
                "Ash Lessard",
                "Damoi Tui",
                "Eoin Greyfur",
                "Igna Phoenix",
                "Ion Darkshroud",
                "Jonah Unchained",
                "Minara Anemina",
                "Orra Greengate",
                "Thena Moga",
                "Tinevin Highdove",
                "Torr Olgosso",
                "Xandro Blooddrinker",
        };
 
Looks good, thanks clandestine! I'll include that in a future guide when we get some time to consolidate all these small features that were added, but lost due to the recent forum issues.
 
This is the new Invasion list:

Alpha Paradisae
Atziri's Pride
Balus Stoneskull
Bladeback Guardian
Bladetooth
Blood Morpher
Blood Stasis
Cintiq, the Inescapable
Coniraya, Shadow of Malice
Corpsestitch
Corrector Draconides
Droolscar
Evocata Apocalyptica
Genesis Paradisae
Glassmaul
Granitecrush
Grath
Guardian of the Mound
Harbinger of Elements
Haviri, Vaal Metalsmith
Inti of the Blood Moon
Jikeji
Judgement Apparatus
Junglemare
Kall Foxfly
Konu, Maker of Wind
Kutec, Vaal Fleshsmith
M'gaska, the Living Pyre
Mammothcage
Mother of the Swarm
Nighteater
Ossecati, Boneshaper
Pewterfang
Rancor
Rima, Deep Temptress
Sheaq, Maker of Floods
Shivershell
Simi, the Nature Touched
Spinesnap
Strangledrift
Tailsinger
The Bolt Juggler
The Book Burner
The Duchess
The Firestarter
The Raging Mask
The Revenant
Thornrunner
Wiraqucha, Ancient Guardian
Wonderwalker

I need to add 2 more bosses to the code, Willl do shortly
 
Is there any way to modify the code to return to the character select screen and not the login screen? It has trouble relogging sometimes for me (wants me to re-type my password). Thanks! :)
 
^^^ This. The logging out on the onPulse function seems like it's kinda suspicious logging out so much. If you could just simply change that I'd be grateful.
 
Ok Il see if i can add the option for the settings... As i said im not the original coder for this Ive just added it all tougher.

None the less i should be able to change it.
 
Ok Il see if i can add the option for the settings... As i said im not the original coder for this Ive just added it all tougher.

None the less i should be able to change it.

The hell are you on about ? :-x This literally requires you to change one parameter in the function call , in this case a boolean .
if (LokiPoe.Gui.Logout(false)) // pass false to logout to login screen (much safer!)
^ That line is reponsible for logging you to login screen, while this might be more "suspicious" it is also safer whilst its instant (i think pushedx explained it as that a terminate packet is sent so you DC instantly) compared to the instance where it hops into the character select screen, that takes some time since you re not terminating the connection and can naturally cause death depending on your pc and other factors.
 
The hell are you on about ? :-x This literally requires you to change one parameter in the function call , in this case a boolean .

^ That line is reponsible for logging you to login screen, while this might be more "suspicious" it is also safer whilst its instant (i think pushedx explained it as that a terminate packet is sent so you DC instantly) compared to the instance where it hops into the character select screen, that takes some time since you re not terminating the connection and can naturally cause death depending on your pc and other factors.

Yep I see that, I was looking at adding a GUI to this plugin, So users could select what option they would prefer, instead of changing the code.
 
The hell are you on about ? :-x This literally requires you to change one parameter in the function call , in this case a boolean .

^ That line is reponsible for logging you to login screen, while this might be more "suspicious" it is also safer whilst its instant (i think pushedx explained it as that a terminate packet is sent so you DC instantly) compared to the instance where it hops into the character select screen, that takes some time since you re not terminating the connection and can naturally cause death depending on your pc and other factors.

And yes i do agree with you, Exit to login screen is what i use, and alot safer.

Moving on towards crule and merc some of these invasion bosses, Will one shot you You just want out ASAP

GGG needs to address some of the combination skills some of these bosses have.
 
Last edited:
not to mention GGG does not mind players using scripts to chicken, some of the AHK scripts are even posted on their forums. Also if you want to add a GUI take a look at the GemLeveler source. It shows you around the basics on how you can do so.
 
Thanks, Doing that right now pretty new to C++ but getting my head around it pretty snappy.
 
New list including 3 missing mobs.

Code:
private static string[] NamesToProcess =
        {

                // Invasion Bosses
                "Alpha Paradisae",
		"Atziri's Pride",
                "Balus Stoneskull",
                "Bladeback Guardian",
                "Bladetooth",
                "Blood Morpher",
                "Blood Stasis",
                "Cintiq, the Inescapable",
                "Coniraya, Shadow of Malice",
                "Corpsestitch",
                "Corrector Draconides",
                "Droolscar",
                "Evocata Apocalyptica",
                "Genesis Paradisae",
                "Glassmaul",
                "Granitecrush",
                "Grath",
                "Guardian of the Mound",
                "Harbinger of Elements",
                "Haviri, Vaal Metalsmith",
                "Inti of the Blood Moon",
                "Jikeji",
                "Judgement Apparatus",
                "Junglemare",
                "Kall Foxfly",
                "Konu, Maker of Wind",
                "Kutec, Vaal Fleshsmith",
                "M'gaska, the Living Pyre",
                "Mammothcage",
                "Mother of the Swarm",
                "Nighteater",
                "Ossecati, Boneshaper",
		"Perquil the Lucky",
                "Pewterfang",
                "Rancor",
                "Rima, Deep Temptress",
                "Sheaq, Maker of Floods",
                "Shivershell",
		"Simi, the Nature Touched",
                "Spinesnap",
                "Strangledrift",
                "Tailsinger",
                "The Bolt Juggler",
                "The Book Burner",
                "The Duchess",
                "The Firestarter",
                "The Raging Mask",
                "The Revenant",
                "Thornrunner",
                "Wiraqucha, Ancient Guardian",
                "Wonderwalker",
                
                // Rogue Exiles
                "Antalie Napora",
                "Armios Bell",
                "Ash Lessard",
                "Damoi Tui",
                "Eoin Greyfur",
                "Igna Phoenix",
                "Ion Darkshroud",
                "Jonah Unchained",
                "Minara Anemina",
                "Orra Greengate",
                "Thena Moga",
                "Tinevin Highdove",
                "Torr Olgosso",
                "Xandro Blooddrinker",
        };
 
its nice but for me he never start a new instance ?so he just do that in loop,entre the place log out,enter,exit...
 
Back
Top