AltAbility TLO changes

Need help running MacroQuest2? Ask your questions about how to get things to work on your computer.

Moderator: MacroQuest Developers

JudgeD
a snow griffon
a snow griffon
Posts: 354
Joined: Sat Aug 18, 2012 8:07 pm

AltAbility TLO changes

Post by JudgeD » Mon Nov 23, 2015 6:05 pm

22 Nov 2015 by EqMule and Demonstar55
- Please don't use MQ2 for unattended gameplay (afk botting)
- Added .Index to the AltAbility TLO.
- Added .NextIndex to the AltAbility TLO.
- Added .CanTrain to the AltAbility TLO.
Usage: /if (${AltAbility[Companion's Aegis].CanTrain}) /alt buy ${AltAbility[Companion's Aegis].NextIndex}
- Added a few new APIs:
- AltAdvManager::CanSeeAbility
- AltAdvManager::CanTrainAbility
- PcZoneClient::HasAlternateAbility
- Added the /pick # command to the ISXEQ build.
Just a question about how exactly Index / NextIndex is supposed to work.

I found that when buying glyphs, I had to use:

Code: Select all

/alt buy ${AltAbility[Glyph of the Cataclysm].Index}
instead of:

Code: Select all

/alt buy ${AltAbility[Glyph of the Cataclysm].NextIndex}
When does one use one vs the other?

demonstar55
a snow griffon
a snow griffon
Posts: 314
Joined: Fri Nov 28, 2008 6:31 am

Re: AltAbility TLO changes

Post by demonstar55 » Mon Nov 23, 2015 10:38 pm

You are correct, going from rank 0 to rank 1 requires you to use Index (this is the ID of the AA rank, as opposed to the ID of the AA group, which is what ID is :P)

going from any other rank up requires you to use NextIndex, as in the next rank's ID.

JudgeD
a snow griffon
a snow griffon
Posts: 354
Joined: Sat Aug 18, 2012 8:07 pm

Re: AltAbility TLO changes

Post by JudgeD » Tue Nov 24, 2015 7:40 pm

Personal opinion is that it feels a little clunky for folks who might not want to build in checks every time they want to buy AA. I'm assuming there's a good reason, just speaking from a consumer's perspective.

demonstar55
a snow griffon
a snow griffon
Posts: 314
Joined: Fri Nov 28, 2008 6:31 am

Re: AltAbility TLO changes

Post by demonstar55 » Tue Nov 24, 2015 7:51 pm

That's how the data is. When you do ${AltAbility[foo]} without any ranks bought you end up with rank 1 and /alt buy takes in the Index of the AA you want to buy, so you have to provide ${AltAbility[foo].Index}. When you have rank 1 it returns rank 1 so you have to do ${AltAbility[foo].NextIndex}.

JudgeD
a snow griffon
a snow griffon
Posts: 354
Joined: Sat Aug 18, 2012 8:07 pm

Re: AltAbility TLO changes

Post by JudgeD » Tue Nov 24, 2015 8:39 pm

Cool, thanks for the explanation

EqMule
Developer
Developer
Posts: 2697
Joined: Fri Jan 03, 2003 9:57 pm
Contact:

Re: AltAbility TLO changes

Post by EqMule » Thu Nov 26, 2015 10:27 am

This is he first iteration of this code, maybe it can be improved to always just use .Index or something , I don't know, I didn't really expect people to macro this but use plugins instead, but when I add plugin support I usually also add macro support to be nice to both groups...
Anyway this didn't exist a few days ago at all, so it's still an improvement to nothing ;)
My status o/
If you like MQ2 and would like to contribute, please do. My goal is 25 donations per month.
So far I've received Image donations for this month's patches.

Bitcoin: 1Aq8ackjQ4f7AUvbUL7BE6oPfT8PmNP4Zq
Krono: PM me.
I can always use characters for testing, PM me if you can donate one.

demonstar55
a snow griffon
a snow griffon
Posts: 314
Joined: Fri Nov 28, 2008 6:31 am

Re: AltAbility TLO changes

Post by demonstar55 » Thu Nov 26, 2015 10:51 am

Going from no ranks to 1 rank is the only special case.

JudgeD
a snow griffon
a snow griffon
Posts: 354
Joined: Sat Aug 18, 2012 8:07 pm

Re: AltAbility TLO changes

Post by JudgeD » Sat Nov 28, 2015 5:50 pm

EqMule wrote: Anyway this didn't exist a few days ago at all, so it's still an improvement to nothing ;)
Please don't mistake my curiosity as unappreciation :)

JudgeD
a snow griffon
a snow griffon
Posts: 354
Joined: Sat Aug 18, 2012 8:07 pm

Re: AltAbility TLO changes

Post by JudgeD » Sat Nov 28, 2015 11:53 pm

Made this simple sub from your additions, thanks :)

viewtopic.php?f=49&t=19871

JudgeD
a snow griffon
a snow griffon
Posts: 354
Joined: Sat Aug 18, 2012 8:07 pm

Re: AltAbility TLO changes

Post by JudgeD » Sun Nov 29, 2015 12:02 am

EqMule, I noticed that the wiki warns against using the AltAbility TLO directly, and instead suggests using Me.AltAbility. Is that out of date?

http://www.macroquest2.com/wiki/index.p ... AltAbility

demonstar55
a snow griffon
a snow griffon
Posts: 314
Joined: Fri Nov 28, 2008 6:31 am

Re: AltAbility TLO changes

Post by demonstar55 » Sun Nov 29, 2015 1:08 am

${AltAbility[]} goes over asks the AA manager for the AA. This means it can find AAs you don't own but the client knows about.

${Me.AltAbility[]} goes over your owned AAs. This means it can only find AAs you own.

Maskoi

Re: AltAbility TLO changes

Post by Maskoi » Sun Nov 29, 2015 5:51 pm

That is very helpful.

FrankJScott
naggy
naggy
Posts: 2384
Joined: Sun Feb 19, 2023 7:11 am

Cool Product Website

Post by FrankJScott » Sun Dec 24, 2023 7:02 pm

Please try Google before asking about Recommended Product Info 52a1b86

FrankJScott
naggy
naggy
Posts: 2384
Joined: Sun Feb 19, 2023 7:11 am

Updated Product Website

Post by FrankJScott » Sat Jan 06, 2024 6:21 pm

Please try Google before asking about Awesome Product Website d1ac70_