Jump to content

Recommended Posts

Sometimes it's difficult to check debuffs/buffs before casting a spell.

Example : Druid Guardian, if you have Faerie Swarm talent, you need to cast Faerie Fire; because Faerie Swarm is unknown spell. If you need to check if debuff faerie swarm exists, then you have a problem, for those who don't have Faerie Swarm.

To check the debuff I use following C# code :

public bool debuffExixts(string debuff)
    {
        /*[F] 11:09:45 - check Aura: Growl: ID=6795, Stack=0, TimeLeft=1082 ms, Owner=00000000079D3B1E0834FC0000000000*/
        List<Aura> t = ObjectManager.Target.GetAllBuff();
        foreach (var aura in t)
        {
            
            string[] checkAura = aura.ToString().Split(':');
            //Logging.WriteFight("check Aura: " + checkAura[0].Trim());
            if (ObjectManager.Me.Guid == ObjectManager.Target.BuffCastedBy(checkAura[0].Trim()) && checkAura[0].Contains(debuff)) return true;
        }
        return false;
    }

Faerie Fire and Faerie Swarm have 1 common text, Faerie. Then you can use debuffExists("Faerie") to check.

 

Link to comment
https://wrobot.eu/forums/topic/3325-get-debuffsbuffs/
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...