Thread Tools Display Modes
02-05-10, 11:16 AM   #1
bluenjoy
A Deviate Faerie Dragon
 
bluenjoy's Avatar
AddOn Compiler - Click to view compilations
Join Date: Jul 2009
Posts: 13
oUF_Freeb (Auras)

Hey,

I asked about how I could change the backdrop and border of the frames auras in his addon thread but I never received a reply. I thought I might try here.

Since his frame has some Caellian code, I was trying to make the auras have the same border as oUF_Caellian. Sadly, I can't seem to get it right.
This is the section I tried to integrate.


(From oUF_Freeb)
Code:
local auraIcon = function(self, button, icons)
	local count = button.count
	count:ClearAllPoints()
	count:SetPoint("BOTTOMRIGHT", 3, -3)
	
	icons.disableCooldown = true

	button.icon:SetTexCoord(.1, .9, .1, .9)
	button.bg = CreateFrame("Frame", nil, button)
	button.bg:SetPoint("TOPLEFT", button, "TOPLEFT", -4, 4)
	button.bg:SetPoint("BOTTOMRIGHT", button, "BOTTOMRIGHT", 4, -4)
	button.bg:SetFrameStrata("LOW")
	button.bg:SetBackdrop(frameBD)
	button.bg:SetBackdropColor(0, 0, 0, 0)
	button.bg:SetBackdropBorderColor(0, 0, 0)
	
	local remaining = button:CreateFontString(nil, "OVERLAY")
	remaining:SetPoint("TOPLEFT", -3, 2)
	remaining:SetFont("FONTS\\FRIZQT__.ttf", 12, "OUTLINE")
	remaining:SetTextColor(.8, .8, .8)
	button.remaining = remaining
	
	if self.unit == "player" then
		button:SetScript("OnMouseUp", CancelAura)
	end
end

( oUF_Caellian)
Code:
local CreateAura = function(self, button, icons)
	button.backdrop = CreateFrame("Frame", nil, button)
	button.backdrop:SetPoint("TOPLEFT", button, "TOPLEFT", -3.5, 3)
	button.backdrop:SetPoint("BOTTOMRIGHT", button, "BOTTOMRIGHT", 4, -3.5)
	button.backdrop:SetFrameStrata("BACKGROUND")
	button.backdrop:SetBackdrop {
		edgeFile = glowTex, edgeSize = 5,
		insets = {left = 3, right = 3, top = 3, bottom = 3}
	}
	button.backdrop:SetBackdropColor(0, 0, 0, 0)
	button.backdrop:SetBackdropBorderColor(0, 0, 0)

	button.count:SetPoint("BOTTOMRIGHT", 1, 1.5)
	button.count:SetJustifyH("RIGHT")
	button.count:SetFont(fontn, 8, "THICKOUTLINE")
	button.count:SetTextColor(0.84, 0.75, 0.65)

	button.cd.noOCC = true
	button.cd.noCooldownCount = true
	icons.disableCooldown = true

	button.overlay:SetTexture(buttonTex)
	button.overlay:SetPoint("TOPLEFT", button, "TOPLEFT", -1, 1)
	button.overlay:SetPoint("BOTTOMRIGHT", button, "BOTTOMRIGHT", 1, -1)
	button.overlay:SetTexCoord(0, 1, 0.02, 1)
	button.overlay.Hide = function(self) end

	if icons ~= self.Enchant then
		button.remaining = SetFontString(button, fontn, 8, "OUTLINE")
		if self.unit == "player" then
			button:SetScript("OnMouseUp", CancelAura)
		end
	else
		button.remaining = SetFontString(button, fontn, 8, "OUTLINE")
		button.overlay:SetVertexColor(0.33, 0.59, 0.33)
	end
	button.remaining:SetPoint("TOPLEFT", 1, -1)
end
It's a great little unitframe and this is the only thing that is preventing me from using it.

Can anyone help me with this task?
__________________
-Biggie
  Reply With Quote
02-06-10, 02:29 PM   #2
Freebaser
A Molten Kobold Bandit
 
Freebaser's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2008
Posts: 135
add this to auraIcon

Code:
icons.showDebuffType = true

button.overlay:SetTexture(buttonTex)
button.overlay:SetPoint("TOPLEFT", button, "TOPLEFT", -1, 1)
button.overlay:SetPoint("BOTTOMRIGHT", button, "BOTTOMRIGHT", 1, -1)
button.overlay:SetTexCoord(0, 1, 0.02, 1)
button.overlay.Hide = function(self) self:SetVertexColor(0.33, 0.59, 0.33) end
and define buttonTex
  Reply With Quote
02-06-10, 03:03 PM   #3
bluenjoy
A Deviate Faerie Dragon
 
bluenjoy's Avatar
AddOn Compiler - Click to view compilations
Join Date: Jul 2009
Posts: 13
OMG IT WORKS FLAWLESSLY!!! Thank you soooo much for your assistance
__________________
-Biggie
  Reply With Quote
02-11-10, 11:37 AM   #4
polarB3AR
A Murloc Raider
 
polarB3AR's Avatar
Join Date: Feb 2010
Posts: 6
Don't want to start a new Topic, that's why I post here

Is it possible to hide myself in the raid unitframes? Because I want to make 6 groups with 4 frames each group and don't want to have a single player in one "group".
  Reply With Quote
02-11-10, 12:13 PM   #5
Freebaser
A Molten Kobold Bandit
 
Freebaser's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2008
Posts: 135
Originally Posted by polarB3AR View Post
Don't want to start a new Topic, that's why I post here

Is it possible to hide myself in the raid unitframes? Because I want to make 6 groups with 4 frames each group and don't want to have a single player in one "group".
Code:
raid:SetManyAttributes(
	'showPlayer', false,
	'showSolo', false,
	'showParty', true,
	'showRaid', true,
	'xoffset', 5,
	'yOffset', -5,
	'point', "LEFT",
	'groupFilter', '1,2,3,4,5,6,7,8',
	'groupingOrder', '1,2,3,4,5,6,7,8',
	'groupBy', 'GROUP',
	'maxColumns', 8,
	'unitsPerColumn', 4,
	'columnSpacing', 5,
	'columnAnchorPoint', "TOP"
)
  Reply With Quote
02-11-10, 03:51 PM   #6
polarB3AR
A Murloc Raider
 
polarB3AR's Avatar
Join Date: Feb 2010
Posts: 6
Thank's, it works
  Reply With Quote

WoWInterface » Featured Projects » oUF (Otravi Unit Frames) » oUF_Freeb (Auras)


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off