02-11-11, 01:53 PM   #21
sacrife
An Onyxian Warder

Join Date: Mar 2009
Posts: 384
Maybe we should try hooking the barPrototype:ApplyStyle from DBT.lua instead?

I tried but couldn't really get it to work as I don't understand hooking properly.

ATM I just edit the DBT.lua every time by adding these lines at the bottom of the "function barPrototype:ApplyStyle()" (Starts around line 630+)

I still want to edit the width, height and positions of the DBM elements manually in LUA as well. (I really hate savedvariables) With this I could also move the bars depending on where I am (PvP or Raid/Dungeon).

Code:
lua Code:
`-- Edit    local blankTex = "Interface\\Buttons\\WHITE8x8"    local backdrop = {bgFile = blankTex, edgeFile = blankTex, edgeSize = 1, insets = { left = 0, right = 0, top = 0, bottom = 0}}        icon1:SetTexCoord(.07, .93, .07, .93)    icon1:SetWidth(17) -- barheight    icon1:SetHeight(17) -- barheight    icon1:SetPoint("RIGHT",frame,"LEFT",-3,0)    icon1.IconGlow = CreateFrame("Frame", nil, frame)    icon1.IconGlow:SetPoint("TOPLEFT", icon1, "TOPLEFT", -1, 1)    icon1.IconGlow:SetPoint("BOTTOMRIGHT", icon1, "BOTTOMRIGHT", 1, -1)    icon1.IconGlow:SetBackdrop(backdrop)    icon1.IconGlow:SetBackdropColor(0,0,0,0)    icon1.IconGlow:SetBackdropBorderColor(0,0,0,1)      icon1.IconGlow:SetFrameLevel(0)        local barbg = _G[frame:GetName().."BarBackground"]    barbg:SetAlpha(0)        bar.Border = CreateFrame("Frame", nil, frame)    bar.Border:SetPoint("TOPLEFT", bar, "TOPLEFT", -1, 1)    bar.Border:SetPoint("BOTTOMRIGHT", bar, "BOTTOMRIGHT", 1, -1)    bar.Border:SetBackdrop(backdrop)    bar.Border:SetBackdropColor(0.17,0.17,0.17,1)    bar.Border:SetBackdropBorderColor(0,0,0,1)      bar.Border:SetFrameLevel(0)        name:SetFont("Interface\\Addons\\!shakes\\fonts\\fieryturk.TTF", 8, "OUTLINEMONOCHROME")    name:SetPoint("LEFT",2.5,0)    timer:SetFont("Interface\\Addons\\!shakes\\fonts\\fieryturk.TTF", 8, "OUTLINEMONOCHROME")    timer:SetPoint("RIGHT",0,0)    texture:SetTexture("Interface\\AddOns\\!shakes\\textures\\tap2.tga")`
Attached Thumbnails

__________________

Last edited by sacrife : 02-11-11 at 01:59 PM.

 WoWInterface » How to skin Deadly Boss Mods (without rewriting)