Mage purify
-
noobbotter
- Posts: 527
- Joined: Fri Aug 31, 2012 1:15 pm
Mage purify
Is there any function to detect if a player or target has any negative effects (debuffs) without doing a hasbuff search for a specific debuff? I'm looking to implement a mage/priest elite skill Purify, but don't know how to tell the bot when to use it. Does the bot already know what debuffs it can clear using this skill (as well as with the grand dispel elite)?
Thanks.
Thanks.
Re: Mage purify
The bot sees buffs and debuffs as being the same. There is an in game function you could use called UnitDebuff. You could use it like this.
This means "if you have at least 1 debuff then".
Code: Select all
if RoMScript("UnitDebuff('player',1)") then
...- Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
- I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
- How to: copy and paste in micromacro
________________________
Quote:- “They say hard work never hurt anybody, but I figure, why take the chance.”
- Ronald Reagan
Re: Mage purify
Well I can tell you that
0x34 is if buff has a timed effect and how many seconds between each effect, 0 if no timed effect (float) ie, regeneration heal ticks every 2 seconds so value is 2
0x38 is time to next effect (float)
0x3C is number of ticks left before buff expires (int) ie If 7 seconds to go and it ticks every 2 seconds then it ticks at 6,4,2,0 so value would be 4
There is more than likely an offset for buff or debuff, I might find it if I have the time.
0x34 is if buff has a timed effect and how many seconds between each effect, 0 if no timed effect (float) ie, regeneration heal ticks every 2 seconds so value is 2
0x38 is time to next effect (float)
0x3C is number of ticks left before buff expires (int) ie If 7 seconds to go and it ticks every 2 seconds then it ticks at 6,4,2,0 so value would be 4
There is more than likely an offset for buff or debuff, I might find it if I have the time.
Remember no matter you do in life to always have a little fun while you are at it 
wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
Re: Mage purify
The bot finds the buffs and debuffs in the same area of memory. I think the only thing distinguishing buffs from debuffs are the effects they cause. I don't think there are any simple flag indicating a buff or debuff. If there was, I would have found it and added it to the buffs data when we first started getting buffs from memory. Feel free to look though.
- Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
- I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
- How to: copy and paste in micromacro
________________________
Quote:- “They say hard work never hurt anybody, but I figure, why take the chance.”
- Ronald Reagan
Re: Mage purify
I need some lowish lvl mobs to do different debuffs to really hold true to what I am seeing.
I am really interested in 0x14, 0x18, 0x1C.
0x14 and 0x18 seem to change depending of if buff/debuff is from a mob or not
0x1C seems to indicate which player/object put the buff/debuff on you.
As for an indicator of whether you can cleanse or not I just don't see 1, chances are when you cast the skill it runs a function which just checks the Id's the skill can remove.
I am really interested in 0x14, 0x18, 0x1C.
0x14 and 0x18 seem to change depending of if buff/debuff is from a mob or not
0x1C seems to indicate which player/object put the buff/debuff on you.
As for an indicator of whether you can cleanse or not I just don't see 1, chances are when you cast the skill it runs a function which just checks the Id's the skill can remove.
Remember no matter you do in life to always have a little fun while you are at it 
wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
Re: Mage purify
Can't we assume that a buff/debuff from a player (while not dueling) will be a buff, and a buff/debuff from a mob will always be a debuff?
- Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
- I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
- How to: copy and paste in micromacro
________________________
Quote:- “They say hard work never hurt anybody, but I figure, why take the chance.”
- Ronald Reagan
Re: Mage purify
Yup that is why I found them interesting, it still won't tell you if you can cleanse it or not, not sure if all debuffs can be cleansed.
Also the tick could indicate a poison as it does damage over time.
Also the tick could indicate a poison as it does damage over time.
Remember no matter you do in life to always have a little fun while you are at it 
wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
Re: Mage purify
The answer is no, some debuffs can only be removed through timer/dying or by going through a boss event. there is even a buff from the horse racing which can only be removed by having more than 40 buffs on you.(kick it out)lisa wrote:Yup that is why I found them interesting, it still won't tell you if you can cleanse it or not, not sure if all debuffs can be cleansed.
Also the tick could indicate a poison as it does damage over time.
Jack-of-all-trades, but master-of-only of a few
My Reps:
https://github.com/BlubBlab/Micromacro-with-OpenCV (My version of MM2 with OpenCV and for MS Visual Studio)
https://github.com/BlubBlab/rom-bot (rombot with no stop WP and advanced human emulation mode and some other extensions)
https://github.com/BlubBlab/Micromacro-2-Bot-Framework ( A work in progress )
My Tools : viewtopic.php?f=10&t=6226
My Reps:
https://github.com/BlubBlab/Micromacro-with-OpenCV (My version of MM2 with OpenCV and for MS Visual Studio)
https://github.com/BlubBlab/rom-bot (rombot with no stop WP and advanced human emulation mode and some other extensions)
https://github.com/BlubBlab/Micromacro-2-Bot-Framework ( A work in progress )
My Tools : viewtopic.php?f=10&t=6226
-
noobbotter
- Posts: 527
- Joined: Fri Aug 31, 2012 1:15 pm
Re: Mage purify
My thinking was along the lines of a Mage/Priest. He has Grand Dispel which, when using purify will also remove harmful effects (in addition to curses. I assume curses are thinks like slow you down or reduce stats, whereas harmful effects are likely bleeds). So I was thinking if I could find some way for it to detect harmful effects coming from a Boss or it's adds, on himself or a party member, it could use it's Purify to remove it. And I'm thinking I don't really need to know if it can be cleansed or not, I figure if it can identify it as a debuff, I could attempt to remove it. This isn't something I plan to have in my profile so it wouldn't be constantly trying to remove a debuff during normal botting of minigames and stuff... just as part of a instance running waypoint I'm using.
Re: Mage purify
If it is purely for specific instances then the list of things to be cleansed should be very low, maybe 5-6 debuffs. In that case just make up a table of the debuffs you want to get rid of and have it check for those specific ones and use skill if the party member has 1 of them.
I think to make the bot use the skill anytime it has any debuff that can be removed (probably 100 of them), is way to much time and effort.
So just gather up debuff Id's you want to get rid of that you get inside the instance and then we can work from there.
I think to make the bot use the skill anytime it has any debuff that can be removed (probably 100 of them), is way to much time and effort.
So just gather up debuff Id's you want to get rid of that you get inside the instance and then we can work from there.
Remember no matter you do in life to always have a little fun while you are at it 
wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
Re: Mage purify
Well, Rock5's hint with UnitDebuff was spot on.
UnitDebuff returns a param (5th return value) that indicates what type of debuff it is.
I found this while browsing through RaidHeals code some time ago. (RaidHeal is a healing addon a bit similar to GCI, but features "sorting" of debuffs depending on how they can be cleansed) In RaidHeal debuff params get checked for the values 6, 10 and 11 (should be poison, harmful effect and curse, though im not 100% on which value represents which debuff type).
In your case, checking for the values 10 and 11 should work out
UnitDebuff returns a param (5th return value) that indicates what type of debuff it is.
I found this while browsing through RaidHeals code some time ago. (RaidHeal is a healing addon a bit similar to GCI, but features "sorting" of debuffs depending on how they can be cleansed) In RaidHeal debuff params get checked for the values 6, 10 and 11 (should be poison, harmful effect and curse, though im not 100% on which value represents which debuff type).
In your case, checking for the values 10 and 11 should work out
Who is online
Users browsing this forum: No registered users and 2 guests