how to check buffer

Need help with a macro you are writing? Ask here!

Moderator: MacroQuest Developers

wolfbaby
a lesser mummy
a lesser mummy
Posts: 45
Joined: Mon Sep 06, 2004 5:34 am

how to check buffer

Post by wolfbaby » Wed Oct 06, 2004 10:53 am

how to check my buffer and my pet's buffer,don't want to use event.
is there another way just like ${Me.PctHPs}

User avatar
fearless
Not a Psychic
Posts: 2684
Joined: Wed Mar 10, 2004 3:52 pm

Post by fearless » Wed Oct 06, 2004 11:29 am

Code: Select all

#include spellcast.inc

    /if (!${Me.Buff["Pact of Hate"].ID} && !${Me.Casting.ID}) /call Cast "Pact of Hate" gem8

I think that is what you are looking for . . . looking for pet routine.
Reading . . . it's not just for me.

[url=http://www.catb.org/~esr/faqs/smart-questions.html]How To Ask Questions The Smart Way[/url]
[quote="Ccomp5950"]Fearless showed me the light, you too shall learn.[/quote]

User avatar
fearless
Not a Psychic
Posts: 2684
Joined: Wed Mar 10, 2004 3:52 pm

Post by fearless » Wed Oct 06, 2004 11:59 am

${Me.PetBuff}
Reading . . . it's not just for me.

[url=http://www.catb.org/~esr/faqs/smart-questions.html]How To Ask Questions The Smart Way[/url]
[quote="Ccomp5950"]Fearless showed me the light, you too shall learn.[/quote]

wolfbaby
a lesser mummy
a lesser mummy
Posts: 45
Joined: Mon Sep 06, 2004 5:34 am

Post by wolfbaby » Wed Oct 06, 2004 9:54 pm

many thanks guys .

Code: Select all

     /echo ${Me.PetBuff["Augment Death"]}
works,

Code: Select all

     /echo ${Me.PetBuff["Augment Death"].ID}
not works,dont know why but i make my macro works right now.

Chill
Contributing Member
Contributing Member
Posts: 435
Joined: Fri May 07, 2004 5:06 pm
Location: Erie, PA

Post by Chill » Tue Oct 26, 2004 9:20 am

If you are checking for a buff to recast, I suggest checking for its duration under some minimum length (in ticks):

Code: Select all

/if (${Me.PetBuff["Augment Death"].Duration}<20) /call cast "Augment Death"
0 is of course less than 20, so if the buff is not there at all, this will cover that too.

wolfbaby
a lesser mummy
a lesser mummy
Posts: 45
Joined: Mon Sep 06, 2004 5:34 am

Post by wolfbaby » Fri Oct 29, 2004 11:06 pm

Chill wrote:If you are checking for a buff to recast, I suggest checking for its duration under some minimum length (in ticks):

Code: Select all

/if (${Me.PetBuff["Augment Death"].Duration}<20) /call cast "Augment Death"
0 is of course less than 20, so if the buff is not there at all, this will cover that too.

Code: Select all

/if (${Me.PetBuff["Augment Death"].Duration}<20) /call cast "Augment Death"
does not work. but

Code: Select all

/if (${Me.Buff[buff name].Duration}<20) /call cast "buff name"
works.
mayben Petbuff.Duration is not right.

User avatar
Cr4zyb4rd
Plugins Czar
Posts: 1449
Joined: Tue Jul 20, 2004 11:46 am

Post by Cr4zyb4rd » Fri Oct 29, 2004 11:37 pm

RTFM. Me.PetBuff returns the type spell, Me.Buff returns the type buff. There's no PetBuff[].Duration because there can't be. All the client knows is the name of the spell affecting the pet, it doesn't have access to it the same way it has access to your own personal effects.

If you want to know the duration of your pet's buffs, set a timer when the buffs land on it.

wolfbaby
a lesser mummy
a lesser mummy
Posts: 45
Joined: Mon Sep 06, 2004 5:34 am

Post by wolfbaby » Fri Nov 05, 2004 8:45 am

no no ,when i put my mouse on the pet's buff,i can see the duration.That's not a server side data.

User avatar
Cr4zyb4rd
Plugins Czar
Posts: 1449
Joined: Tue Jul 20, 2004 11:46 am

Post by Cr4zyb4rd » Fri Nov 05, 2004 9:41 am

then look at the xml for your pet buff window and use that *shrug*

User avatar
fearless
Not a Psychic
Posts: 2684
Joined: Wed Mar 10, 2004 3:52 pm

Post by fearless » Fri Nov 05, 2004 9:47 am

Code: Select all

/if (${Me.Pet.ID} && !${Me.PetBuff["Augmentation of Death"]} && ${Me.Pet.Distance}<100) {
          /call Cast "Augmentation of Death" gem8 
        }
Works, use it and love it.
Reading . . . it's not just for me.

[url=http://www.catb.org/~esr/faqs/smart-questions.html]How To Ask Questions The Smart Way[/url]
[quote="Ccomp5950"]Fearless showed me the light, you too shall learn.[/quote]

User avatar
Cr4zyb4rd
Plugins Czar
Posts: 1449
Joined: Tue Jul 20, 2004 11:46 am

Post by Cr4zyb4rd » Fri Nov 05, 2004 12:06 pm

but that's not the duration, his pet window shows the duration! waa waa!

ColdFusion
decaying skeleton
decaying skeleton
Posts: 9
Joined: Mon Nov 01, 2004 10:30 am
Location: Emarr

Post by ColdFusion » Fri Nov 05, 2004 12:14 pm

Code: Select all

[Substitutions]
CoD=${Window[PetInfoWindow].Child[PIW_BuffWindow].Child[PIW_PetBuff${Math.Calc[${Me.PetBuff[Command of Druzzil]}-1].Int}_Button].Tooltip}
returns Command of druzzil (mins:seconds)
(Or something similar)

then use .Arg[ previous string length -1 ]}

fix all the fun santax, but should get idea

-have fun

User avatar
fearless
Not a Psychic
Posts: 2684
Joined: Wed Mar 10, 2004 3:52 pm

Post by fearless » Fri Nov 05, 2004 12:24 pm

Cr4zyb4rd wrote:but that's not the duration, his pet window shows the duration! waa waa!
oh nos!
Reading . . . it's not just for me.

[url=http://www.catb.org/~esr/faqs/smart-questions.html]How To Ask Questions The Smart Way[/url]
[quote="Ccomp5950"]Fearless showed me the light, you too shall learn.[/quote]

p$
decaying skeleton
decaying skeleton
Posts: 8
Joined: Sat Oct 16, 2004 10:59 pm

Post by p$ » Tue Nov 09, 2004 9:59 pm

.Duration will work if you use a number, but it only shows the spells original duration, not the time remaining

Code: Select all

${Me.PetBuff[${Me.PetBuff[Augment Death]}].Duration}
not that it will help you any, but its in there. ${Me.PetBuff[Name]} returns an integer, ${Me.PetBuff[Number]} returns a string. you need to use the string version to use the Duration property for some reason.

User avatar
ieatacid
Developer
Developer
Posts: 2727
Joined: Wed Sep 03, 2003 7:44 pm

Post by ieatacid » Wed Nov 10, 2004 12:37 am

Can't you just grab the ToolTip? There was a post about that somewhere for getting group member names who weren't in the same zone.

I don't feel like looking for it.