Thread Tools Display Modes
12-28-08, 04:18 AM   #181
Tøra
A Murloc Raider
Join Date: Dec 2008
Posts: 6
Originally Posted by haste View Post
It's the same answer anyway. Moving is done through the code for most layouts. Which means this is completely layout dependent. oUF itself doesn't and will not provide any in-game options because layouts can solve and modify behavior as they like.
How can i move them ?
Where can i edit the layout code ?

sorry for bad english.
 
12-28-08, 05:52 AM   #182
Mordog
A Deviate Faerie Dragon
Join Date: Feb 2008
Posts: 17
Originally Posted by Tøra View Post
How can i move them ?
Where can i edit the layout code ?

sorry for bad english.
You have to change the position in the Lua-file of your Layout. search for ouf:spawn and change the position in that line.

id would be better to move this question to Layout-thread i think.
 
12-29-08, 12:22 PM   #183
Alkar
A Chromatic Dragonspawn
 
Alkar's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2005
Posts: 195
Have a quick question do any of u use like wowui designer or anything like that to make the layouts or just do it all by hand in a editor?
__________________
 
12-29-08, 01:18 PM   #184
darkenscale
A Defias Bandit
AddOn Author - Click to view addons
Join Date: Mar 2005
Posts: 2
Is it possible to hide any or all of the frames given an event?

For instance, I'd like to hide the player frame while resting (in a capitol city/inn), but my frame name mouseover macro doesn't return anything.
 
12-29-08, 01:28 PM   #185
p3lim
A Pyroguard Emberseer
 
p3lim's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2007
Posts: 1,710
Originally Posted by darkenscale View Post
Is it possible to hide any or all of the frames given an event?

For instance, I'd like to hide the player frame while resting (in a capitol city/inn), but my frame name mouseover macro doesn't return anything.
oUF.units.player
 
12-30-08, 10:30 AM   #186
jadakren
A Flamescale Wyrmkin
 
jadakren's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2007
Posts: 103
castbar safezone quirks

Originally Posted by haste View Post
By just changing the "value" from 1e6 to 1e3 you will get. The "new" safe zone math produces the same result as the old one did.
Code:
5 sec cast, 50 ms, 100 width, 1e3 = safe zone size: 10
5 sec cast, 50 ms, 100 width, 1e6 = safe zone size: .1
--
5 sec cast, 500 ms, 100 width, 1e3 = safe zone size: 10
5 sec cast, 500 ms, 100 width, 1e6 = safe zone size: 1
--
5 sec cast, 1000 ms, 100 width, 1e3 = safe zone size: 10
5 sec cast, 1000 ms, 100 width, 1e6 = safe zone size: 2
--
5 sec cast, 2000 ms, 100 width, 1e3 = safe zone size: 10
5 sec cast, 2000 ms, 100 width, 1e6 = safe zone size: 4
--
5 sec cast, 3000 ms, 100 width, 1e3 = safe zone size: 10
5 sec cast, 3000 ms, 100 width, 1e6 = safe zone size: 6
==
10 sec cast, 50 ms, 100 width, 1e3 = safe zone size: 10
10 sec cast, 50 ms, 100 width, 1e6 = safe zone size: .05
--
10 sec cast, 500 ms, 100 width, 1e3 = safe zone size: 10
10 sec cast, 500 ms, 100 width, 1e6 = safe zone size: .5
--
10 sec cast, 1000 ms, 100 width, 1e3 = safe zone size: 10
10 sec cast, 1000 ms, 100 width, 1e6 = safe zone size: 1
--
10 sec cast, 2000 ms, 100 width, 1e3 = safe zone size: 10
10 sec cast, 2000 ms, 100 width, 1e6 = safe zone size: 2
--
10 sec cast, 3000 ms, 100 width, 1e3 = safe zone size: 10
10 sec cast, 3000 ms, 100 width, 1e6 = safe zone size: 3
It would probably be better to use the time between the spell cast is sent, and when it starts instead of GetNetStats() however.
I found that 1e6 produces a safe-zone that is misleading, although it may be correct.

What is happening is that i cast a greater heal and expect to be able to start the next one when the cast bar enters the safe-zone.

This isn't happening, so i assume that the cast-bar isn't actually in the safe-zone yet.

to this end i change the 1e6 to 9e4. seems to produce more reliable results for me

Last edited by jadakren : 12-30-08 at 11:26 AM.
 
12-30-08, 11:05 AM   #187
haste
Featured Artist
 
haste's Avatar
Premium Member
Featured
Join Date: Dec 2005
Posts: 1,027
Originally Posted by jadakren View Post
I found that 1e6 produces a safezone that is misleading, although it may be correct.

What is happening is that i cast a greater heal and expect to be able to start the next one when the cast bar enters the safezone.

this isnt happening, so i assume that the castbar isnt actually in the safezone yet.

to this end i change the 1e6 to 9e4. seems to priduce more reliable results for me
Fixing the safe zone is on the TODO list. There's a slight discussion about it here.
 
01-01-09, 01:04 PM   #188
jadakren
A Flamescale Wyrmkin
 
jadakren's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2007
Posts: 103
Originally Posted by SkunkWerks View Post
In the end it all boils down to: it's a nice addon that is sadly completely useless to me, whatever the reason.
You really are a twit...you know this right?
 
01-03-09, 06:58 AM   #189
Xuerian
A Fallenroot Satyr
 
Xuerian's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2006
Posts: 27
Is there any special usage for :RegisterEvent?

I'm trying to indicate debuffs I can remove myself, and it works fine if I fake a .Buffs object and use.PreUpdateAura, but it messes up rather horribly if I :RegisterEvent("UNIT_AURA", myownfunc) on a per-frame basis.
 
01-03-09, 07:14 AM   #190
p3lim
A Pyroguard Emberseer
 
p3lim's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2007
Posts: 1,710
1st argument is the event you want to register.
2nd argument is the function you want to assign to that event.
 
01-03-09, 07:20 AM   #191
Xuerian
A Fallenroot Satyr
 
Xuerian's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2006
Posts: 27
Originally Posted by p3lim View Post
1st argument is the event you want to register.
2nd argument is the function you want to assign to that event.
Indeed, that's as I'm registering it:
Code:
local function addDebuffs(self)
    local pc = playerClass
    if pc ~= "DRUID" and pc ~= "MAGE" and pc ~= "PRIEST" and pc ~= "SHAMAN" and pc ~= "PALADIN" then return nil end
    ...
    --self:RegisterEvent("UNIT_AURA", updateAura)
    self.PostUpdateAura = updateAura
    self.Buffs = CreateFrame("Frame")
end
The RegisterEvent line ends up with all enabled frames showing the debuff when one (Haven't figured out if it matters which...) has it.
The PostUpdateAura method works fine, though I'd rather not have the overhead of .Buffs.


What I don't get is that as I read it, I'm doing it exactly the same way that it's done in auras.lua.
One trigger method and it works exactly as expected, the other doesn't.

I'm testing this with a pally and a rogue in a group, on the scorpids outside of org. To illustrate, as seen from pally:
(RegisterEvent) Rogue gets poisoned, icon shows up on both pally (player) and rogue (party1). Cleanse poison, both icons vanish.
(PostUpdateAura) Rogue gets poisoned, icon shows up on rogue (party1). Cleanse poison, icon vanishes.

Last edited by Xuerian : 01-03-09 at 07:27 AM. Reason: STOP INJECTING SMILIES YOU TWISTED BBS
 
01-03-09, 10:45 AM   #192
haste
Featured Artist
 
haste's Avatar
Premium Member
Featured
Join Date: Dec 2005
Posts: 1,027
My guess is that you don't validate the unit in your function.
 
01-03-09, 02:39 PM   #193
Xuerian
A Fallenroot Satyr
 
Xuerian's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2006
Posts: 27
Thanks haste. That was rather nooby of me not to consider that UNIT_AURA is for all units, and I completely missed the first line of the auras Update function till you mentioned it.
 
01-14-09, 06:17 AM   #194
Blood Druid
A Fallenroot Satyr
Join Date: Oct 2008
Posts: 26
New version OUF

status.lua
An error in syntax, an error at the job of values, strings: 21 and 53

masterlooter.lua
Not correctly fulfils a unit entirely.
If the same code to place in leader.lua:
Code:
local parent = debugstack():match[[\AddOns\(.-)\]]
local global = GetAddOnMetadata(parent, 'X-oUF')
assert(global, 'X-oUF needs to be defined in the parent add-on.')
local oUF = _G[global]

local Update = function(self, event)
	if(UnitIsPartyLeader(self.unit)) then
		self.Leader:Show()
	else
		self.Leader:Hide()
	end
	if self.MasterIcon then
		local unit
		local method, pid, rid = GetLootMethod()
		if(method == 'master') then
			if(pid) then
				if(pid == 0) then
					unit = 'player'
				else
					unit = 'party'..pid
				end
			elseif(rid) then
				unit = 'raid'..rid
			end

			if(unit == self.unit) then
				if (self.Leader:IsShown()) then
					if (self.unit == 'player') then
						self.MasterIcon:SetPoint(self.Leader:GetPoint(), self.Leader, 'TOPLEFT', 1, 0)
					else
						self.MasterIcon:SetPoint(self.Leader:GetPoint(), self.Leader, 'TOPRIGHT', -3, 0)
					end
				else
					self.MasterIcon:SetPoint(self.Leader:GetPoint())
				end
				self.MasterIcon:Show()
			elseif(self.MasterIcon:IsShown()) then
				self.MasterIcon:Hide()
			end
		elseif(self.MasterIcon:IsShown()) then
			self.MasterIcon:Hide()
		end
	end
end

local Enable = function(self)
	local leader = self.Leader
	if(leader) then
		self:RegisterEvent("PARTY_LEADER_CHANGED", Update)
		self:RegisterEvent("PARTY_MEMBERS_CHANGED", Update)

		if(leader:IsObjectType"Texture" and not leader:GetTexture()) then
			leader:SetTexture[[Interface\GroupFrame\UI-Group-LeaderIcon]]
		end

		local masterIcon = self.MasterIcon
		if(masterIcon) then
			if(masterIcon:IsObjectType"Texture" and not masterIcon:GetTexture()) then
				masterIcon:SetTexture[[Interface\GroupFrame\UI-Group-MasterLooter]]
			end
		end

		return true
	end
end

local Disable = function(self)
	local leader = self.Leader
	if(leader) then
		self:UnregisterEvent("PARTY_LEADER_CHANGED", Update)
		self:UnregisterEvent("PARTY_MEMBERS_CHANGED", Update)
	end
end

oUF:AddElement('Leader', Update, Enable, Disable)
that all works correctly.
 
01-14-09, 06:57 AM   #195
haste
Featured Artist
 
haste's Avatar
Premium Member
Featured
Join Date: Dec 2005
Posts: 1,027
status.lua - http://ixo.no/git/oUF.git/commit/?id...cd50286d366e54
masterlooter.lua - The code worked for me when I tested it last night. Did you restart WoW to make sure it loaded the new file?
 
01-14-09, 07:06 AM   #196
Blood Druid
A Fallenroot Satyr
Join Date: Oct 2008
Posts: 26
Originally Posted by haste View Post
status.lua - http://ixo.no/git/oUF.git/commit/?id...cd50286d366e54
masterlooter.lua - The code worked for me when I tested it last night. Did you restart WoW to make sure it loaded the new file?
The file is connected it precisely and works but it is incorrect in raid icon ML is drawn on all participants of raid, it is 1 of examples, as if ML the player on it raid frame icon ML is not drawn
 
01-14-09, 07:09 AM   #197
Blood Druid
A Fallenroot Satyr
Join Date: Oct 2008
Posts: 26
Message: ..\AddOns\oUF\elements\status.lua line 22:
Usage: <unnamed>:SetTexCoord(minX, maxX, minY, maxY) or SetTexCoord(ULx, ULy, LLx, LLy, URx, URy, LRx, LRy)

You have forgotten the last co-ordinate

Here my numbers:
self.Resting:SetTexCoord(0.09, 0.43, 0.08, 0.42)

and

self.Combat:SetTexCoord(0.57, 0.90, 0.08, 0.41)
 
01-14-09, 07:16 AM   #198
Blood Druid
A Fallenroot Satyr
Join Date: Oct 2008
Posts: 26
As I consider that more favourably a code for mapping ML to place in leader.lua since events identical to both cases, there is no sense to produce units and superfluous cycles on units
 
01-14-09, 07:40 AM   #199
haste
Featured Artist
 
haste's Avatar
Premium Member
Featured
Join Date: Dec 2005
Posts: 1,027
I fixed the missing coordinate, and the values I use are the ones from the Blizzard XML.

I'll have to check the ML behavior later however.
 
01-14-09, 07:53 AM   #200
Blood Druid
A Fallenroot Satyr
Join Date: Oct 2008
Posts: 26
Originally Posted by haste View Post
I fixed the missing coordinate, and the values I use are the ones from the Blizzard XML.
ty


Originally Posted by haste View Post
I'll have to check the ML behavior later however.
Here my code (it I already post):
Code:
local parent = debugstack():match[[\AddOns\(.-)\]]
local global = GetAddOnMetadata(parent, 'X-oUF')
assert(global, 'X-oUF needs to be defined in the parent add-on.')
local oUF = _G[global]

local Update = function(self, event)
	if(UnitIsPartyLeader(self.unit)) then
		self.Leader:Show()
	else
		self.Leader:Hide()
	end
	if self.MasterIcon then
		local isML = false
		local lootmethod, masterlooterPartyID, masterlooterRaidID = GetLootMethod()
		if (masterlooterRaidID ~= nil) then
			if (masterlooterRaidID < 10) then
				if (UnitName('raid0'..masterlooterRaidID) == UnitName(self.unit)) then
					isML = true
				end
			else
				if (UnitName('raid'..masterlooterRaidID) == UnitName(self.unit)) then
					isML = true
				end
			end
		elseif (masterlooterPartyID ~= nil) then
			if masterlooterPartyID <=0 then
				masterlooterPartyID = 'player'
			else
				masterlooterPartyID = 'party'..masterlooterPartyID
			end	
			if (UnitName(masterlooterPartyID) == UnitName(self.unit)) then
				isML = true
			end
		end	
		if isML then
			if (self.Leader:IsShown()) then
				if (self.unit == 'player') then
					self.MasterIcon:SetPoint(self.Leader:GetPoint(), self.Leader, 'TOPLEFT', 1, 0)
				else
					self.MasterIcon:SetPoint(self.Leader:GetPoint(), self.Leader, 'TOPRIGHT', -3, 0)
				end
			else
				self.MasterIcon:SetPoint(self.Leader:GetPoint())
			end
			self.MasterIcon:Show()
		else
			self.MasterIcon:Hide()
		end
	end
end

local Enable = function(self)
	local leader = self.Leader
	if(leader) then
		self:RegisterEvent("PARTY_LEADER_CHANGED", Update)
		self:RegisterEvent("PARTY_MEMBERS_CHANGED", Update)

		if(leader:IsObjectType"Texture" and not leader:GetTexture()) then
			leader:SetTexture[[Interface\GroupFrame\UI-Group-LeaderIcon]]
		end

		local masterIcon = self.MasterIcon
		if(masterIcon) then
			if(masterIcon:IsObjectType"Texture" and not masterIcon:GetTexture()) then
				masterIcon:SetTexture[[Interface\GroupFrame\UI-Group-MasterLooter]]
			end
		end

		return true
	end
end

local Disable = function(self)
	local leader = self.Leader
	if(leader) then
		self:UnregisterEvent("PARTY_LEADER_CHANGED", Update)
		self:UnregisterEvent("PARTY_MEMBERS_CHANGED", Update)
	end
end

oUF:AddElement('Leader', Update, Enable, Disable)
Yes it bulky, but dependably works 7 months
 

WoWInterface » Featured Projects » oUF (Otravi Unit Frames) » oUF - General discussion

Thread Tools
Display Modes

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