Page 1 of 1

Disc Timers?

Posted: Wed Oct 27, 2004 3:03 am
by ranma
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

Posted: Fri Oct 29, 2004 4:31 pm
by Cr4zyb4rd
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.

Posted: Fri Oct 29, 2004 5:05 pm
by Seariz
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?

Posted: Fri Oct 29, 2004 5:11 pm
by Cr4zyb4rd
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.

Posted: Fri Oct 29, 2004 5:44 pm
by Seariz
Does it work the same way even though its not a disc, its a active ability...like mend?

Posted: Fri Oct 29, 2004 6:32 pm
by Cr4zyb4rd
Um, yeah but doesn't AbilityReady[mend] work?

Posted: Fri Oct 29, 2004 6:37 pm
by Seariz
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

Posted: Fri Oct 29, 2004 6:38 pm
by Seariz
Trying to get a count down timer for mend and have no clue how i should do that.

Posted: Fri Oct 29, 2004 6:40 pm
by Night Hawk
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 :!:

Posted: Fri Oct 29, 2004 6:45 pm
by Seariz
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?

just a thought

Posted: Tue Dec 07, 2004 12:04 pm
by jtanida
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.

Posted: Tue Dec 07, 2004 2:22 pm
by Cr4zyb4rd
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

Posted: Sat Jan 01, 2005 5:44 am
by fallon

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]

Posted: Sat Jan 01, 2005 6:07 am
by Cr4zyb4rd
you're missing a comma in your mnotready

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