Jump to content

[LUA Fightclass] UnitDebuff + BuffStackTarget


Jupken13

Recommended Posts

Hello,

I can't seem to figure out the following:

I want to have a condition that checks the Buff Stack Target for Festering Wound.
However, whenever I use this function, it checks the debuffs from ALL DK's.
I want to check the Stack of my own debuffs, which can go up to 8.

Target Buff Casted By Me checks if my debuff is on the target, but that only checks for if the debuff is "present".

If I combine the above 2, it doesn't work.

Hence, I started to write in LUA code... But I seem to have reach an impasse.

returnResult = false;
local name = GetSpellInfo(194310);
local _, _, _, count, _, _, _, unitCaster = UnitDebuff("target", name, nil, "player");
if count and count =< 6 then
returnResult = true;
end

The above seems to work, but not if the debuff isn't present!

I would also need the same code, but this time, with a Between function.
Example: Between 2 & 6 stacks.

I lack the experience to create the proper code, can anyone help?

Thanks!

Link to comment
Share on other sites

I tested this code.

Again, this code works if the debuff ( Festering Wound ) is present with at least one stack.

In case the debuff is non existant on the target, it doesn't cast.

I could probably use Target Buff Casted By Me as a workaround in a different condition, although that would give me a lot more work.

Thanks for feedback.

Link to comment
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...