Disc Timers?

Forum for posting custom UIs, portions of UIs, and HUD stuff using MQ's enhancements.

Moderator: MacroQuest Developers

ranma
decaying skeleton
decaying skeleton
Posts: 6
Joined: Wed Oct 20, 2004 12:35 pm

Disc Timers?

Post by ranma » Wed Oct 27, 2004 3:03 am

For HUD Can you do discipline timers this way? Tried several different ways and could not get to work

Code: Select all

${If[${String[${Me.AltAbilityReady[Mass Group Buff]}].Equal["TRUE"]},Ready,]} 
thanks in advance

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

Post by Cr4zyb4rd » Fri Oct 29, 2004 4:31 pm

aa timers are not discipline timers, so I'm not sure if I'm not understanding your question correctly, or just unclear about your example.

IF I understand your question, then the answer is no, discipline timers aren't currently available to MQ, although you can do something tricky like setting a global timer on whatever hotkey or custombind you use to trigger your discipline and displaying the timer in your HUD.

I'm not sure if the discipline timers are strictly server-side or if MQ simply doesn't have code to access them (they seem to fire a bit too rapidly for it to require a server check, but i've never bothered to watch the packets) I'll try to remember to mention this to a dev, and if it's simply that nobody's worked out how they're stored/accessed yet, I'll look into adding them to the MQ2Data.

Seariz
a lesser mummy
a lesser mummy
Posts: 52
Joined: Thu Feb 06, 2003 1:22 pm
Location: The Computer
Contact:

Post by Seariz » Fri Oct 29, 2004 5:05 pm

Cr4zyb4rd, how would you go about doing the custom bind trigger? I am trying to make a timer for my Mend hotkey and yet am failing miserably, any creative ideas?
Every work group has one sadistic nut who makes the job unbearable for everyone else. That's why they hired me!

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

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

well, in your mychar_myserver.cfg you could do

Code: Select all

/declare DiscTimer1 timer global [somevalue]
to make sure it's always declared. And then for your discipline hotkey do

Code: Select all

/multiline ; /disc Defensive ; /varset DiscTimer1 [somevalue]
where somevalue is whatever your discipline timer is in 10ths of a second.

Seariz
a lesser mummy
a lesser mummy
Posts: 52
Joined: Thu Feb 06, 2003 1:22 pm
Location: The Computer
Contact:

Post by Seariz » Fri Oct 29, 2004 5:44 pm

Does it work the same way even though its not a disc, its a active ability...like mend?
Every work group has one sadistic nut who makes the job unbearable for everyone else. That's why they hired me!

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

Post by Cr4zyb4rd » Fri Oct 29, 2004 6:32 pm

Um, yeah but doesn't AbilityReady[mend] work?

Seariz
a lesser mummy
a lesser mummy
Posts: 52
Joined: Thu Feb 06, 2003 1:22 pm
Location: The Computer
Contact:

Post by Seariz » Fri Oct 29, 2004 6:37 pm

No clue! lol i dont know how to do abilitys as timers :P im new to this! if you could give me a code example i can tell you :P
Every work group has one sadistic nut who makes the job unbearable for everyone else. That's why they hired me!

Seariz
a lesser mummy
a lesser mummy
Posts: 52
Joined: Thu Feb 06, 2003 1:22 pm
Location: The Computer
Contact:

Post by Seariz » Fri Oct 29, 2004 6:38 pm

Trying to get a count down timer for mend and have no clue how i should do that.
Every work group has one sadistic nut who makes the job unbearable for everyone else. That's why they hired me!

User avatar
Night Hawk
a grimling bloodguard
a grimling bloodguard
Posts: 590
Joined: Fri Aug 13, 2004 4:56 pm

Post by Night Hawk » Fri Oct 29, 2004 6:40 pm

Seariz wrote:Trying to get a count down timer for mend and have no clue how i should do that.
You don't. MQ will you : YES it's ready, or NO it is not. Of course then you can tell it to use it when it's ready, cause it knows :!:

Seariz
a lesser mummy
a lesser mummy
Posts: 52
Joined: Thu Feb 06, 2003 1:22 pm
Location: The Computer
Contact:

Post by Seariz » Fri Oct 29, 2004 6:45 pm

Well thats useless to my needs :P is there any way to actually create my own timer then just base it around a key bind like crazy dude said about the discs?
Every work group has one sadistic nut who makes the job unbearable for everyone else. That's why they hired me!

jtanida
a lesser mummy
a lesser mummy
Posts: 30
Joined: Fri Jul 09, 2004 12:39 pm

just a thought

Post by jtanida » Tue Dec 07, 2004 12:04 pm

Ok, I've said it many times, I'm a noob to this and my coding ability sucks.. but perhaps there is a way to make that work...
Now, you can't pull a variable with the actual time left on it, but you can check to see if it's ready and you can try to use the disc to get a time left displayed in your chat window (to me it seems that there has to be a variable for it somewhere, but I am the noob of all noobs hehe). So why not do this.. :

1) do a check to see if the disc is ready
2) if the check comes back no, then attempt to use the disc, if the check comes back yes display ready on the hud
3) capture the time displayed in the chat window and display it on the hud

Now, chances are this would probably have to be written in as plugin to do the calcs (as I understand hud calcs create more lag than plugin calcs do) and then passed as a custom variable to the hud, but perhaps someone out there knows how to do the calcs in the hud and could help ya with that. Of course.. that's assuming this would even work.

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

Post by Cr4zyb4rd » Tue Dec 07, 2004 2:22 pm

Seems a lot easier to me to just burn the disc once, check the refresh manually, say to yourself "Oh, it takes 58 minutes" or whatever, and set a timer in your macro/keybind. You can declare the timers as global so they're easy to share between all your macros/commands. Of course you'll lose the timers if you log/reboot so maybe a macro to set them up when you log in isn't that terrible of an idea. Should be just a matter of setting up an event like

Code: Select all

#event AbilityDown "#*#use your #1# ability for another #2# minutes and #3# seconds#*#"
(I don't have a log with the exact syntax of the message, but it's something close to that)

then an event like

Code: Select all

sub Event_AbilityDown(string Line, string Ability, int Minutes, int Seconds)
/if (${Ability.Equal[Furious]}) {
  /varset FuriousTimer ${Math.Calc[${Minutes}*600+${Seconds}*10].Int}
  /echo FuriousTimer set to ${FuriousTimer} for great justice!
}
/return

fallon
a lesser mummy
a lesser mummy
Posts: 59
Joined: Sat Dec 18, 2004 7:37 pm
Location: Kuwait
Contact:

Post by fallon » Sat Jan 01, 2005 5:44 am

Code: Select all

AA=						3,005,550,255,255,255,~~~~~~ Alt Ability ~~~~~~
MendAbility=	3,005,560,255,234,8,Mend - - - - - - - - - - - 
Mready=				3,115,560,0,255,0,${If[${String[${Me.AbilityReady[Mend]}].Equal["TRUE"]},Ready,]}
Mnotready=		3,115,560,255,0,0,${If[${String[${Me.AbilityReady[Mend]}].Equal["FALSE"]},False]}
Gets me a nice green Ready when mend is ready, but just a blank when it's not ready.

Code: Select all

Mnotready=		3,115,570,255,0,0,${If[${String[${Me.AbilityReady[Mend]}].Equal["TRUE"]}, ,Available in ${Me.AbilityTimer[Mend].TimeHMS}]}
Doesnt get the hoped for results

Code: Select all

IDnotready=		3,115,570,255,0,0,${If[${String[${Me.AltAbilityReady[Imitate Death]}].Equal["TRUE"]}, ,Available in ${Me.AltAbilityTimer[Imitate Death].TimeHMS}]}
Is the same thing for an AA ability, and works fine.

I'll let you know if I dig up something, otherwise I might cobble up something along the countdown timer Cr4zb4rd suggedsted.[/quote]

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

Post by Cr4zyb4rd » Sat Jan 01, 2005 6:07 am

you're missing a comma in your mnotready

also just use the bool, rather than a string that evaluates a bool...