update #13
This commit is contained in:
@@ -2001,10 +2001,7 @@ do
|
||||
end
|
||||
end
|
||||
|
||||
function WeakAuras.GetSpellCooldown(id, ignoreRuneCD, showgcd, ignoreSpellKnown, track)
|
||||
if (not spellKnown[id] and not ignoreSpellKnown) then
|
||||
return;
|
||||
end
|
||||
function WeakAuras.GetSpellCooldown(id, ignoreRuneCD, showgcd, track)
|
||||
local startTime, duration, gcdCooldown;
|
||||
if track == "charges" then
|
||||
startTime, duration = spellCdsCharges:FetchSpellCooldown(id)
|
||||
@@ -2031,10 +2028,7 @@ do
|
||||
return startTime, duration, gcdCooldown;
|
||||
end
|
||||
|
||||
function WeakAuras.GetSpellCharges(id, ignoreSpellKnown)
|
||||
if (not spellKnown[id] and not ignoreSpellKnown) then
|
||||
return;
|
||||
end
|
||||
function WeakAuras.GetSpellCharges(id)
|
||||
return spellCounts[id];
|
||||
end
|
||||
|
||||
|
||||
@@ -1835,10 +1835,9 @@ WeakAuras.event_prototypes = {
|
||||
local spellname = %s
|
||||
local ignoreRuneCD = %s
|
||||
local showgcd = %s;
|
||||
local ignoreSpellKnown = %s;
|
||||
local track = %q
|
||||
local startTime, duration, gcdCooldown = WeakAuras.GetSpellCooldown(spellname, ignoreRuneCD, showgcd, ignoreSpellKnown, track);
|
||||
local spellCount = WeakAuras.GetSpellCharges(spellname, ignoreSpellKnown);
|
||||
local startTime, duration, gcdCooldown = WeakAuras.GetSpellCooldown(spellname, ignoreRuneCD, showgcd, track);
|
||||
local spellCount = WeakAuras.GetSpellCharges(spellname);
|
||||
local stacks = (spellCount and spellCount > 0 and spellCount) or nil;
|
||||
local genericShowOn = %s
|
||||
local expirationTime = startTime and duration and startTime + duration
|
||||
@@ -1860,7 +1859,6 @@ WeakAuras.event_prototypes = {
|
||||
ret = ret:format(spellName,
|
||||
(trigger.use_matchedRune and "true" or "false"),
|
||||
(trigger.use_showgcd and "true" or "false"),
|
||||
(trigger.use_ignoreSpellKnown and "true" or "false"),
|
||||
(trigger.track or "auto"),
|
||||
showOnCheck
|
||||
);
|
||||
@@ -1972,11 +1970,6 @@ WeakAuras.event_prototypes = {
|
||||
text = text ..L["Ignore Rune CDs"]
|
||||
end
|
||||
|
||||
if trigger.use_ignoreSpellKnown then
|
||||
if text ~= "" then text = text .. "; " end
|
||||
text = text .. L["Ignore Unknown Spell"]
|
||||
end
|
||||
|
||||
if trigger.genericShowOn ~= "showOnReady" and trigger.track ~= "cooldown" then
|
||||
if trigger.use_trackcharge and trigger.trackcharge then
|
||||
if text ~= "" then text = text .. "; " end
|
||||
@@ -2015,13 +2008,6 @@ WeakAuras.event_prototypes = {
|
||||
test = "true",
|
||||
collapse = "extra Cooldown Progress (Spell)"
|
||||
},
|
||||
{
|
||||
name = "ignoreSpellKnown",
|
||||
display = L["Disable Spell Known Check"],
|
||||
type = "toggle",
|
||||
test = "true",
|
||||
collapse = "extra Cooldown Progress (Spell)"
|
||||
},
|
||||
{
|
||||
name = "trackcharge",
|
||||
display = L["Show CD of Charge"],
|
||||
@@ -3377,9 +3363,10 @@ WeakAuras.event_prototypes = {
|
||||
name = "spellName",
|
||||
display = L["Spell"],
|
||||
required = true,
|
||||
type = "string",
|
||||
type = "spell",
|
||||
test = "true",
|
||||
store = true
|
||||
store = true,
|
||||
conditionType = "string"
|
||||
},
|
||||
-- This parameter uses the IsSpellInRange API function, but it does not check spell range at all
|
||||
-- IsSpellInRange returns nil for invalid targets, 0 for out of range, 1 for in range (0 and 1 are both "positive" values)
|
||||
|
||||
@@ -724,7 +724,7 @@ function WeakAuras.ConstructOptions(prototype, data, startorder, triggernum, tri
|
||||
end
|
||||
end
|
||||
end
|
||||
return useExactSpellId and L["Invalid Spell ID"] or L["Invalid Spell Name/ID/Link"];
|
||||
return useExactSpellId and L["Invalid Spell ID"] or (arg.conditionType == "string" and L["Invalid Spell Name/Link"] or L["Invalid Spell Name/ID/Link"]);
|
||||
else
|
||||
return nil;
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user