Page 1 of 1

Player debuffing

Posted: Wed Feb 08, 2012 5:33 am
by jasn
Was wondering and seraching about how to debuff your self or party members.
And all i could find was this from the wiki , but im not sure how to implement it and where in the profile.

Code: Select all

local target = player:getTarget();
 target:updateBuffs()
 if target:hasDebuff("debuffname") then
if we assume that the player(me) have a DeBuff of poison, as a druid i use Antidote or a Priest use Cleanse.
and the same goes for curses druid uses Purify, Priest use Cleanse ? or is it Remove Curse.

so if i understand the code snippet would be something like this?

Code: Select all

local target = player:getTarget();
 target:updateBuffs()
 if target:hasDebuff("debuffname") then PRIEST_CLEANSE
and now i know im totaly out on deep water. ;)

Re: Player debuffing

Posted: Wed Feb 08, 2012 5:51 am
by lisa
I would probably set up a table for it but the trouble is how do you know what type of debuff it is?
Would you add in every single name or Id for every single debuff?
There must be something in memory which has the type as it would need it for when using skills to remove some types.

Re: Player debuffing

Posted: Thu Feb 09, 2012 1:32 am
by jasn
what i´ve seen so far is that poison has the word poison or poisoned in the debuff, bit worse with the curses tho.

But im way over my head on this one so ill just put the "debuffin" thingy to rest cause i dont have the knowhow and skills for it.

Thanks for the inputs tho.