Advertisement
Xerik2669

Untitled

Nov 27th, 2017
306
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.09 KB | None | 0 0
  1.  
  2. function(t)
  3. --if frost:
  4. --t1: Cold Heart==20, t2: Cold Heart>=10, t3: Pillar Of Frost<=3
  5. --t4: Unholy Strength
  6. --t7: POF CD > 6, t8: CH >16, t9: POF running, t10: POF off cd
  7. --t11: Obliteration not up
  8. --t12: CH >= 13
  9. --t13: Razorice == 5
  10.  
  11. --The path to the sound clip that will play
  12. local sound_clip = "Interface\AddOns\WeakAuras\PowerAurasMedia\Sounds\ESPARK1.ogg"
  13. --Set this flag to 'false' if we don't want the sound to play
  14. local sound_on = true
  15. --This method plays the sound clip
  16. function playSoundClip ()
  17. PlaySoundFile(sound_clip, "master")
  18. end
  19.  
  20. --Local variable for GCD
  21. local gcd = UnitPowerType'player' == 3 and (UnitBuff("player",GetSpellInfo(13750)) and .8 or 1) or max(1.5/(1 + .01 * UnitSpellHaste'player'), UnitBuff('player', GetSpellInfo(194249)) and .67 or .75)
  22.  
  23. local aura_env = aura_env
  24.  
  25. if GetSpecialization() == 2 and t[11] and t[13] then
  26. --if frost, Oblit not up, razorice == 5
  27. if t[1] then
  28. --20 stacks CH
  29. if t[7] and t[4] then
  30. --if POF on CD for > 6 and UNH STR is up
  31. if sound_on then playSoundClip() end
  32. return true
  33. end
  34.  
  35. if t[9] or t[10] then
  36. --if POF ready, or POF running, (removed t[6] timer condition)
  37. if sound_on then playSoundClip() end
  38. return true
  39. else --need to wait
  40. -- CH at 20 stacks and need to wait 5 seconds rechecking to see if theres a proc otherwise tell to cast
  41. --C_Timer.After(5,function() WeakAuras.ScanEvents("CHAINS_TIMEOUT") end)
  42. end
  43.  
  44. elseif t[8] and t[7] then
  45. -- print("CH>16")
  46.  
  47. if t[4] then --if UH is up
  48. --print("UH up")
  49. -- CH>16, UH < GCD, POF on CD
  50. --UH (53365) Remaining < GCD
  51. local _, _, _, _, _, _, expirationTime = UnitBuff("player", (GetSpellInfo(53365)), nil, "PLAYER")
  52. local remaining = expirationTime - GetTime()
  53. --print("CH>16, UH UP, GCD=", gcd, " remaining=", remaining )
  54. if remaining < gcd then
  55. if sound_on then playSoundClip() end
  56. return true
  57. end
  58. end
  59.  
  60. elseif t[12] and t[4] and IsPlayerSpell(207057) then
  61. --CH>13, Unholy Str is up, Shattering Strikes chosen
  62. if sound_on then playSoundClip() end
  63. return true
  64.  
  65. elseif t[2] then
  66. --print("CH>10")
  67. -->10 stacks and
  68. if t[9] then
  69. --print("POF up")
  70. --POF (51271) remaining < GCD
  71. local _, _, _, _, _, _, expirationTime = UnitBuff("player", (GetSpellInfo(51271)), nil, "PLAYER")
  72. local remaining = expirationTime - GetTime()
  73. -- print("CH>10, POF up, GCD=", gcd, " remaining=", remaining )
  74. if remaining < gcd then
  75. if sound_on then playSoundClip() end
  76. return true
  77. end
  78. end
  79. end
  80.  
  81.  
  82.  
  83. elseif GetSpecialization() == 3 then
  84. --print("UNHOLY")
  85. --if unholy:
  86. --t4: Unholy Strength, t5: master of ghouls
  87. --if t1==20 and (t4 or t5) playsoundfile and return true
  88. if t[1] then --if CH == 20
  89. if sound_on then playSoundClip() end
  90. return true
  91.  
  92. elseif t[8] then --CH > 16
  93.  
  94. if t[4] then --if unholy strength is up (53365)
  95. local _, _, _, _, _, _, expirationTime = UnitBuff("player", (GetSpellInfo(53365)), nil, "PLAYER")
  96. local remaining = expirationTime - GetTime()
  97. -- print("CH>16, UH UP, GCD=", gcd, " remaining=", remaining )
  98.  
  99. if remaining < gcd then --if remaining time on buff is less than GCD
  100. if sound_on then playSoundClip() end
  101. return true
  102. end
  103.  
  104. elseif t[5] then --if master of ghouls is up (246995)
  105. local _, _, _, _, _, _, expirationTime = UnitBuff("player", (GetSpellInfo(246995)), nil, "PLAYER")
  106. local remaining = expirationTime - GetTime()
  107. -- print("CH>16, MoG UP, GCD=", gcd, " remaining=", remaining )
  108. if remaining < gcd then --if remaining time on buff is less than GCD
  109. if sound_on then playSoundClip() end
  110. return true
  111. end
  112. end
  113. end
  114. end
  115. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement