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

Perform action before opening StrongBox

papagal

Member
Joined
Dec 11, 2014
Messages
68
Reaction score
0
Hi, Is it possible to perform an action before opening a strongbox?

What I have in mind is editing my routine to drop my totems before opening a strongbox, but i'm not sure if that's even achievable in the combat routine.

Any pointers to the proper documentation would be mu appreciated!

Thanks.
 
I made myself a cheap plugin that detects when my character is within 30 units of a strongbox and cast Vaal Summon Skeleton. I guess you could do the same for your totems. The skill isn't casted exactly before opening the strongbox, as the bot might be in range but decide to pick up items or something, but it's close enough for me.

Here's what my code looks like.

Code:
public void Tick()
        {
            if (!LokiPoe.IsInGame || LokiPoe.Me.IsInTown || LokiPoe.Me.IsDead)
                return;
            var monsters = LokiPoe.ObjectManager.GetObjectsByType<Monster>()
                .Where(m => !m.IsDead &&
                    m.IsHostile &&
                    m.Distance < 60)
                .OrderBy(b => b.Distance).ToList();

            //use vaal skill on unique monster
            if (monsters.Any(m => m.Rarity == Loki.Game.GameData.Rarity.Unique))
            {
                UseVaalSkill();
                return;
            }

            var boxes = LokiPoe.ObjectManager.GetObjectsByType<Chest>()
                .Where(b => b.IsStrongBox &&
                    b.Distance < 30)
                .OrderBy(b => b.Distance)
                .ToList();

            if(!monsters.Any() && boxes.Any()){
                //use skill before opening box
                UseVaalSkill();
                return;
            }
           
        }

Edit : Added my plugin to the post because some people seem interested. It doesn't have a UI, so if you want to change the behavior, you'll have to do it in the code.
 

Attachments

Last edited:
can anyone send me the code for using double flame totem before opening strongbox pls?
 
Back
Top