Really don't want to rewrite it every single time i switch character (since I play both). Would this work?
http://pastebin.com/fx2Av2Q8
Really don't want to rewrite it every single time i switch character (since I play both). Would this work?
http://pastebin.com/fx2Av2Q8
Is there ANY Auction Addon that has been updated to work for Caged Pets?
I'm getting sick of having to manually look up, price, etc. all of my duplicate pets. :S
I've checked Auctioneer and Auctionator, neither have received any comments from the creator since September. AuctionMaster's creator says he has to rewrite the code because all pet cages are labeled as "Pet Cage", so if you enter an auction for one of them, it will sell all of them for the same price. :S
@Denalion: Why not just copy the add-on, and enable one for your monk and one for your death knight? You can custom choose which addons are active on which characters.
Keep in mind, your death knight can also gain guard from the Ox Statue a monk places, so you might want to include that in your Death Knight one as well. I was getting guarded like crazy last night on my rogue.
Last edited by Myzou; 2012-11-07 at 10:22 AM.
While I didn't test this, it should work.
If your further want to adjust it, just add any spells you want, then replace references to "Frame7Column" with increasing numbers (correspondent to the index of the "Total" pseudo-spell in the table).Code:-- Absorb Field -- Author: Kar (EU-Silvermoon) local amountAbsorb, totalAbsorb local UnitBuff = UnitBuff local UnitExists = UnitExists local spells = { { ["Name"] = "Blood Shield", ["Icon"] = "spell_deathknight_butcher2", }, { ["Name"] = "Guard", ["Icon"] = "ability_monk_guard", }, { ["Name"] = "Power Word: Shield", ["Icon"] = "spell_holy_powerwordshield", }, { ["Name"] = "Divine Aegis", ["Icon"] = "spell_holy_devineaegis", }, { ["Name"] = "Illuminated Healing", ["Icon"] = "spell_holy_absolution", }, { ["Name"] = "Sacred Shield", ["Icon"] = "ability_paladin_blessedmending", }, { ["Name"] = "Total", ["Icon"] = "spell_arcane_arcaneresilience", }, } local function Absorb_SavePosition(frame) AbsorbField_Settings[frame.Unit.."PosX"] = frame:GetLeft() AbsorbField_Settings[frame.Unit.."PosY"] = frame:GetBottom() end local function Absorb_FormatValue(value) if value > 999 then value = value / 1000 if value < 100 then value = format("%.1fk",value) else value = format("%.0fk",value) end end return value end local hide_if_zero = true local hidden_alpha = 0 local full_alpha = 1 local focus_hidedetails = true local function Absorb_UpdateAbsorbs(unit) totalAbsorb = 0 for i = 1, 4 do if UnitBuff(unit, spells[i]["Name"]) then amountAbsorb = select(14, UnitBuff(unit, spells[i]["Name"])) totalAbsorb = totalAbsorb + amountAbsorb if(unit == "focus" and focus_hidedetails) then _G["AbsorbField"..unit.."_Frame"..i.."Coloumn"]:Hide() else _G["AbsorbField"..unit.."_Frame"..i.."Coloumn"]:Show() _G["AbsorbField"..unit.."_Frame"..i.."Coloumn"].Amount:SetText(Absorb_FormatValue(amountAbsorb)) _G["AbsorbField"..unit.."_Frame"..i.."Coloumn"].Amount:SetTextColor(0.2, 1.0, 0.2) _G["AbsorbField"..unit.."_Frame"..i.."Coloumn"].Icon:SetDesaturated(nil) end else if(unit == "focus" and focus_hidedetails) then _G["AbsorbField"..unit.."_Frame"..i.."Coloumn"]:Hide() else _G["AbsorbField"..unit.."_Frame"..i.."Coloumn"]:Show() _G["AbsorbField"..unit.."_Frame"..i.."Coloumn"].Amount:SetText("0") _G["AbsorbField"..unit.."_Frame"..i.."Coloumn"].Amount:SetTextColor(0.4, 0.4, 0.4) _G["AbsorbField"..unit.."_Frame"..i.."Coloumn"].Icon:SetDesaturated(true) end end end if totalAbsorb > 0 then _G["AbsorbField"..unit.."_Frame7Coloumn"].Amount:SetText(Absorb_FormatValue(totalAbsorb)) _G["AbsorbField"..unit.."_Frame7Coloumn"].Amount:SetTextColor(0.1, 0.7, 1.0) _G["AbsorbField"..unit.."_Frame7Coloumn"].Icon:SetDesaturated(nil) if hide_if_zero then _G["AbsorbField"..unit.."_Frame7Coloumn"]:SetAlpha(full_alpha) for i = 1, 4 do _G["AbsorbField"..unit.."_Frame"..i.."Coloumn"]:SetAlpha(full_alpha) end end else _G["AbsorbField"..unit.."_Frame7Coloumn"].Amount:SetText(0) _G["AbsorbField"..unit.."_Frame7Coloumn"].Amount:SetTextColor(0.4, 0.4, 0.4) _G["AbsorbField"..unit.."_Frame7Coloumn"].Icon:SetDesaturated(true) if hide_if_zero then _G["AbsorbField"..unit.."_Frame7Coloumn"]:SetAlpha(hidden_alpha) for i = 1, 4 do _G["AbsorbField"..unit.."_Frame"..i.."Coloumn"]:SetAlpha(hidden_alpha) end end end end local function Absorb_CreateColumn(icon, name, id, unit) local button = CreateFrame("Button", "AbsorbField"..unit.."_Frame"..id.."Coloumn", _G["AbsorbField"..unit.."_Frame"]) button:SetWidth(50) button:SetHeight(15) button:SetPoint("LEFT", _G["AbsorbField"..unit.."_Frame"], "LEFT", (id - 1) * 51, 0) button.Name = name button:EnableMouse(false) local texture = button:CreateTexture(nil, "ARTWORK") texture:SetWidth(15) texture:SetHeight(15) texture:SetPoint("LEFT", button, "LEFT", 0, 0) texture:SetTexture("Interface\\Icons\\"..icon) texture:SetDesaturated(true) texture:SetTexCoord(.1, .9, .1, .9) button.Icon = texture local amount = button:CreateFontString(nil, "OVERLAY") amount:SetFont("Interface\\AddOns\\SharedMedia\\fonts\\Homespun.TTF", 10, "OUTLINE") amount:SetText("0") amount:SetTextColor(0.4, 0.4, 0.4) amount:SetPoint("CENTER", button, "CENTER", 7, 0) amount:SetJustifyH("CENTER") button.Amount = amount if hide_if_zero then button:SetAlpha(0) end end local function Absorb_CreateField(unit) local frame = CreateFrame("Frame", "AbsorbField"..unit.."_Frame", UIParent) frame:SetWidth(254) frame:SetHeight(15) if not AbsorbField_Settings[unit.."PosX"] then if unit == "player" then frame:SetPoint("CENTER", UIParent, "CENTER", 0, 200) else frame:SetPoint("CENTER", UIParent, "CENTER", 0, 150) end else frame:SetPoint("BOTTOMLEFT", UIParent, "BOTTOMLEFT", AbsorbField_Settings[unit.."PosX"], AbsorbField_Settings[unit.."PosY"]) end local texture = frame:CreateTexture(nil, "BACKGROUND") texture:SetAllPoints(true) texture:Hide() frame.Unit = unit frame.BG = texture for i = 1, #spells do Absorb_CreateColumn(spells[i]["Icon"], spells[i]["Name"], i, unit) end if unit == "focus" then frame:Hide() end end function AbsorbField_SlashHandler(msg) msg = string.lower(msg) if msg == "unlock" then AbsorbFieldplayer_Frame:RegisterForDrag("LeftButton") AbsorbFieldplayer_Frame:SetMovable(true) AbsorbFieldplayer_Frame:EnableMouse(true) AbsorbFieldplayer_Frame.BG:SetTexture(0.2, 1.0, 0.2) AbsorbFieldplayer_Frame.BG:Show() AbsorbFieldplayer_Frame:SetScript("OnDragStart", function (self) self:StartMoving() end) AbsorbFieldplayer_Frame:SetScript("OnDragStop", function (self) self:StopMovingOrSizing() Absorb_SavePosition(self) end) AbsorbFieldfocus_Frame:RegisterForDrag("LeftButton") AbsorbFieldfocus_Frame:SetMovable(true) AbsorbFieldfocus_Frame:EnableMouse(true) AbsorbFieldfocus_Frame.BG:SetTexture(0.2, 0.2, 1.0) AbsorbFieldfocus_Frame.BG:Show() AbsorbFieldfocus_Frame:SetScript("OnDragStart", function (self) self:StartMoving() end) AbsorbFieldfocus_Frame:SetScript("OnDragStop", function (self) self:StopMovingOrSizing() Absorb_SavePosition(self) end) AbsorbFieldfocus_Frame:Show() elseif msg == "lock" then AbsorbFieldplayer_Frame:RegisterForDrag(nil) AbsorbFieldplayer_Frame:SetMovable(false) AbsorbFieldplayer_Frame:EnableMouse(false) AbsorbFieldplayer_Frame.BG:Hide() AbsorbFieldplayer_Frame:SetScript("OnDragStart", nil) AbsorbFieldplayer_Frame:SetScript("OnDragStop", nil) AbsorbFieldfocus_Frame:RegisterForDrag(nil) AbsorbFieldfocus_Frame:SetMovable(false) AbsorbFieldfocus_Frame:EnableMouse(false) AbsorbFieldfocus_Frame.BG:Hide() AbsorbFieldfocus_Frame:SetScript("OnDragStart", nil) AbsorbFieldfocus_Frame:SetScript("OnDragStop", nil) if not UnitExists("focus") then AbsorbFieldfocus_Frame:Hide() end end end function AbsorbField_OnEvent(self, event, ...) if event == "VARIABLES_LOADED" then if not AbsorbField_Settings then AbsorbField_Settings = {} end Absorb_CreateField("player") Absorb_CreateField("focus") self:RegisterEvent("UNIT_AURA") self:RegisterEvent("PLAYER_FOCUS_CHANGED") SlashCmdList["ABSORBFIELDCOMMANDS"] = AbsorbField_SlashHandler; SLASH_ABSORBFIELDCOMMANDS1 = "/abf" elseif event == "UNIT_AURA" then local arg1 = ... if arg1 == "player" then Absorb_UpdateAbsorbs("player") elseif arg1 == "focus" then Absorb_UpdateAbsorbs("focus") end elseif event == "PLAYER_FOCUS_CHANGED" then if UnitExists("focus") then AbsorbFieldfocus_Frame:Show() Absorb_UpdateAbsorbs("focus") else AbsorbFieldfocus_Frame:Hide() end end end local frame = CreateFrame("Frame", "AbsorbField") frame:SetScript("OnEvent", AbsorbField_OnEvent) frame:RegisterEvent("VARIABLES_LOADED")
It's also pretty in-efficient and leaking globals. If you want, I could take a look at it when I have some time.
UI & AddOns expert | Interface & Macros moderator - My work
Greetings,
Im looking for an addon that would reverse the sequence of mails in my mailbox. So the first mail in sequence becomes the last. Any ideas?
To clarify: I'm looking for a really basic addon, that I might be able to edit myself, where I could just add "Drops Silk Cloth" to the tooltip on mouse over. I know the very basics of lua but I can't understand how or if this is possible when mousing over a hostile mob.
Last edited by omni; 2012-11-08 at 04:20 AM.
Looking to have Ora3 sort the cooldown tracker based on class rather than duration.
i.e 3 Warriors drop demo banner all cd's are in the same area of the list no matter the time desparity
Recently tranferred from Bartender4 to bBars. Seeing how bBars has very minimal in-game configuration..
-How would I make the stacks text smaller? Like on pots, healthstones, ect. The numbers are going with a "in your face" attitude.
-- Screeny --
-How would I deactivate the fade when the ability is not usable or out of range? I found this code in the addon LUA (not wtf) and I'm pretty sure it has something to do with it. Would I just change the right side to "False" or something?
Code:local IsUsableAction = IsUsableAction local IsActionInRange = IsActionInRange
Jeremypwnz Armory JeremypwnzUI Jeremy's Logs<--(Contains all guild raids)
12/12N T15 25m <Calm Down> Calm Down Logs -- Recruiting an Elemental Shaman and a Boomkin!
You could probably do:
No guarantees though.Code:local dummy = function() return true end local IsUsableAction = dummy local IsActionInRange = dummy
UI & AddOns expert | Interface & Macros moderator - My work
Works like a charm, thanks!
Jeremypwnz Armory JeremypwnzUI Jeremy's Logs<--(Contains all guild raids)
12/12N T15 25m <Calm Down> Calm Down Logs -- Recruiting an Elemental Shaman and a Boomkin!
I feel like I've been here a lot lately. How would I add a 1 pixel black border to DBM timers? With a 1 pixil spacing between each timer? (Can I do this?)
Jeremypwnz Armory JeremypwnzUI Jeremy's Logs<--(Contains all guild raids)
12/12N T15 25m <Calm Down> Calm Down Logs -- Recruiting an Elemental Shaman and a Boomkin!
You can add spacing between the bars in the ingame config of DBM.
I can't remember exactly how I added my border around the bars, but here is my DBT-Template.xml. This will add a border to your bars, and it will look like this (not the color though):
I recommend backing up your DBT-Template.xml before trying it out. Just copy the raw paste data at the bottom into your file and it should work.
I love you. Works perfectly, and I found the spacing setting. Never knew it was there. lol
Jeremypwnz Armory JeremypwnzUI Jeremy's Logs<--(Contains all guild raids)
12/12N T15 25m <Calm Down> Calm Down Logs -- Recruiting an Elemental Shaman and a Boomkin!
You're welcome. It was a pain for me to figure out how to get a border on those bars about a year ago. Had to read through an old forum somewhere to figure it out, and I'm happy you don't have to do that now![]()
I have a couple of goals for chat frames:
-I play on multiple machines, so I'd like to disable server-side config saving if possible (chatter claims to do this)
-I want to manually edit whatever lua or config is necessary to get exact placement
-I need all the standard functionality of an addon like Prat or Chatter, i.e. edit box placement, removal of buttons, ability to move window to the edge of the screen, etc.
But I have some issues:
-My chat-cache does not behave at all like expected. Sometimes the game saves no information to it at all when I logout and exit the game. Sometimes the game loads the config, but sometimes it seems to reset to the server-side config.
-Chatter sometimes completely forgets the previous config and reverts.
-The addon Een's Chat saver (... exact name not remembered) would allow me to continue using server side positioning, and just load a config each time. This is clunky, however, I'm not sure if it would play nice with Chatter/Prat, and I don't know the syntax of its saved variables, so I'm not sure how to edit them manually.
Anyone who's had success with this type of issue?
I've tried setting synchronizeSettings - which I suppose might help the specific issue, but A) Isn't really an option because I don't want to manage macros and bindings on multiple machines, and B) doesn't solve my more important problem - that I want to be able to manually adjust things - when I tried this the game didn't even save anything in chat-cache for me to change.
Anyone around that knows how to hide the equipborder in blizzards original ui?
Thanks in advance!
I've seen this on a few different European UIs lately and I tried to find out what mod it was but I wasn't easily able to. So here I am going to ask! In this video it shows the crit percentage at the bottom left. So.. what is this addon? Oh, and while I'm here I should ask what his player/boss bars are too (the one at the bottom middle area) if anyone happens to know? It's a pretty sleek UI and I'm totally digging it.
Here's the vid: http://www.youtube.com/watch?v=1NT0VwKjY2M
That looks like a modified ElvUI. http://tukui.org/dl.php
Both of the things you mentioned can be easily imitated through other addons. The crit % thing can be done by many broker display addons and the unit frames can be done by addons such as Stuf.
Yo! Just got myself this UI: http://www.wowinterface.com/download...-SkaarjUI.html
I'd like to add something though and I have close to none experience with LUA.
The UI are using caelNamePlates and I'd like to add my Debuffs up over them, like ElvUI/TidyPlates. So my question is, how could I fix this?
I've been looking trough the code but I can't really find anything with "debuff(s)".
I'm not sure if this is a big thing to do or not, and if it is, well it's not as important I presume, but I'd really love to have it.
Code:local _, caelNameplates = ... caelNameplates.eventFrame = CreateFrame("Frame", nil, UIParent) local mediaPath = "Interface\\AddOns\\Media\\" local barTexture = mediaPath.."texture" local glowTex = mediaPath.."glowTex" local raidIcons = mediaPath.."raidicons" local overlayTexture = [=[Interface\Tooltips\Nameplate-Border]=] local font, fontSize, fontOutline = mediaPath.. "pixel.ttf", 5, "Outlinemonochrome" local backdrop = { bgFile = [=[Interface\ChatFrame\ChatFrameBackground]=], edgeFile = glowTex, edgeSize = 2, insets = {left = 2, right = 2, top = 2, bottom = 2} } local UpdateTime = function(self, curValue) local minValue, maxValue = self:GetMinMaxValues() if self.channeling then self.time:SetFormattedText("%.1f ", curValue) else self.time:SetFormattedText("%.1f ", maxValue - curValue) end end local ThreatUpdate = function(self, elapsed) self.elapsed = self.elapsed + elapsed if self.elapsed >= 0.2 then if not self.oldglow:IsShown() then self.healthBar.hpGlow:SetBackdropBorderColor(0, 0, 0) else local r, g, b = self.oldglow:GetVertexColor() if g + b == 0 then self.healthBar.hpGlow:SetBackdropBorderColor(1, 0, 0) else self.healthBar.hpGlow:SetBackdropBorderColor(1, 1, 0) end end self.healthBar:SetStatusBarColor(self.r, self.g, self.b) self.elapsed = 0 end end local UpdatePlate = function(self) -- Reset text color just in case self.name:SetTextColor(0.84, 0.75, 0.65) local r, g, b = self.healthBar:GetStatusBarColor() local newr, newg, newb if g + b == 0 then -- Hostile unit newr, newg, newb = 0.69, 0.31, 0.31 elseif r + b == 0 then -- Friendly unit newr, newg, newb = 0.33, 0.59, 0.33 elseif r + g == 0 then -- Friendly player newr, newg, newb = 0.31, 0.45, 0.63 elseif 2 - (r + g) < 0.05 and b == 0 then -- Neutral unit newr, newg, newb = 0.65, 0.63, 0.35 else -- Hostile player - class colored. newr, newg, newb = r, g, b self.name:SetTextColor(r, g, b) end self.healthBar:SetStatusBarColor(newr, newg, newb) self.r, self.g, self.b = newr, newg, newb self.healthBar:ClearAllPoints() self.healthBar:SetPoint("BOTTOM", self.healthBar:GetParent(), "BOTTOM") self.healthBar:SetHeight(8) self.healthBar:SetWidth(100) self.healthBar.hpBackground:SetVertexColor(self.r * 0.33, self.g * 0.33, self.b * 0.33, 1) self.castBar:ClearAllPoints() self.castBar:SetPoint("TOP", self.healthBar, "BOTTOM", 0, -4) self.castBar:SetHeight(5) self.castBar:SetWidth(100) self.highlight:ClearAllPoints() self.highlight:SetAllPoints(self.healthBar) local oldName = self.oldname:GetText() local newName = (string.len(oldName) > 25) and string.gsub(oldName, "%s?(.[\128-\191]*)%S+%s", "%1. ") or oldName -- "%s?(.)%S+%s" self.name:SetText(newName) local level, elite, mylevel = tonumber(self.level:GetText()), self.elite:IsShown(), UnitLevel("player") self.level:ClearAllPoints() self.level:SetPoint("RIGHT", self.healthBar, "LEFT", 0, 0) if self.boss:IsShown() then self.level:SetText("??") self.level:SetTextColor(0.8, 0.05, 0) self.level:Show() elseif not elite and (mylevel == MAX_PLAYER_LEVEL and level == mylevel) then self.level:Hide() else self.level:SetText(level..(elite and "+" or "")) end end local FixCastbar = function(self) self.castbarOverlay:Hide() self:SetHeight(5) self:ClearAllPoints() self:SetPoint("TOP", self.healthBar, "BOTTOM", 0, -4) end local ColorCastBar = function(self, shielded) if shielded then self:SetStatusBarColor(1, .9, .4) else self:SetStatusBarColor(0, 0.7, 1) end end local OnSizeChanged = function(self) self.needFix = true end local OnValueChanged = function(self, curValue) UpdateTime(self, curValue) if self.needFix then FixCastbar(self) self.needFix = nil end end local OnShow = function(self) self.channeling = UnitChannelInfo("target") FixCastbar(self) ColorCastBar(self, self.shieldedRegion:IsShown()) end local OnHide = function(self) self.highlight:Hide() self.healthBar.hpGlow:SetBackdropBorderColor(0, 0, 0) end local OnEvent = function(self, event, unit) if unit == "target" then if self:IsShown() then ColorCastBar(self, event == "UNIT_SPELLCAST_NOT_INTERRUPTIBLE") end end end local CreatePlate = function(frame) if frame.done then return end frame.nameplate = true frame.healthBar, frame.castBar = frame:GetChildren() local healthBar, castBar = frame.healthBar, frame.castBar local glowRegion, overlayRegion, highlightRegion, nameTextRegion, levelTextRegion, bossIconRegion, raidIconRegion, stateIconRegion = frame:GetRegions() local _, castbarOverlay, shieldedRegion, spellIconRegion = castBar:GetRegions() frame.oldname = nameTextRegion nameTextRegion:Hide() frame.name = frame:CreateFontString() frame.name:SetPoint("BOTTOMLEFT", healthBar, "TOPLEFT") frame.name:SetFont(font, fontSize, fontOutline) frame.name:SetTextColor(0.84, 0.75, 0.65) frame.name:SetShadowOffset(0, 0) frame.level = levelTextRegion levelTextRegion:SetFont(font, fontSize, fontOutline) levelTextRegion:SetShadowOffset(0, 0) healthBar:SetStatusBarTexture(barTexture) healthBar.hpBackground = healthBar:CreateTexture(nil, "BACKGROUND") healthBar.hpBackground:SetAllPoints() healthBar.hpBackground:SetTexture(barTexture) healthBar.hpGlow = CreateFrame("Frame", nil, healthBar) healthBar.hpGlow:SetFrameLevel(healthBar:GetFrameLevel() -1 > 0 and healthBar:GetFrameLevel() -1 or 0) healthBar.hpGlow:SetPoint("TOPLEFT", healthBar, "TOPLEFT", -2, 2) healthBar.hpGlow:SetPoint("BOTTOMRIGHT", healthBar, "BOTTOMRIGHT", 2, -2) healthBar.hpGlow:SetBackdrop(backdrop) healthBar.hpGlow:SetBackdropColor(0, 0, 0, 0) healthBar.hpGlow:SetBackdropBorderColor(0, 0, 0) castBar.castbarOverlay = castbarOverlay castBar.healthBar = healthBar castBar.shieldedRegion = shieldedRegion castBar:SetStatusBarTexture(barTexture) castBar:HookScript("OnShow", OnShow) castBar:HookScript("OnSizeChanged", OnSizeChanged) castBar:HookScript("OnValueChanged", OnValueChanged) castBar:HookScript("OnEvent", OnEvent) castBar:RegisterEvent("UNIT_SPELLCAST_INTERRUPTIBLE") castBar:RegisterEvent("UNIT_SPELLCAST_NOT_INTERRUPTIBLE") castBar.time = castBar:CreateFontString(nil, "ARTWORK") castBar.time:SetPoint("RIGHT", castBar, "LEFT", -2, 0) castBar.time:SetFont(font, fontSize, fontOutline) castBar.time:SetTextColor(0.84, 0.75, 0.65) castBar.time:SetShadowOffset(0, 0) castBar.cbBackground = castBar:CreateTexture(nil, "BACKGROUND") castBar.cbBackground:SetAllPoints() castBar.cbBackground:SetTexture(barTexture) castBar.cbBackground:SetVertexColor(0.25, 0.25, 0.25, 1) castBar.cbGlow = CreateFrame("Frame", nil, castBar) castBar.cbGlow:SetFrameLevel(castBar:GetFrameLevel() -1 > 0 and castBar:GetFrameLevel() -1 or 0) castBar.cbGlow:SetPoint("TOPLEFT", castBar, -2, 2) castBar.cbGlow:SetPoint("BOTTOMRIGHT", castBar, 2, -2) castBar.cbGlow:SetBackdrop(backdrop) castBar.cbGlow:SetBackdropColor(0, 0, 0, 0) castBar.cbGlow:SetBackdropBorderColor(0, 0, 0) castBar.HolderA = CreateFrame("Frame", nil, castBar) castBar.HolderA:SetFrameLevel(castBar.HolderA:GetFrameLevel() + 1) castBar.HolderA:SetAllPoints() spellIconRegion:ClearAllPoints() spellIconRegion:SetParent(castBar.HolderA) spellIconRegion:SetPoint("BOTTOMLEFT", castBar, "BOTTOMRIGHT", 3, 0) spellIconRegion:SetSize(17, 17) spellIconRegion:SetTexCoord(.07, .93, .07, .93) spellIconRegion.Background = castBar:CreateTexture(nil, "BACKGROUND") spellIconRegion.Background:SetAllPoints() spellIconRegion.Background:SetTexture(barTexture) spellIconRegion.Background:SetVertexColor(0.25, 0.25, 0.25, 1) spellIconRegion.Glow = CreateFrame("Frame", nil, castBar) spellIconRegion.Glow:SetFrameLevel(castBar:GetFrameLevel() -1 > 0 and castBar:GetFrameLevel() -1 or 0) spellIconRegion.Glow:SetPoint("TOPLEFT", spellIconRegion, -2, 2) spellIconRegion.Glow:SetPoint("BOTTOMRIGHT", spellIconRegion, 2, -2) spellIconRegion.Glow:SetBackdrop(backdrop) spellIconRegion.Glow:SetBackdropColor(0, 0, 0, 0) spellIconRegion.Glow:SetBackdropBorderColor(0, 0, 0) castBar.HolderB = CreateFrame("Frame", nil, castBar) castBar.HolderB:SetFrameLevel(castBar.HolderA:GetFrameLevel() + 2) castBar.HolderB:SetAllPoints() highlightRegion:SetTexture(barTexture) highlightRegion:SetVertexColor(0.25, 0.25, 0.25) frame.highlight = highlightRegion raidIconRegion:ClearAllPoints() raidIconRegion:SetPoint("RIGHT", healthBar, -8, 0) raidIconRegion:SetSize(20, 20) raidIconRegion:SetTexture(raidIcons) frame.oldglow = glowRegion frame.elite = stateIconRegion frame.boss = bossIconRegion frame.done = true glowRegion:SetTexture(nil) overlayRegion:SetTexture(nil) shieldedRegion:SetTexture(nil) castbarOverlay:SetTexture(nil) stateIconRegion:SetTexture(nil) bossIconRegion:SetTexture(nil) UpdatePlate(frame) frame:SetScript("OnShow", UpdatePlate) frame:SetScript("OnHide", OnHide) frame.elapsed = 0 frame:SetScript("OnUpdate", ThreatUpdate) end local numKids = 0 local lastUpdate = 0 caelNameplates.eventFrame:SetScript("OnUpdate", function(self, elapsed) lastUpdate = lastUpdate + elapsed if lastUpdate > 0.1 then lastUpdate = 0 local newNumKids = WorldFrame:GetNumChildren() if newNumKids ~= numKids then for i = numKids + 1, newNumKids do local frame = select(i, WorldFrame:GetChildren()) if (frame:GetName() and frame:GetName():find("NamePlate%d")) then CreatePlate(frame) end end numKids = newNumKids end end end)