Add new code snippets
This commit is contained in:
26
WIP/Atrigan Interrupt/Display.lua
Normal file
26
WIP/Atrigan Interrupt/Display.lua
Normal file
@@ -0,0 +1,26 @@
|
||||
--Display every frame for text
|
||||
--Every frame
|
||||
function()
|
||||
print(aura_env.peopleList[aura_env.currentInterrupt])
|
||||
if aura_env.peopleList[aura_env.currentInterrupt] == UnitName("player") then
|
||||
if UnitCastingInfo("Belac") then
|
||||
local sname = UnitCastingInfo("Belac")
|
||||
if sname == "Phangs of Guilt" then
|
||||
return "Interrupt it reeee"
|
||||
end
|
||||
end
|
||||
if UnitDebuff("player", "Belac's Prisoner") or UnitIsDead("player") then --If is in cage
|
||||
local msg = aura_env.messages["Cannot Interrupt"]
|
||||
local msg = aura_env.encode(msg)
|
||||
SendChatMessage(msg, "RAID")
|
||||
aura_env.currentInterrupt = aura_env.currentInterrupt + 1
|
||||
end
|
||||
if GetTime() < aura_env.interruptTime then --If is on cooldown
|
||||
local msg = aura_env.messages["Cannot Interrupt"]
|
||||
local msg = aura_env.encode(msg)
|
||||
SendChatMessage(msg, "RAID")
|
||||
aura_env.currentInterrupt = aura_env.currentInterrupt + 1
|
||||
end
|
||||
return "You're next"
|
||||
end
|
||||
end
|
||||
40
WIP/Atrigan Interrupt/INIT.lua
Normal file
40
WIP/Atrigan Interrupt/INIT.lua
Normal file
@@ -0,0 +1,40 @@
|
||||
aura_env.interruptTime = 0
|
||||
aura_env.interruptCD = 24
|
||||
aura_env.peopleList = {}
|
||||
aura_env.currentInterrupt = 1
|
||||
local playerClass = UnitClass("player")
|
||||
if playerClass == "Hunter" then
|
||||
aura_env.classInterrupt = "Counter Shot" elseif
|
||||
playerClass == "Mage" then
|
||||
aura_env.classInterrupt = "Counterspell" elseif
|
||||
playerClass == "Warlock" then
|
||||
aura.classInterrupt = "Spell Lock"
|
||||
end
|
||||
aura_env.messages =
|
||||
{
|
||||
["Interrupted"] = 9461,
|
||||
["Cannot Interrupt"] = 9462,
|
||||
["Initialized"] = 9451,
|
||||
["Added to interrupt list"], = 9452,
|
||||
["Cycle Interrupt DEBUG"] = 9551
|
||||
}
|
||||
aura_env.encode = function(msg)
|
||||
local date = date()
|
||||
local localtime = date:match("%d%d%/%d%d%/%d%d%s(%d%d%p%d%d%p%d%d)") --15:37:43
|
||||
local hr = localtime:match("(%d%d)")
|
||||
local min = localtime:match("%d%d%p(%d%d)")
|
||||
|
||||
local retmsg = msg - (hr * min)
|
||||
retmsg = tostring(retmsg)
|
||||
return retmsg
|
||||
end
|
||||
aura_env.decode = function(msg)
|
||||
local date = date()
|
||||
local localtime = date:match("%d%d%/%d%d%/%d%d%s(%d%d%p%d%d%p%d%d)") --15:37:43
|
||||
local hr = localtime:match("(%d%d)")
|
||||
local min = localtime:match("%d%d%p(%d%d)")
|
||||
|
||||
tonumber(msg)
|
||||
local retint = msg + (hr * min)
|
||||
return retint
|
||||
end
|
||||
28
WIP/Atrigan Interrupt/Libs.lua
Normal file
28
WIP/Atrigan Interrupt/Libs.lua
Normal file
@@ -0,0 +1,28 @@
|
||||
[02:39 PM] [Virags DT]: 14:35:39 UNIT_SPELLCAST_INTERRUPTED - (6) table: 000000004830D3C0 --seems to only work on player
|
||||
[02:39 PM] [Virags DT]: 1 - UNIT_SPELLCAST_INTERRUPTED
|
||||
[02:39 PM] [Virags DT]: 2 - player
|
||||
[02:39 PM] [Virags DT]: 3 - Flash of Light
|
||||
[02:39 PM] [Virags DT]: 5 - 3-5-1-0-19750-00000056B2
|
||||
[02:39 PM] [Virags DT]: 6 - 19750
|
||||
|
||||
|
||||
|
||||
[02:40 PM] [Virags DT]: 14:35:50 COMBAT_LOG_EVENT_UNFILTERED - (18) table: 00000000543D23B0 -- realistically the only important one since the only interrupts are outgoing
|
||||
[02:40 PM] [Virags DT]: 1 - COMBAT_LOG_EVENT_UNFILTERED
|
||||
[02:40 PM] [Virags DT]: 2 - 1549632949.728
|
||||
[02:40 PM] [Virags DT]: 3 - SPELL_INTERRUPT
|
||||
[02:40 PM] [Virags DT]: 4 - false
|
||||
[02:40 PM] [Virags DT]: 5 - Player-5-000AD3B6
|
||||
[02:40 PM] [Virags DT]: 6 - Pinkiepiie
|
||||
[02:40 PM] [Virags DT]: 7 - 1297
|
||||
[02:40 PM] [Virags DT]: 8 - 0
|
||||
[02:40 PM] [Virags DT]: 9 - Player-5-000A70EF
|
||||
[02:40 PM] [Virags DT]: 10 - Lilithiy
|
||||
[02:40 PM] [Virags DT]: 11 - 66888
|
||||
[02:40 PM] [Virags DT]: 12 - 0
|
||||
[02:40 PM] [Virags DT]: 13 - 96231
|
||||
[02:40 PM] [Virags DT]: 14 - Rebuke
|
||||
[02:40 PM] [Virags DT]: 15 - 1
|
||||
[02:40 PM] [Virags DT]: 16 - 116
|
||||
[02:40 PM] [Virags DT]: 17 - Frostbolt
|
||||
[02:40 PM] [Virags DT]: 18 - 16
|
||||
18
WIP/Atrigan Interrupt/Trigger1.lua
Normal file
18
WIP/Atrigan Interrupt/Trigger1.lua
Normal file
@@ -0,0 +1,18 @@
|
||||
--The interrupt detection trigger
|
||||
--COMBAT_LOG_EVENT_UNFILTERED
|
||||
function(...)
|
||||
local subevent = select(3, ...)
|
||||
if subevent == "SPELL_INTERRUPT" then
|
||||
local playerName = select(6, ...)
|
||||
local targetName = select(10, ...)
|
||||
local spellName = select(14, ...)
|
||||
local interruptedSpellName = select(17, ...)
|
||||
if playerName == UnitName("player") and targetName == "Belac" and and interruptedSpellName == "Phangs of Guilt" then
|
||||
local msg = aura_env.messages["Interrupted"]
|
||||
local msg = aura_env.encode(msg)
|
||||
SendChatMessage(msg, "RAID")
|
||||
aura_env.currentInterrupt = aura_env.currentInterrupt + 1
|
||||
aura_env.interruptTime = GetTime() + aura_env.interruptCD
|
||||
end
|
||||
end
|
||||
end
|
||||
40
WIP/Atrigan Interrupt/Trigger2.lua
Normal file
40
WIP/Atrigan Interrupt/Trigger2.lua
Normal file
@@ -0,0 +1,40 @@
|
||||
--The encoding trigger
|
||||
--CHAT_MSG_RAID, CHAT_MSG_RAID_LEADER
|
||||
function(_,msg,sender)
|
||||
local sender = string.match(sender, "%a+")
|
||||
local returnMessage = aura_env.decode(msg)
|
||||
if returnMessage == aura_env.messages["Initialized"] then
|
||||
local isfound = 0
|
||||
for k,v in pairs(aura_env.peopleList) do
|
||||
if v == UnitName("player") then
|
||||
isfound = 1
|
||||
break
|
||||
end
|
||||
end
|
||||
if isfound == 0 then
|
||||
aura_env.peopleList[#aura_env.peopleList + 1] = UnitName("player")
|
||||
end
|
||||
local msg = aura_env.messages["Added to interrupt list"]
|
||||
local msg = aura_env.encode(msg)
|
||||
SendChatMessage(msg, "RAID")
|
||||
end
|
||||
if returnMessage == aura_env.messages["Added to interrupt list"] then
|
||||
local isfound = 0
|
||||
for k,v in pairs(aura_env.peopleList) do
|
||||
if v == sender then
|
||||
isfound = 1
|
||||
break
|
||||
end
|
||||
end
|
||||
if isfound == 0 then
|
||||
aura_env.peopleList[#aura_env.peopleList + 1] = sender
|
||||
end
|
||||
end
|
||||
if returnMessage == aura_env.messages["Interrupted"] then
|
||||
aura_env.currentInterrupt = aura_env.currentInterrupt + 1
|
||||
end
|
||||
if returnMessage == aura_env.messages["Cycle Interrupt DEBUG"] then
|
||||
aura_env.currentInterrupt = aura_env.currentInterrupt + 1
|
||||
end
|
||||
return true
|
||||
end
|
||||
15
WIP/Atrigan Interrupt/Trigger3.lua
Normal file
15
WIP/Atrigan Interrupt/Trigger3.lua
Normal file
@@ -0,0 +1,15 @@
|
||||
--Trigger for raid wide initialization
|
||||
--CHAT_MSG_WHISPER
|
||||
function(_,msg,sender)
|
||||
local sender = string.match(sender, "%a+")
|
||||
if sender == "Pinkiepiie" and msg == "init_the_thing_i_guess_101_?" then
|
||||
local msg = aura_env.messages["Initialized"]
|
||||
local msg = aura_env.encode(msg)
|
||||
SendChatMessage(msg, "RAID")
|
||||
end
|
||||
if sender == "Pinkiepiie" and msg == "cycle_interrupt_debug" then
|
||||
local msg = aura_env.messages["Cycle Interrupt DEBUG"]
|
||||
local msg = aura_env.encode(msg)
|
||||
SendChatMessage(msg, "RAID")
|
||||
end
|
||||
end
|
||||
40
WIP/Block.lua
Normal file
40
WIP/Block.lua
Normal file
@@ -0,0 +1,40 @@
|
||||
COMBAT_LOG_EVENT_UNFILTERED
|
||||
function(...)
|
||||
local subevent = select(3, ...)
|
||||
local target = select(10, ...)
|
||||
if subevent == "SWING_DAMAGE" and target == UnitName("player") then
|
||||
local dmg = select(13, ...)
|
||||
local block = select(17, ...) or 0
|
||||
if block > 0 then
|
||||
aura_env.overallBlock = aura_env.overallBlock + block
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
DISPLAY
|
||||
function()
|
||||
local function shorten(val)
|
||||
local function round(var, n)
|
||||
if (n) then
|
||||
var = math.floor((var * 10^n) + 0.5) / (10^n)
|
||||
else
|
||||
var = math.floor(var+0.5)
|
||||
end
|
||||
return var
|
||||
end
|
||||
local n = 2
|
||||
if val < 1e3 then
|
||||
return round(val, n)
|
||||
elseif val > 1e3 and val < 1e6 then
|
||||
return round(val / 1e3, n) .. "k"
|
||||
elseif val > 1e6 and val < 1e9 then
|
||||
return round(val / 1e6, n) .. "M"
|
||||
elseif val > 1e9 then
|
||||
return round(val / 1e9, n) .. "G"
|
||||
end
|
||||
end
|
||||
return shorten(aura_env.overallBlock)
|
||||
end
|
||||
|
||||
INIT
|
||||
aura_env.overallBlock = 0
|
||||
13
WIP/Dargul Timer(UNTESTED).lua
Normal file
13
WIP/Dargul Timer(UNTESTED).lua
Normal file
@@ -0,0 +1,13 @@
|
||||
function()
|
||||
if UnitExists("target") and UnitName("target"):match("Dargul") then
|
||||
local name,_,_,startTimeMS,endTimeMS,= UnitCastingInfo("target")
|
||||
if name == "Molten Crash" then
|
||||
local name,_,_,_,_,expirationTime = UnitBuff("player", "Shield of the Righteous")
|
||||
expirationTime = expirationTime * 1000
|
||||
local time = GetTime() * 1000
|
||||
if endTimeMS > expirationTime then
|
||||
return true
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
70
WIP/Hydra Shot 2.lua
Normal file
70
WIP/Hydra Shot 2.lua
Normal file
@@ -0,0 +1,70 @@
|
||||
--UNIT_AURA
|
||||
--Event that fires off whenever an aura is applied or removed -- probably overkill for this application but it should work relatively fine
|
||||
--Can also use combatlog event for cast success of hydra shot but am unsure if that would work
|
||||
--The basic idea of this setup is to minimize the time it's calculating stuff to make it as efficient, to do that we only enable the aura while hydra shot is active; To find when it is active we get the time when it was cast and add 8 seconds to that (Don't know why 8, previous aura said so)
|
||||
--We find what auras are applied after the cast has begun and see for each if it's the one we're looking for (hydra shot)
|
||||
--Theoretically SHOULD PROBABLY *LIKELY* work but practically probably isn't going to
|
||||
function()
|
||||
if (aura_env.startCast + 12) < GetTime() then
|
||||
local spell = GetSpellInfo(230139) --hydra shot 230139
|
||||
local spell2 = GetSpellInfo(239375) --fish 239375
|
||||
local spell3 = GetSpellInfo(230214) -- tank debuff
|
||||
local j = 0
|
||||
for i = 1, GetNumGroupMembers() do
|
||||
local name = GetRaidRosterInfo(i)
|
||||
if not UnitDebuff(name, spell) and not UnitDebuff(name, spell2) and not UnitDebuff(name, spell3) then
|
||||
if name == UnitName("player") and j < 2 then
|
||||
aura_env.output = "|cffffd00cStar|r"
|
||||
return 0
|
||||
end
|
||||
if name == UnitName("player") and j >= 2 and j < 5 then
|
||||
aura_env.output = "cff4baf1cTriangle|r"
|
||||
return 0
|
||||
end
|
||||
if name == UnitName("player") and j >= 5 and j < 8 then
|
||||
aura_env.output = "cfff6802cCircle|r"
|
||||
return 0
|
||||
end
|
||||
if name == UnitName("player") and j >= 8 and j < 11 then
|
||||
aura_env.output = "cfff0098cDiamond|r"
|
||||
return 0
|
||||
end
|
||||
j = j + 1
|
||||
end
|
||||
end
|
||||
aura_env.output = "Whatever"
|
||||
return 0
|
||||
end
|
||||
end
|
||||
|
||||
--DISPLAY
|
||||
function() --It's more efficient to only return a value every frame instead of calculating for it as well as returning it
|
||||
return aura_env.output
|
||||
end
|
||||
|
||||
--EVERY FRAME TRIGGER
|
||||
--The trigger that will be actually showing the aura
|
||||
function() --Enables the weakaura for 8 seconds after the cast
|
||||
if (aura_env.startCast + 12) < GetTime() then --If the time of cast + 8 seconds is < current time the aura will be shown (aka for the next 8 seconds after the cast)
|
||||
return true
|
||||
else
|
||||
return false
|
||||
end
|
||||
end
|
||||
|
||||
--COMBAT_LOG_EVENT_UNFILTERED
|
||||
function(...) --Enables the weakaura for 8 seconds after the cast
|
||||
local subevent = select(3, ...)
|
||||
if subevent == "SPELL_CAST_START" then --If there was a spell cast (in the combat log)
|
||||
local caster = select(6, ...) --Found who cast it
|
||||
local spell = select(14, ...) --And what was cast
|
||||
if caster:match("Mistress") and spell == "Hydra Shot" then --If the spell is Hydra Shot and Mistress cast it then
|
||||
aura_env.startCast = GetTime() --Get the time when it was cast
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
--INIT
|
||||
--Defines protected variables which are the output and the cast time for the timer
|
||||
aura_env.startCast = 0
|
||||
aura_env.output = ""
|
||||
50
WIP/Hydra Shot.lua
Normal file
50
WIP/Hydra Shot.lua
Normal file
@@ -0,0 +1,50 @@
|
||||
function ()
|
||||
local spell = GetSpellInfo(230139) --hydra shot 230139
|
||||
local spell2 = GetSpellInfo(239375) --fish 239375
|
||||
local spell3 = GetSpellInfo(230214) -- tank debuff
|
||||
local star = "star" --Don't need this, isn't used anywhere
|
||||
local triangle = "triangle" --Don't need this, isn't used anywhere
|
||||
local circle = "circle" --Don't need this, isn't used anywhere
|
||||
local diamond = "diamond" --Don't need this, isn't used anywhere
|
||||
local playerName = UnitName("player")
|
||||
--These empty lines are pissing me off only because I don't do it as such
|
||||
local total = 0 --Don't need this, isn't used anywhere
|
||||
local max = 18 --Don't need this, isn't used anywhere
|
||||
local j = 0
|
||||
|
||||
for i=1, GetNumGroupMembers() do
|
||||
|
||||
local name = GetRaidRosterInfo(i)
|
||||
if (not UnitDebuff(name, spell) and not UnitDebuff(name, spell2) and not UnitDebuff(name, spell3)) then
|
||||
|
||||
if (name == playerName and j<2) then
|
||||
|
||||
return string.format("%s", "|cffffd00cStar") --It is good habbit to close a |c with an |r (basically returns the color to it's default from |c)
|
||||
|
||||
end
|
||||
|
||||
if (name == playerName and j>=2 and j<5) then
|
||||
return string.format("%s", "|cff4baf1cTriangle")
|
||||
|
||||
end
|
||||
|
||||
if (name == playerName and j>=5 and j<8) then
|
||||
return string.format("%s", "|cfff6802cCircle")
|
||||
end
|
||||
|
||||
if (name == playerName and j>=8 and j<11) then
|
||||
return string.format("%s", "|cfff0098cDiamond")
|
||||
end
|
||||
|
||||
j = j+1
|
||||
|
||||
end
|
||||
|
||||
|
||||
end
|
||||
|
||||
return string.format("%s", "Whatever")
|
||||
end
|
||||
|
||||
|
||||
|
||||
5
WIP/Icey AP/C AP.lua
Normal file
5
WIP/Icey AP/C AP.lua
Normal file
@@ -0,0 +1,5 @@
|
||||
function()
|
||||
local AP = UnitPower("player")
|
||||
local maxAP = UnitPowerMax("player")
|
||||
return maxAP - AP, maxAP, 1
|
||||
end
|
||||
27
WIP/Icey AP/Cast AP.lua
Normal file
27
WIP/Icey AP/Cast AP.lua
Normal file
@@ -0,0 +1,27 @@
|
||||
function()
|
||||
local AP = UnitPower("player") --Get astral power and max power
|
||||
local maxAP = UnitPowerMax("player")
|
||||
local APgains = --Define AP gained by spells
|
||||
{
|
||||
["New Moon"] = 10,
|
||||
["Half Moon"] = 20,
|
||||
["Full Moon"] = 40,
|
||||
["Lunar Strike"] = 12,
|
||||
["Solar Wrath"] = 8
|
||||
}
|
||||
local buff = UnitBuff("player", "Blessing of Elune") --Find 25% increase if present
|
||||
local casting = UnitCastingInfo("player") --Get spell currently being cast if any
|
||||
if casting then --If there's a spell being cast
|
||||
local plusAP = AP + APgains[casting] --Add AP gained by spell currently cast to current AP to "predict" AP
|
||||
if buff then
|
||||
if casting == "Lunar Strike" or casting == "Solar Wrath" then --If either spell affected by buff is being cast add 25% to it's ap gained
|
||||
local plusAP = AP + APgains[casting]
|
||||
plusAP = math.floor(plusAP + APgains[casting] * 0.25) --Get the 25% of 8 or 12 and add it to 8 or 12
|
||||
end
|
||||
end
|
||||
return maxAP - plusAP, maxAP, 1
|
||||
end
|
||||
if not casting then
|
||||
return maxAP - AP, maxAP, 1
|
||||
end
|
||||
end
|
||||
5
WIP/Icey AP/Pred AP.lua
Normal file
5
WIP/Icey AP/Pred AP.lua
Normal file
@@ -0,0 +1,5 @@
|
||||
function()
|
||||
local AP = UnitPower("player") --Get astral power and max power
|
||||
local maxAP = UnitPowerMax("player")
|
||||
return maxAP - AP, maxAP, 1
|
||||
end
|
||||
30
WIP/Last n spells cast.lua
Normal file
30
WIP/Last n spells cast.lua
Normal file
@@ -0,0 +1,30 @@
|
||||
COMBAT_LOG_EVENT_UNFILTERED
|
||||
function(...)
|
||||
DavesFuckerySpellsCast = {}
|
||||
local subevent = select(3, ...)
|
||||
local caster = --GET CASTER FROM INGAME EVENT
|
||||
local function addSpell(spellname)
|
||||
if #DavesFuckerySpellsCast == aura_env.maxspells then
|
||||
table.remove(DavesFuckerySpellsCast, 1)
|
||||
table.insert(DavesFuckerySpellsCast, spellname)
|
||||
else
|
||||
table.insert(DavesFuckerySpellsCast,spellname)
|
||||
end
|
||||
end
|
||||
if aura_env.casterName ~= "" then
|
||||
if subevent == "SPELL_CAST_SUCCESS" and caster == aura_env.casterName then
|
||||
local spellname = --GET SPELL NAME FROM INGAME EVENT
|
||||
addSpell(spellname)
|
||||
end
|
||||
else
|
||||
if subevent == "SPELL_CAST_SUCCESS" and caster == UnitName(aura_env.casterID) then
|
||||
local spellname = --GET SPELL NAME FROM INGAME EVENT
|
||||
addSpell(spellname)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
INIT
|
||||
aura_env.maxspells = 5
|
||||
aura_env.casterID = "player"
|
||||
aura_env.casterName = ""
|
||||
44
WIP/Nameplate HP Sort.lua
Normal file
44
WIP/Nameplate HP Sort.lua
Normal file
@@ -0,0 +1,44 @@
|
||||
--Nameplate HP order
|
||||
function()
|
||||
local enemies = {}
|
||||
local output = ""
|
||||
for i = 1, 40 do
|
||||
if UnitIsEnemy("nameplate" .. i, "player") and UnitAffectingCombat("nameplate" .. i) then
|
||||
--print(UnitGUID("nameplate" .. i), UnitHealth("nameplate" .. i), UnitHealthMax("nameplate" .. i), (UnitHealth("nameplate" .. i) / UnitHealthMax("nameplate" .. i)) * 100)
|
||||
--local ID = UnitGUID("nameplate" .. i):match("%a+%-%d+%-%d+%-%d+%-%d+%-%d+%-(.+)")
|
||||
--ID = ID:gsub(0, "")
|
||||
--print(ID)
|
||||
enemies[UnitGUID("nameplate" .. i)] = (UnitHealth("nameplate" .. i) / UnitHealthMax("nameplate" .. i)) * 100
|
||||
end
|
||||
end
|
||||
for k,v in pairs(enemies) do
|
||||
--local ID = UnitGUID("target"):match("%a+%-%d+%-%d+%-%d+%-%d+%-%d+%-(.+)")
|
||||
--ID = ID:gsub(0, "")
|
||||
print("Target " .. UnitGUID("target") .. " key " .. k)
|
||||
if k == UnitGUID("target") then
|
||||
print("GREEN")
|
||||
output = "|cFF00FF00" .. output .. k .. " " .. v .. "|r\n"
|
||||
else
|
||||
print("WHITE")
|
||||
output = "|cFFFFFFFF" .. output .. k .. " " .. v .. "|r\n"
|
||||
end
|
||||
end
|
||||
return output
|
||||
end
|
||||
|
||||
|
||||
local enemies =
|
||||
{
|
||||
["Creature-0-5-1220-0-109349-0000002871"] = 17,
|
||||
["Creature-0-5-1220-0-109349-0000002870"] = 13
|
||||
}
|
||||
local target = "Creature-0-5-1220-0-109349-0000002871"
|
||||
local output = ""
|
||||
for k,v in pairs(enemies) do
|
||||
if target == k then
|
||||
output = output .. k .. " " .. v .. " GREEN\n"
|
||||
else
|
||||
output = output .. k .. " " .. v .. "\n"
|
||||
end
|
||||
end
|
||||
print(output)
|
||||
16
WIP/Premade Automation.lua
Normal file
16
WIP/Premade Automation.lua
Normal file
@@ -0,0 +1,16 @@
|
||||
function()
|
||||
C_LFGList.Search(2, "")
|
||||
numResults, resultIDTable = C_LFGList.GetSearchResults();
|
||||
print(numResults, resultIDTable)
|
||||
for k,v in pairs(resultIDTable) do
|
||||
--local _,_,name,comment,_,iLvl,_,_,_,_,_,leaderName,numMembers = C_LFGList.GetSearchResultInfo(v);
|
||||
for i = 1, 40 do
|
||||
local tempvar = ""
|
||||
tempvar = select(i, C_LFGList.GetSearchResultInfo(v))
|
||||
if tempvar ~= nil then
|
||||
print(tempvar, i)
|
||||
end
|
||||
end
|
||||
print("")
|
||||
end
|
||||
end
|
||||
14
WIP/Reply to MOVE.lua
Normal file
14
WIP/Reply to MOVE.lua
Normal file
@@ -0,0 +1,14 @@
|
||||
CHAT_MSG_PARTY, CHAT_MSG_PARTY_LEADER
|
||||
function(_,msg,source)
|
||||
local responses =
|
||||
{
|
||||
""
|
||||
}
|
||||
if source ~= UnitName("player") then
|
||||
msg:lower()
|
||||
if msg:match("move") then
|
||||
local id = math.random(1, #responses)
|
||||
SendChatMessage(responses[id], "PARTY")
|
||||
end
|
||||
end
|
||||
end
|
||||
2962
WIP/Some Premade Documentation.lua
Normal file
2962
WIP/Some Premade Documentation.lua
Normal file
File diff suppressed because it is too large
Load Diff
60
WIP/Some next gen shit.lua
Normal file
60
WIP/Some next gen shit.lua
Normal file
@@ -0,0 +1,60 @@
|
||||
/run if not IsQuestFlaggedCompleted(39399) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 54.3 81.0 Akrrilo"); end
|
||||
/run if not IsQuestFlaggedCompleted(38430) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 53.0 40.6 Argosh the Destroyer"); end
|
||||
/run if not IsQuestFlaggedCompleted(38609) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 34.9 47.1 Belgork"); end
|
||||
/run if not IsQuestFlaggedCompleted(38262) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 23.8 51.9 Bilkor the Thrower"); end
|
||||
/run if not IsQuestFlaggedCompleted(38696) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 50.0 74.0 Bleeding Hollow Horror"); end
|
||||
/run if not IsQuestFlaggedCompleted(38266) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 21.2 42.2 Bloodhunter Zulk"); end
|
||||
/run if not IsQuestFlaggedCompleted(38209) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 40.7 69.8 Bramblefell"); end
|
||||
/run if not IsQuestFlaggedCompleted(38589) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 57.4 67.9 Broodlord Ixkor"); end
|
||||
/run if not IsQuestFlaggedCompleted(38820) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 48.0 57.2 Captain Grok'mar"); end
|
||||
/run if not IsQuestFlaggedCompleted(38756) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 35.6 79.9 Captain Ironbeard"); end
|
||||
/run if not IsQuestFlaggedCompleted(38031) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 30.9 68.3 Ceraxas"); end
|
||||
/run if not IsQuestFlaggedCompleted(37990) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 44.4 37.3 Cindral the Wildfire"); end
|
||||
/run if not IsQuestFlaggedCompleted(38746) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 15.2 54.5 Commander Krag'goth"); end
|
||||
/run if not IsQuestFlaggedCompleted(38749) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 51.0 46.0 Commander Org'mok"); end
|
||||
/run if not IsQuestFlaggedCompleted(38265) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 23.5 46.8 Dorg the Bloody"); end
|
||||
/run if not IsQuestFlaggedCompleted(38736) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 19.8 53.6 Driss Vile"); end
|
||||
/run if not IsQuestFlaggedCompleted(38264) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 25.1 46.6 Drivnul"); end
|
||||
/run if not IsQuestFlaggedCompleted(38411) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 49.5 36.5 Executor Riloth"); end
|
||||
/run if not IsQuestFlaggedCompleted(39379) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 54.3 81.0 Eyepiercer"); end
|
||||
/run if not IsQuestFlaggedCompleted(38775) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 28.7 51.0 Felbore"); end
|
||||
/run if not IsQuestFlaggedCompleted(38634) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 45.8 47.0 Felsmith Damorka"); end
|
||||
/run if not IsQuestFlaggedCompleted(38211) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 52.0 26.4 Felspark"); end
|
||||
/run if not IsQuestFlaggedCompleted(38604) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 63.2 80.0 Gloomtalon"); end
|
||||
/run if not IsQuestFlaggedCompleted(38764) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 34.5 78.3 Glub'glok"); end
|
||||
/run if not IsQuestFlaggedCompleted(38709) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 33.3 35.8 Gorabosh"); end
|
||||
/run if not IsQuestFlaggedCompleted(38400) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 47.5 42.3 Grand Warlock Nethekurse"); end
|
||||
/run if not IsQuestFlaggedCompleted(38750) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 15.9 59.7 Grannok"); end
|
||||
/run if not IsQuestFlaggedCompleted(39046) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 39.6 32.6 Harbormaster Korak"); end
|
||||
/run if not IsQuestFlaggedCompleted(38026) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 31.5 73.5 Imp-Master Valessa"); end
|
||||
/run if not IsQuestFlaggedCompleted(38030) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 26 8 76.1 Jax'zor"); end
|
||||
/run if not IsQuestFlaggedCompleted(38605) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 52.0 83.8 Krell the Serene"); end
|
||||
/run if not IsQuestFlaggedCompleted(38825) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 39.6 68.4 Kris'kar the Unredeemed"); end
|
||||
/run if not IsQuestFlaggedCompleted(38029) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 32.5 74.0 Lady Oran"); end
|
||||
/run if not IsQuestFlaggedCompleted(38726) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 52.4 62.5 Magwia"); end
|
||||
/run if not IsQuestFlaggedCompleted(38032) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 25.5 79.2 Mistress Thavra"); end
|
||||
/run if not IsQuestFlaggedCompleted(38580) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 53.0 20.0 Overlord Ma'gruth"); end
|
||||
/run if not IsQuestFlaggedCompleted(38557) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 53.6 21.6 Painmistress Selora"); end
|
||||
/run if not IsQuestFlaggedCompleted(38282) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 16.8 48.8 Podlord Wakkawam"); end
|
||||
/run if not IsQuestFlaggedCompleted(38457) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 56.7 24.7 Putre'thar"); end
|
||||
/run if not IsQuestFlaggedCompleted(38034) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 16.8 44.7 Rasthe"); end
|
||||
/run if not IsQuestFlaggedCompleted(38496) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 26.3 54.9 Relgor"); end
|
||||
/run if not IsQuestFlaggedCompleted(39400) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 54.3 81.0 Rendarr"); end
|
||||
/run if not IsQuestFlaggedCompleted(38631) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 43.0 73.9 Rendrak"); end
|
||||
/run if not IsQuestFlaggedCompleted(38263) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 20.5 49.8 Rogond the Tracker"); end
|
||||
/run if not IsQuestFlaggedCompleted(37953) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 43.0 36.9 Sergeant Mor'grak"); end
|
||||
/run if not IsQuestFlaggedCompleted(38812) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 49.7 61.2 Shadowthrash"); end
|
||||
/run if not IsQuestFlaggedCompleted(38600) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 62.2 73.0 Soulslicer"); end
|
||||
/run if not IsQuestFlaggedCompleted(38700) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 65.2 37.0 Steelsnout"); end
|
||||
/run if not IsQuestFlaggedCompleted(38628) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 40.5 79.2 Sylissa"); end
|
||||
/run if not IsQuestFlaggedCompleted(38752) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 16.1 57.4 Szirek the Twisted"); end
|
||||
/run if not IsQuestFlaggedCompleted(38597) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 48.9 73.5 The Blackfang"); end
|
||||
/run if not IsQuestFlaggedCompleted(38654) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 34.9 72.5 The Goreclaw"); end
|
||||
/run if not IsQuestFlaggedCompleted(38751) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 13.0 57.0 The Iron Houndmaster"); end
|
||||
/run if not IsQuestFlaggedCompleted(38632) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 37.0 72.0 The Night Haunter"); end
|
||||
/run if not IsQuestFlaggedCompleted(38747) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 13.4 58.6 Tho'gar Gorefist"); end
|
||||
/run if not IsQuestFlaggedCompleted(38620) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 34.1 44 3 Thromma the Gutslicer"); end
|
||||
/run if not IsQuestFlaggedCompleted(37937) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 27.6 32.8 Varyx the Damned"); end
|
||||
/run if not IsQuestFlaggedCompleted(38579) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 60.0 21.2 Xanzith the Everlasting"); end
|
||||
/run if not IsQuestFlaggedCompleted(38207) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 48.4 28.6 Zeter'el"); end
|
||||
/run if not IsQuestFlaggedCompleted(39045) then SlashCmdList.TOMTOM_WAY("Tanaan Jungle 37.0 32.8 Zoug the Heavy"); end
|
||||
30
WIP/Swelter.lua
Normal file
30
WIP/Swelter.lua
Normal file
@@ -0,0 +1,30 @@
|
||||
COMBAT_LOG_EVENT_UNFILTERED
|
||||
function(...)
|
||||
local event = select(3, ...)
|
||||
aura_env.spell = select(14, ...)
|
||||
aura_env.target = select(10, ...)
|
||||
if aura_env.target == UnitName("player") and aura_env.spell == "Swelter" and event == "SPELL_AURA_APPLIED" then
|
||||
aura_env.startTime = GetTime()
|
||||
end
|
||||
end
|
||||
|
||||
DURATION
|
||||
function()
|
||||
print(GetTime() - aura_env.startTime)
|
||||
if UnitBuff("player", "Swelter") then
|
||||
print("STEP TWO")
|
||||
return GetTime() - aura_env.startTime, 3, 1
|
||||
elseif
|
||||
GetTime() - aura_env.startTime <= 10 then
|
||||
print("STEP THREE")
|
||||
return GetTime() - aura_env.startTime, 10, 1
|
||||
end
|
||||
if GetTime() - aura_env.startTime > 10 then
|
||||
print("STEP FOUR")
|
||||
return 1, 1, 1
|
||||
end
|
||||
end
|
||||
|
||||
aura_env.spell = ""
|
||||
aura_env.target = ""
|
||||
aura_env.startTime = 0
|
||||
34
WIP/TODO.lua
Normal file
34
WIP/TODO.lua
Normal file
@@ -0,0 +1,34 @@
|
||||
"TODO"
|
||||
make raid loot work somehow; filo register with table.insert remove
|
||||
|
||||
string.byte() *H M M M M M M*
|
||||
|
||||
TSU for rep bars
|
||||
|
||||
"More difficult than expected"
|
||||
sang for hp<2% or smth OR sort by HP %
|
||||
|
||||
"Done maybe?"
|
||||
tank alerts like in 7.1.5 but without focus using GroupRoleAssigned with neat list for debuffs :> --Done maybe
|
||||
|
||||
dargul timer for shield
|
||||
|
||||
"Done"
|
||||
judmgnet of light on focus
|
||||
macro for cast and focus if no focus
|
||||
aura for judgment code
|
||||
use ilterendi
|
||||
|
||||
average melee hit during combat
|
||||
|
||||
last n melee color by average -- using tohex maybe and maybe color function
|
||||
|
||||
Arcway trinket auras for stacks and shield by using aura triggers for spell ids and 2 auras
|
||||
|
||||
prydaz for time and absorb (with absorb % and abs)
|
||||
|
||||
SPAWN TIMERS for herberino by using timer for herbs on cooldown (in seperate array) then insert into waypoint array
|
||||
|
||||
rework last n melee hits with proper filo register
|
||||
|
||||
make a proper judgment/hotp bar thing with code
|
||||
76
WIP/Tank Stack Alerts(UNTESTED).lua
Normal file
76
WIP/Tank Stack Alerts(UNTESTED).lua
Normal file
@@ -0,0 +1,76 @@
|
||||
--DISPLAY
|
||||
function()
|
||||
return aura_env.stacks
|
||||
end
|
||||
|
||||
--EVERY FRAME TRIGGER
|
||||
function()
|
||||
if aura_env.tank ~= "" then
|
||||
for k,v in pairs(aura_env.spells) do
|
||||
if UnitDebuff("target", k) ~= nil then
|
||||
local _,_,_,stacks,_,dur,exptime = UnitDebuff("target", k)
|
||||
if v > 1 and stacks > v then
|
||||
aura_env.stacks = stacks
|
||||
aura_env.exptime = exptime
|
||||
aura_env.dur = dur
|
||||
return true
|
||||
end
|
||||
if v == 1 then
|
||||
aura_env.exptime = exptime
|
||||
aura_env.dur = dur
|
||||
return true
|
||||
end
|
||||
if v == 0 then
|
||||
local _,_,starttime,exptime = UnitCastingInfo("boss1")
|
||||
aura_env.exptime = exptime
|
||||
aura_env.dur = exptime - starttime
|
||||
return true
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
--GROUP_ROSTER_UPDATE
|
||||
function()
|
||||
aura_env.tank = ""
|
||||
for i = 1, GetNumGroupMembers() do --Find other tank
|
||||
if UnitGroupRolesAssigned("raid" .. i) == "TANK" and UnitName("raid" .. i) ~= UnitName("player") then
|
||||
aura_env.tank = UnitName("raid" .. i)
|
||||
print(aura_env.tank, i)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
--DURATION TRIGGER
|
||||
function()
|
||||
print(aura_env.dur, aura_env.exptime)
|
||||
return aura_env.dur, aura_env.exptime, 1
|
||||
end
|
||||
|
||||
--INIT
|
||||
aura_env.tank = ""
|
||||
aura_env.stacks = 0
|
||||
aura_env.exptime = 0
|
||||
aura_env.spells =
|
||||
{
|
||||
--NH
|
||||
["Arcane Slash"] = 2,
|
||||
["Annihilate"] = 2,
|
||||
["Feast of Blood"] = 1,
|
||||
["Recursive Strikes"] = 7,
|
||||
["Gravitational Pull"] = 1,
|
||||
["Ablating Explosion"] = 1,
|
||||
["Bonds of Fel"] = 0,
|
||||
["Empowered Bonds of Fel"] = 0,
|
||||
--ToS
|
||||
["Burning Armor"] = 1,
|
||||
["Jagged Abrasion"] = 5,
|
||||
["Judgment of Light"] = 1,
|
||||
}
|
||||
for i = 1, GetNumGroupMembers() do --Find other tank
|
||||
if UnitGroupRolesAssigned("raid" .. i) == "TANK" and UnitName("raid" .. i) ~= UnitName("player") then
|
||||
aura_env.tank = UnitName("raid" .. i)
|
||||
print(aura_env.tank, i)
|
||||
end
|
||||
end
|
||||
568
WIP/ToDissect.lua
Normal file
568
WIP/ToDissect.lua
Normal file
@@ -0,0 +1,568 @@
|
||||
if select(2, UnitClass("player")) ~= "DRUID" then return end
|
||||
local damageTable = {}
|
||||
local updateInterval = 0.1
|
||||
local eventIndex = 0
|
||||
local playerGUID
|
||||
local timeElapsed = 0
|
||||
local damageTP5S = 0
|
||||
local idFR = 22842
|
||||
local anouncedHealing = 0
|
||||
|
||||
local lowTransparency = 0.7
|
||||
local mediumTransparency = 0.5
|
||||
local highTransparency = 0.3
|
||||
|
||||
settingsFR = {}
|
||||
|
||||
local frenzyRegenFrame = CreateFrame("Frame", "frenzyRegenFrame", UIParent)
|
||||
frenzyRegenFrame:SetSize(100, 26)
|
||||
frenzyRegenFrame:ClearAllPoints()
|
||||
frenzyRegenFrame:SetPoint("CENTER", UIParent)
|
||||
frenzyRegenFrame:SetBackdrop({
|
||||
bgFile = "Interface\\Tooltips\\UI-Tooltip-Background", tile = true, tileSize = 16,
|
||||
edgeFile = "Interface\\Tooltips\\UI-Tooltip-Border", edgeSize = 12,
|
||||
insets = {left = 3, right = 3, top = 3, bottom = 3, },
|
||||
})
|
||||
frenzyRegenFrame:SetBackdropColor(0, 0, 0, 0.4)
|
||||
frenzyRegenFrame:SetBackdropBorderColor(0, 0, 0, 1)
|
||||
|
||||
frenzyRegenFrame:RegisterEvent("COMBAT_LOG_EVENT_UNFILTERED")
|
||||
frenzyRegenFrame:RegisterEvent("ADDON_LOADED")
|
||||
frenzyRegenFrame:RegisterEvent("ACTIVE_TALENT_GROUP_CHANGED")
|
||||
frenzyRegenFrame:RegisterEvent("UPDATE_SHAPESHIFT_FORM")
|
||||
frenzyRegenFrame:RegisterEvent("PLAYER_REGEN_DISABLED");
|
||||
frenzyRegenFrame:RegisterEvent("PLAYER_REGEN_ENABLED")
|
||||
frenzyRegenFrame:RegisterEvent("ARTIFACT_UPDATE")
|
||||
frenzyRegenFrame:RegisterEvent("PET_BATTLE_CLOSE")
|
||||
frenzyRegenFrame:RegisterEvent("PET_BATTLE_OPENING_START")
|
||||
|
||||
frenzyRegenFrame:EnableMouse(true)
|
||||
frenzyRegenFrame:SetMovable(true)
|
||||
frenzyRegenFrame:RegisterForDrag("LeftButton")
|
||||
frenzyRegenFrame:SetScript("OnDragStart", frenzyRegenFrame.StartMoving)
|
||||
frenzyRegenFrame:SetScript("OnDragStop", function(self)
|
||||
self:StopMovingOrSizing()
|
||||
settingsFR.XPos = self:GetLeft()
|
||||
settingsFR.YPos = self:GetBottom()
|
||||
end)
|
||||
|
||||
frenzyRegenFrame.damageTakenBar = CreateFrame("StatusBar", nil, frenzyRegenFrame)
|
||||
frenzyRegenFrame.damageTakenBar:SetPoint("TOPLEFT", 3, -3)
|
||||
frenzyRegenFrame.damageTakenBar:SetPoint("TOPRIGHT", -3, -3)
|
||||
frenzyRegenFrame.damageTakenBar:SetHeight(20)
|
||||
frenzyRegenFrame.damageTakenBar:SetStatusBarTexture("Interface\\TargetingFrame\\UI-StatusBar")
|
||||
frenzyRegenFrame.damageTakenBar:GetStatusBarTexture():SetHorizTile(false)
|
||||
frenzyRegenFrame.damageTakenBar:GetStatusBarTexture():SetVertTile(false)
|
||||
frenzyRegenFrame.damageTakenBar:SetMinMaxValues(0, 100)
|
||||
frenzyRegenFrame.damageTakenBar:SetStatusBarColor(0, 0.65, 0)
|
||||
|
||||
frenzyRegenFrame.damageTakenBar.bg = frenzyRegenFrame.damageTakenBar:CreateTexture(nil, "BACKGROUND")
|
||||
frenzyRegenFrame.damageTakenBar.bg:SetTexture("Interface\\TARGETINGFRAME\\UI-StatusBar")
|
||||
frenzyRegenFrame.damageTakenBar.bg:SetAllPoints(true)
|
||||
frenzyRegenFrame.damageTakenBar.bg:SetVertexColor(0, 0.35, 0)
|
||||
|
||||
frenzyRegenFrame.damageTakenBar.value = frenzyRegenFrame.damageTakenBar:CreateFontString(nil, "OVERLAY")
|
||||
frenzyRegenFrame.damageTakenBar.value:SetPoint("CENTER", frenzyRegenFrame.damageTakenBar, "CENTER", 4, 0)
|
||||
frenzyRegenFrame.damageTakenBar.value:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
|
||||
frenzyRegenFrame.damageTakenBar.value:SetJustifyH("LEFT")
|
||||
frenzyRegenFrame.damageTakenBar.value:SetShadowOffset(1, -1)
|
||||
frenzyRegenFrame.damageTakenBar.value:SetTextColor(0, 1, 0)
|
||||
|
||||
function frenzyRegenFrame:getShortNumber(num)
|
||||
if settingsFR.shortNumFlag then
|
||||
if not num then
|
||||
return 0
|
||||
elseif num >= 1e6 then
|
||||
return format("%.1fM", num / 1e6)
|
||||
elseif num >= 1e3 then
|
||||
return format("%.1fK", num / 1e3)
|
||||
else
|
||||
return format("%d", num)
|
||||
end
|
||||
else
|
||||
return format("%d", num)
|
||||
end
|
||||
end
|
||||
|
||||
function frenzyRegenFrame:countHealing()
|
||||
maxHP = UnitHealthMax("player")
|
||||
|
||||
versatilityBonus = GetCombatRatingBonus(CR_VERSATILITY_DAMAGE_DONE) + GetVersatilityBonus(CR_VERSATILITY_DAMAGE_DONE)
|
||||
expectedHealing = math.max(maxHP * 0.05, damageTP5S * 0.5) * (1 + versatilityBonus / 100)
|
||||
legendaryHealing = 0
|
||||
|
||||
if IsEquippedItem(137025) and settingsFR.legendaryFlag then -- Skysec's Hold
|
||||
legendaryHealing = maxHP * 0.12 * (1 + versatilityBonus / 100)
|
||||
end
|
||||
|
||||
local t18set = {124246, 124255, 124261, 124267, 124272}
|
||||
local t18items = 0
|
||||
for i = 1, 5, 1 do
|
||||
if IsEquippedItem(t18set[i]) then
|
||||
t18items = t18items + 1
|
||||
end
|
||||
end
|
||||
isT18eq = t18items > 1
|
||||
|
||||
local idx = 1
|
||||
repeat
|
||||
local name, _, _, _, _, _, _, _, _, _, spellID = UnitAura("player", idx, nil, "PLAYER|HELPFUL|CANCELABLE")
|
||||
if spellID and spellID == 213680 then -- Guardian of Elune
|
||||
expectedHealing = expectedHealing * 1.2
|
||||
elseif isT18eq and spellID and spellID == 192081 then -- Ironfur id
|
||||
expectedHealing = expectedHealing * 1.2
|
||||
elseif spellID and spellID == 47788 then -- Guardian Spirit
|
||||
expectedHealing = expectedHealing * 1.4
|
||||
elseif spellID and spellID == 64844 then -- Divine Hymn
|
||||
expectedHealing = expectedHealing * 1.1
|
||||
elseif spellID and spellID == 116849 then -- Life Cocoon
|
||||
expectedHealing = expectedHealing * 1.5
|
||||
elseif spellID and spellID == 199368 then -- Legacy of the Ravencrest
|
||||
expectedHealing = expectedHealing * 4
|
||||
end
|
||||
idx = idx + 1
|
||||
until name == nil
|
||||
|
||||
if IsEquippedItem(128821) then
|
||||
expectedHealing = expectedHealing * (1 + settingsFR.artifactBonus)
|
||||
end
|
||||
|
||||
ratioHP = (expectedHealing + legendaryHealing) / maxHP * 100
|
||||
anouncedHealing = format("Self healing %d%% over 3 sec", ratioHP)
|
||||
|
||||
charges, maxcharges = GetSpellCharges(idFR)
|
||||
if settingsFR.statusTypeFlag == 1 then
|
||||
frenzyRegenFrame.damageTakenBar:SetValue(charges * 100 / maxcharges)
|
||||
else
|
||||
frenzyRegenFrame.damageTakenBar:SetValue(ratioHP)
|
||||
end
|
||||
|
||||
if settingsFR.displayFlag == 0 then
|
||||
frenzyRegenFrame.damageTakenBar.value:SetText(self:getShortNumber(expectedHealing + legendaryHealing))
|
||||
anouncedHealing = format("Self healing %s over 3 sec", self:getShortNumber(expectedHealing + legendaryHealing))
|
||||
elseif settingsFR.displayFlag == 1 then
|
||||
frenzyRegenFrame.damageTakenBar.value:SetText(self:getShortNumber(expectedHealing / 6))
|
||||
else if settingsFR.displayFlag == 2 then
|
||||
frenzyRegenFrame.damageTakenBar.value:SetText(format("%d%%", ratioHP))
|
||||
end
|
||||
end
|
||||
|
||||
if settingsFR.showValueOnlyFlag then
|
||||
transparency = 0
|
||||
frenzyRegenFrame:SetBackdropColor(0, 0, 0, 0)
|
||||
frenzyRegenFrame:SetBackdropBorderColor(0, 0, 0, 0)
|
||||
else
|
||||
transparency = settingsFR.transparencyFlag
|
||||
frenzyRegenFrame:SetBackdropColor(0, 0, 0, 0.4)
|
||||
frenzyRegenFrame:SetBackdropBorderColor(0, 0, 0, 1)
|
||||
end
|
||||
start = GetSpellCooldown(idFR)
|
||||
if start ~= 0 and settingsFR.greyOutFlag then
|
||||
frenzyRegenFrame.damageTakenBar:SetStatusBarColor(0.212, 0.212, 0.212, transparency)
|
||||
frenzyRegenFrame.damageTakenBar.bg:SetVertexColor(0.1, 0.1, 0.1, transparency)
|
||||
frenzyRegenFrame.damageTakenBar.value:SetTextColor(0.5, 0.5, 0.5, settingsFR.transparencyFlag)
|
||||
else
|
||||
frenzyRegenFrame.damageTakenBar:SetStatusBarColor(0, 0.65, 0, transparency / 1.5)
|
||||
if charges < maxcharges and settingsFR.statusTypeFlag == 1 then
|
||||
frenzyRegenFrame.damageTakenBar:SetStatusBarColor(0.6, 0.65, 0, transparency / 1.5)
|
||||
end
|
||||
frenzyRegenFrame.damageTakenBar.bg:SetVertexColor(0, 0.35, 0, transparency)
|
||||
frenzyRegenFrame.damageTakenBar.value:SetTextColor(0, 1, 0, settingsFR.transparencyFlag)
|
||||
end
|
||||
end
|
||||
|
||||
function frenzyRegenFrame:updateVisibility()
|
||||
if IsPlayerSpell(idFR) then
|
||||
self:Show()
|
||||
else
|
||||
self:Hide()
|
||||
return
|
||||
end
|
||||
if C_PetBattles.IsInBattle() then
|
||||
self:Hide()
|
||||
return
|
||||
else
|
||||
self:Show()
|
||||
end
|
||||
if settingsFR.hideOutOfBearFlag then
|
||||
if GetShapeshiftFormID() == 5 then
|
||||
self:Show()
|
||||
else
|
||||
self:Hide()
|
||||
return
|
||||
end
|
||||
end
|
||||
if settingsFR.hideOutOfCombatFlag then
|
||||
if UnitAffectingCombat("player") then
|
||||
self:Show()
|
||||
else
|
||||
self:Hide()
|
||||
end
|
||||
end
|
||||
if settingsFR.ignoreMouseFlag and UnitAffectingCombat("player") then
|
||||
frenzyRegenFrame:EnableMouse(false)
|
||||
else
|
||||
frenzyRegenFrame:EnableMouse(true)
|
||||
end
|
||||
end
|
||||
|
||||
function frenzyRegenFrame:initFlags()
|
||||
if settingsFR.displayFlag == nil then
|
||||
settingsFR.displayFlag = 0;
|
||||
end
|
||||
if settingsFR.greyOutFlag == nil then
|
||||
settingsFR.greyOutFlag = true;
|
||||
end
|
||||
if settingsFR.movableFlag == nil then
|
||||
settingsFR.movableFlag = true;
|
||||
end
|
||||
if settingsFR.shortNumFlag == nil then
|
||||
settingsFR.shortNumFlag = true;
|
||||
end
|
||||
if settingsFR.hideOutOfCombatFlag == nil then
|
||||
settingsFR.hideOutOfCombatFlag = false;
|
||||
end
|
||||
if settingsFR.hideOutOfBearFlag == nil then
|
||||
settingsFR.hideOutOfBearFlag = false;
|
||||
end
|
||||
if settingsFR.legendaryFlag == nil then
|
||||
settingsFR.legendaryFlag = false;
|
||||
end
|
||||
if settingsFR.artifactBonus == nil then
|
||||
settingsFR.artifactBonus = 0;
|
||||
end
|
||||
if settingsFR.transparencyFlag == nil then
|
||||
settingsFR.transparencyFlag = 1;
|
||||
end
|
||||
if settingsFR.ignoreMouseFlag == nil then
|
||||
settingsFR.ignoreMouseFlag = false;
|
||||
end
|
||||
if settingsFR.announceFlag == nil then
|
||||
settingsFR.announceFlag = false;
|
||||
end
|
||||
if settingsFR.announceChannel == nil then
|
||||
settingsFR.announceChannel = "SAY";
|
||||
end
|
||||
if settingsFR.statusTypeFlag == nil then
|
||||
settingsFR.statusTypeFlag = 0;
|
||||
end
|
||||
if settingsFR.showValueOnlyFlag == nil then
|
||||
settingsFR.showValueOnlyFlag = false;
|
||||
end
|
||||
end
|
||||
|
||||
function frenzyRegenFrame:updateArtifactBonus()
|
||||
if IsEquippedItem(128821) then
|
||||
local powers = C_ArtifactUI.GetPowers()
|
||||
if powers ~= nil then
|
||||
for i = 1, #powers do
|
||||
local id, _, rank = C_ArtifactUI.GetPowerInfo(powers[i])
|
||||
if id == 200400 then -- Wildflesh id
|
||||
settingsFR.artifactBonus = rank * 0.05
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
frenzyRegenFrame:SetScript("OnEvent",
|
||||
function(self, event, ...)
|
||||
if event == "ADDON_LOADED" then
|
||||
playerGUID = UnitGUID("player")
|
||||
if settingsFR.XPos then
|
||||
frenzyRegenFrame:ClearAllPoints()
|
||||
frenzyRegenFrame:SetPoint("BOTTOMLEFT", settingsFR.XPos, settingsFR.YPos)
|
||||
end
|
||||
frenzyRegenFrame:initFlags()
|
||||
if not settingsFR.movableFlag then
|
||||
frenzyRegenFrame:SetMovable(false)
|
||||
end
|
||||
frenzyRegenFrame:updateVisibility()
|
||||
elseif self:IsShown() and event == "COMBAT_LOG_EVENT_UNFILTERED" then
|
||||
|
||||
local _, eventType, _, sourceGUID, _, _, _, destGUID = ...
|
||||
if settingsFR.announceFlag and sourceGUID == playerGUID and eventType == "SPELL_CAST_SUCCESS" then
|
||||
local spellId = select(12, ...)
|
||||
if spellId == idFR then -- Frenzied Regeneration
|
||||
SendChatMessage(anouncedHealing, settingsFR.announceChannel, "Common")
|
||||
end
|
||||
end
|
||||
if destGUID == playerGUID then
|
||||
eventIndex = eventIndex + 1
|
||||
if eventType == "SWING_DAMAGE" then
|
||||
local _, _, _, _, _, _, _, _, _, _, _, amount, _, _, _, _, absorbed = ...
|
||||
if absorbed == nil then
|
||||
absorbed = 0;
|
||||
end
|
||||
damageTable[eventIndex] = {time(), amount + absorbed}
|
||||
elseif eventType == "SPELL_DAMAGE" or eventType == "SPELL_PERIODIC_DAMAGE" or eventType == "RANGE_DAMAGE" then
|
||||
local _, _, _, _, _, _, _, _, _, _, _, _, _, _, amount, _, _, _, _, absorbed = ...
|
||||
if absorbed == nil then
|
||||
absorbed = 0;
|
||||
end
|
||||
damageTable[eventIndex] = {time(), amount + absorbed}
|
||||
end
|
||||
end
|
||||
elseif event == "ACTIVE_TALENT_GROUP_CHANGED" or event == "UPDATE_SHAPESHIFT_FORM" or event == "PLAYER_REGEN_DISABLED" or event == "PLAYER_REGEN_ENABLED" or
|
||||
event == "PET_BATTLE_CLOSE" or event == "PET_BATTLE_OPENING_START" then
|
||||
frenzyRegenFrame:updateVisibility()
|
||||
elseif event == "ARTIFACT_UPDATE" then
|
||||
frenzyRegenFrame:updateArtifactBonus()
|
||||
end
|
||||
end)
|
||||
|
||||
frenzyRegenFrame:SetScript("OnUpdate", function(self, elapsed)
|
||||
timeElapsed = timeElapsed + elapsed
|
||||
if timeElapsed >= updateInterval then
|
||||
local t = time() - 5
|
||||
for k, v in pairs(damageTable) do
|
||||
if v[1] <= t then
|
||||
damageTable[k] = nil
|
||||
else
|
||||
damageTP5S = damageTP5S + v[2]
|
||||
end
|
||||
end
|
||||
self:countHealing()
|
||||
damageTP5S = 0
|
||||
timeElapsed = 0
|
||||
end
|
||||
end)
|
||||
|
||||
local dropDown = CreateFrame("Frame", "FRContextMenu", frenzyRegenFrame, "UIDropDownMenuTemplate")
|
||||
UIDropDownMenu_Initialize(dropDown, function(self, level, menuList)
|
||||
local info = UIDropDownMenu_CreateInfo()
|
||||
if (level or 1) == 1 then
|
||||
info.text = " Frame settings"
|
||||
info.notCheckable = true
|
||||
info.hasArrow = true
|
||||
info.value = "position_submenu"
|
||||
UIDropDownMenu_AddButton(info)
|
||||
info.text = " Transparency"
|
||||
info.value = "position_submenu2"
|
||||
UIDropDownMenu_AddButton(info)
|
||||
info.text = " Status bar shows..."
|
||||
info.value = "position_submenu3"
|
||||
UIDropDownMenu_AddButton(info)
|
||||
info.text = " Announce healing..."
|
||||
info.value = "position_submenu4"
|
||||
UIDropDownMenu_AddButton(info)
|
||||
info.hasArrow = false
|
||||
info.isTitle = true
|
||||
info.icon = "Interface\\Common\\UI-TooltipDivider-Transparent"
|
||||
info.tSizeX = 0
|
||||
info.tSizeY = 8
|
||||
info.text = ""
|
||||
info.iconOnly = true
|
||||
info.iconInfo = {tFitDropDownSizeX = true}
|
||||
UIDropDownMenu_AddButton(info)
|
||||
info = UIDropDownMenu_CreateInfo()
|
||||
info.notCheckable = false
|
||||
info.hasArrow = false
|
||||
info.text = "Show total heal"
|
||||
info.func = function() settingsFR.displayFlag = 0 end
|
||||
info.checked = function() return settingsFR.displayFlag == 0 end
|
||||
UIDropDownMenu_AddButton(info)
|
||||
info.text = "Show heal per tick"
|
||||
info.func = function() settingsFR.displayFlag = 1 end
|
||||
info.checked = function() return settingsFR.displayFlag == 1 end
|
||||
UIDropDownMenu_AddButton(info)
|
||||
info.text = "Show % of HP"
|
||||
info.func = function() settingsFR.displayFlag = 2 end
|
||||
info.checked = function() return settingsFR.displayFlag == 2 end
|
||||
UIDropDownMenu_AddButton(info)
|
||||
elseif level == 2 then
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu" then
|
||||
info.text = "Block position"
|
||||
info.func = function() frenzyRegenFrame:SetMovable(not frenzyRegenFrame:IsMovable()) settingsFR.movableFlag = frenzyRegenFrame:IsMovable() end
|
||||
info.checked = function() return not frenzyRegenFrame:IsMovable() end
|
||||
info.isNotRadio = true
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu" then
|
||||
info.text = "Ignore clicks in combat"
|
||||
info.func = function() settingsFR.ignoreMouseFlag = not settingsFR.ignoreMouseFlag frenzyRegenFrame:updateVisibility() end
|
||||
info.checked = function() return settingsFR.ignoreMouseFlag end
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu" then
|
||||
info.hasArrow = false
|
||||
info.isTitle = true
|
||||
info.notCheckable = true
|
||||
info.icon = "Interface\\Common\\UI-TooltipDivider-Transparent"
|
||||
info.tSizeX = 0
|
||||
info.tSizeY = 8
|
||||
info.text = ""
|
||||
info.iconOnly = true
|
||||
info.iconInfo = {tFitDropDownSizeX = true}
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu" then
|
||||
info = UIDropDownMenu_CreateInfo()
|
||||
info.notCheckable = false
|
||||
info.isNotRadio = true
|
||||
info.text = "Grey-out if FR's on cd"
|
||||
info.func = function() settingsFR.greyOutFlag = not settingsFR.greyOutFlag end
|
||||
info.checked = function() return settingsFR.greyOutFlag end
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu" then
|
||||
info.text = "Short numbers format"
|
||||
info.func = function() settingsFR.shortNumFlag = not settingsFR.shortNumFlag end
|
||||
info.checked = function() return settingsFR.shortNumFlag end
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu" then
|
||||
info.hasArrow = false
|
||||
info.isTitle = true
|
||||
info.notCheckable = true
|
||||
info.icon = "Interface\\Common\\UI-TooltipDivider-Transparent"
|
||||
info.tSizeX = 0
|
||||
info.tSizeY = 8
|
||||
info.text = ""
|
||||
info.iconOnly = true
|
||||
info.iconInfo = {tFitDropDownSizeX = true}
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu" then
|
||||
info = UIDropDownMenu_CreateInfo()
|
||||
info.notCheckable = false
|
||||
info.isNotRadio = true
|
||||
info.text = "Include Skysec's Hold"
|
||||
info.func = function() settingsFR.legendaryFlag = not settingsFR.legendaryFlag end
|
||||
info.checked = function() return settingsFR.legendaryFlag end
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu" then
|
||||
info.hasArrow = false
|
||||
info.isTitle = true
|
||||
info.notCheckable = true
|
||||
info.icon = "Interface\\Common\\UI-TooltipDivider-Transparent"
|
||||
info.tSizeX = 0
|
||||
info.tSizeY = 8
|
||||
info.text = ""
|
||||
info.iconOnly = true
|
||||
info.iconInfo = {tFitDropDownSizeX = true}
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu" then
|
||||
info = UIDropDownMenu_CreateInfo()
|
||||
info.notCheckable = false
|
||||
info.text = "Hide when not in Bear form"
|
||||
info.func = function() settingsFR.hideOutOfBearFlag = not settingsFR.hideOutOfBearFlag frenzyRegenFrame:updateVisibility() print("To turn off this setting type '/frshow bear'") end
|
||||
info.checked = function() return settingsFR.hideOutOfBearFlag end
|
||||
info.isNotRadio = true
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu" then
|
||||
info.text = "Hide when out of combat"
|
||||
info.func = function() settingsFR.hideOutOfCombatFlag = not settingsFR.hideOutOfCombatFlag frenzyRegenFrame:updateVisibility() print("To turn off this setting type '/frshow combat'") end
|
||||
info.checked = function() return settingsFR.hideOutOfCombatFlag end
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu2" then
|
||||
info.text = "Show value only"
|
||||
info.func = function() settingsFR.showValueOnlyFlag = not settingsFR.showValueOnlyFlag end
|
||||
info.checked = function() return settingsFR.showValueOnlyFlag end
|
||||
info.isNotRadio = true
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu2" then
|
||||
info.hasArrow = false
|
||||
info.isTitle = true
|
||||
info.notCheckable = true
|
||||
info.icon = "Interface\\Common\\UI-TooltipDivider-Transparent"
|
||||
info.tSizeX = 0
|
||||
info.tSizeY = 8
|
||||
info.text = ""
|
||||
info.iconOnly = true
|
||||
info.iconInfo = {tFitDropDownSizeX = true}
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu2" then
|
||||
info = UIDropDownMenu_CreateInfo()
|
||||
info.text = "OFF"
|
||||
info.notCheckable = false
|
||||
info.func = function() settingsFR.transparencyFlag = 1 end
|
||||
info.checked = function() return settingsFR.transparencyFlag == 1 end
|
||||
info.isNotRadio = false
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu2" then
|
||||
info.text = "Low"
|
||||
info.func = function() settingsFR.transparencyFlag = lowTransparency end
|
||||
info.checked = function() return settingsFR.transparencyFlag == lowTransparency end
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu2" then
|
||||
info.text = "Medium"
|
||||
info.func = function() settingsFR.transparencyFlag = mediumTransparency end
|
||||
info.checked = function() return settingsFR.transparencyFlag == mediumTransparency end
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu2" then
|
||||
info.text = "High"
|
||||
info.func = function() settingsFR.transparencyFlag = highTransparency end
|
||||
info.checked = function() return settingsFR.transparencyFlag == highTransparency end
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu3" then
|
||||
info.text = "% of HP"
|
||||
info.func = function() settingsFR.statusTypeFlag = 0 end
|
||||
info.checked = function() return settingsFR.statusTypeFlag == 0 end
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu3" then
|
||||
info.text = "Number of charges"
|
||||
info.func = function() settingsFR.statusTypeFlag = 1 end
|
||||
info.checked = function() return settingsFR.statusTypeFlag == 1 end
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu4" then
|
||||
info.text = "OFF"
|
||||
info.func = function() settingsFR.announceFlag = false end
|
||||
info.checked = function() return not settingsFR.announceFlag end
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu4" then
|
||||
info.text = "/Say"
|
||||
info.func = function() settingsFR.announceChannel = "SAY" settingsFR.announceFlag = true end
|
||||
info.checked = function() return settingsFR.announceFlag and settingsFR.announceChannel == "SAY" end
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu4" then
|
||||
info.text = "/Yell"
|
||||
info.func = function() settingsFR.announceChannel = "YELL" settingsFR.announceFlag = true end
|
||||
info.checked = function() return settingsFR.announceFlag and settingsFR.announceChannel == "YELL" end
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu4" then
|
||||
info.text = "/Party"
|
||||
info.func = function() settingsFR.announceChannel = "PARTY" settingsFR.announceFlag = true end
|
||||
info.checked = function() return settingsFR.announceFlag and settingsFR.announceChannel == "PARTY" end
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
if UIDROPDOWNMENU_MENU_VALUE == "position_submenu4" then
|
||||
info.text = "/Raid"
|
||||
info.func = function() settingsFR.announceChannel = "RAID" settingsFR.announceFlag = true end
|
||||
info.checked = function() return settingsFR.announceFlag and settingsFR.announceChannel == "RAID" end
|
||||
UIDropDownMenu_AddButton(info, level)
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
frenzyRegenFrame:SetScript("OnMouseDown", function(self, button)
|
||||
if button == "RightButton" then
|
||||
ToggleDropDownMenu(1, nil, dropDown, "cursor", 3, -3)
|
||||
end
|
||||
end)
|
||||
|
||||
SLASH_FRENZYREGEN1 = "/frshow";
|
||||
function SlashCmdList.FRENZYREGEN(msg, editbox)
|
||||
if msg == "bear" then
|
||||
settingsFR.hideOutOfBearFlag = not settingsFR.hideOutOfBearFlag
|
||||
elseif msg == "combat" then
|
||||
settingsFR.hideOutOfCombatFlag = not settingsFR.hideOutOfCombatFlag
|
||||
end
|
||||
frenzyRegenFrame:updateVisibility()
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user