Other Spells to include

3 posts Page 1 of 1
droopy
Posts: 2
Joined: 24 Apr 2019, 06:53


Firstly let me say I love these types of addons, the spell rotations have helped me heaps by increasing my DPS.

So when I started using the addon, i got thinking about how to highlight non offensive spells like Power Word Shield, or other class specific/item specific buffs.

So I have had a look at your code an have added the following, not sure if it is in the right place but : -

MaxDps\Helper.lua

Under Utility Functions, this give me my health as a percent

function MaxDps:PlayerHealth()
local percent = (UnitHealth("player")/UnitHealthMax("player"))*100
return percent
end

MaxDps_Priest\main.lua

I was looking for spells to highlight under Single, AOE or Cleave function: -

CurrentHealth = MaxDps:PlayerHealth();

if CurrentHealth < 25 and CurrentHealth > 10 and currentSpell ~= SH.ShadowMend then
return SH.ShadowMend;
end

if CurrentHealth < 10 and cooldown[SH.Dispersion].ready and currentSpell ~= SH.Dispersion then
return SH.Dispersion;
end

if CurrentHealth < 10 and not cooldown[SH.Dispersion].ready and currentSpell ~= SH.ShadowMend then
return SH.ShadowMend;
end

if not buff[SH.PowerWordFortitude].up and currentSpell ~= SH.PowerWordFortitude then
return SH.PowerWordFortitude;
end

if not buff[SH.PowerWordShield].up and cooldown[SH.PowerWordShield].ready and currentSpell ~= SH.PowerWordShield then
return SH.PowerWordShield;
end

if not buff[SH.VampiricEmbrace].up and cooldown[SH.VampiricEmbrace].ready and currentSpell ~= SH.VampiricEmbrace then
return SH.VampiricEmbrace;
end

if cooldown[SH.Shadowfiend].ready and currentSpell ~= SH.Shadowfiend then
return SH.Shadowfiend;
end

What do you think??

I also added the PowerWordFortitude to the Precombat function.

I'm no expert on lua but can i move the above rotation to a "Customised Spell" function and call it from the 3 functions, cleave, aoe and single etc.....

Drew
droopy
Posts: 2
Joined: 24 Apr 2019, 06:53


Also is there a way to add non spells into th rotation

for example, Falsh on Augment Rune if not buffed.

I also have a Trinket, Pearl Divers compass (158162), that has a use, increase mastery which is the effect "True North " (273935).

I thought something like logic - "If buff not up 273935 and cooldown ready etc, then highlight 158162" but no joy

:-(
Kaminaris
Site Admin
Posts: 409
Joined: 25 Jun 2017, 03:45


Items are not possible currently
3 posts Page 1 of 1
drogie łóżka stolik kawowy stół dębowy rozkładany