Page 1 of 1

How to tell if there is a combat ability currently running

Posted: Wed Aug 08, 2007 5:28 am
by pw
Apologies if this has been answered somewhere else. I tried search and didn't easily find the answer.

I wanted to be able to check if there was a combat ability currently running so that I didn't try and start a second or third ability running at the same time (which wouldn't work!). The only way to tell seems to be to check for the label text in the combat abilities window being currently set to "No Effect" like this:

Code: Select all

${Window[CombatAbilityWnd].Child[CAW_CombatEffectLabel].Text.Equal[No Effect]}
For a real use of this check, I have the following inside a Combat sub-routine:

Code: Select all

      /if (${Me.CombatAbilityReady[Savage Onslaught Discipline]} && ${Target.PctHPs} > 10 && ${Me.PctEndurance} > 50 && ${Window[CombatAbilityWnd].Child[CAW_CombatEffectLabel].Text.Equal[No Effect]}) {
          /disc Savage Onslaught Discipline
      }
   
      /if (${Me.CombatAbilityReady[Furious Discipline]} && ${Target.PctHPs} > 10 && ${Me.PctEndurance} > 50 && ${Window[CombatAbilityWnd].Child[CAW_CombatEffectLabel].Text.Equal[No Effect]}) {
          /disc Furious Discipline
      }
      
      /if (${Me.CombatAbilityReady[Fellstrike Discipline]} && ${Target.PctHPs} > 10 && ${Me.PctEndurance} > 50 && ${Window[CombatAbilityWnd].Child[CAW_CombatEffectLabel].Text.Equal[No Effect]}) {
          /disc Fellstrike Discipline
      }

Posted: Wed Aug 08, 2007 10:10 am
by jacensolo
As far as I know, there isn't a way to check that, at least not through the Me TLO, which is where I would expect it to be. The only other ways I could think of doing it require way more code than what you're doing, and also less flexibility.

However, that code you're using to check it is a very creative workaround.

Does it still return that info if the combat abilities window is closed? Or do you need to keep it open to get the info?

Posted: Thu Aug 09, 2007 5:51 am
by pw
It *sometimes* works when the window is closed too. :roll:

For reliable use, just Alt+C to get the window up and park it out the way.