Category: oUF: Plugins
Addon Information
Works with 3.2
Download Latest Version.
To add favorites please register for a free account. If you already have one you need to login. How do I install this? (FAQ)
p3lim's Portal Bug Reports Feature Requests

This file is a Addon for oUF by haste. You must have that installed before this Addon will work.

Author:
Version:
30200.4-Release
Date:
09-07-2009 06:24 PM
Size:
1.83 Kb
Downloads:
15,072
Favorites:
160
MD5:
oUF Experience   Popular! (More than 5000 hits)
Description:
oUF Experience is a element plug-in made for the UnitFrame framework oUF.
It is required that you have this addon updated at all times to make everything work as it should.
You can download oUF by clicking on the link located under the "Download" button on the right.


Features:
  • Experience bar (with rested (optional))
  • Informational text on bar
  • Informational tooltip
  • If player is at max level the bar cluster is hidden
  • If pet is at player level the bar cluster is hidden
  • If player has disabled xp gain its put on standby

Note:
Read the documentation inside the lua file for usage.
You need to add this addon to your layout's toc metadata!


Click here and follow steps how to submit a bug
  Change Log - oUF Experience
Full changelog can be found on GitHub:
http://github.com/p3lim/oUF_Experience/commits/master/
  Archived Versions - oUF Experience
File Name
Version
Size
Author
Date
30200.3-Release
2kB
p3lim
08-22-2009 05:20 PM
30200.2-Release
2kB
p3lim
08-17-2009 05:58 PM
30200.1-Beta
2kB
p3lim
08-08-2009 12:06 PM
30200.39
2kB
p3lim
08-04-2009 06:22 PM
30200.38
2kB
p3lim
08-04-2009 03:28 PM
30000.37
2kB
p3lim
07-15-2009 02:51 PM
30000.36
2kB
p3lim
06-13-2009 02:31 PM
30000.35
2kB
p3lim
06-11-2009 04:27 PM
30000.34
2kB
p3lim
06-01-2009 12:45 PM
30000.33
2kB
p3lim
06-01-2009 05:55 AM
30000.32
2kB
p3lim
05-26-2009 04:36 PM
30000.31
2kB
p3lim
05-24-2009 09:28 PM
30000.30
2kB
p3lim
05-20-2009 12:52 PM
30000.29
2kB
p3lim
04-17-2009 11:34 AM
30000.28
2kB
p3lim
02-07-2009 03:36 PM
30000.26
2kB
p3lim
01-14-2009 03:38 PM
30000.25
2kB
p3lim
01-13-2009 03:41 PM
  Comments - oUF Experience
Post A Reply Comment Options
Old 09-08-2009, 01:39 PM  
p3lim
A Molten Giant
 
p3lim's Avatar
Interface Author - Click to view interfaces

Forum posts: 558
File comments: 838
Uploads: 19
Quote:
Originally posted by Icerat
Cool thanks works as intended now,

Ive been playing around with the way you show the experience bar with the rested in it and trying to auto hide it on mouse over.

The problem I'm having is the text and the green part of the bar hide on mouse over but I'm left with the rested blue bar still showing.

How can i get the bar that shows rested to hide also when i mouse over?

Code:
		if(unit == 'player' or unit == 'pet') then
		if(IsAddOnLoaded('oUF_Experience')) then
			self.Experience = CreateFrame('StatusBar', nil, self)
			self.Experience:SetPoint('TOPLEFT', self, 'BOTTOMLEFT', 0, -10)
			self.Experience:SetPoint('TOPRIGHT', self, 'BOTTOMRIGHT', 0, -10)
			self.Experience:SetHeight(11)
			self.Experience:SetStatusBarTexture(texture2)
			self.Experience:SetStatusBarColor(0.15, 0.7, 0.1)
			self.Experience.Tooltip = true

			self.Experience.Rested = CreateFrame('StatusBar', nil, self)
			self.Experience.Rested:SetAllPoints(self.Experience)
			self.Experience.Rested:SetStatusBarTexture(texture2)
			self.Experience.Rested:SetStatusBarColor(0, 0.4, 1, 0.6)
			self.Experience.Rested:SetBackdrop(backdrop)
			self.Experience.Rested:SetBackdropColor(0, 0, 0)
			
			self.Experience.Text = self.Experience:CreateFontString(nil, 'OVERLAY', 'GameFontHighlightSmall')
			self.Experience.Text:SetPoint('CENTER', self.Experience)

			self.Experience.bg = self.Experience.Rested:CreateTexture(nil, 'BORDER')
			self.Experience.bg:SetAllPoints(self.Experience)
			self.Experience.bg:SetTexture(0.3, 0.3, 0.3)
			
			self.Experience:SetScript ('OnEnter', function(self) self:SetAlpha(1) end)
			self.Experience:SetScript ('OnLeave', function(self) self:SetAlpha(0) end)

			
		end
		end
I'm sorry if its a little a stupid question, I'm still learning.
If you create a rested bar you must know that it will be above the normal bar.
You have to parent text etc to it, aswell to make the OnEnter/OnLeave scripts on it, though to hide the parent, not the rested bar.

This is a very tacky way to do it, but blizzard doesnt allow multi-bars.

Last edited by p3lim : 09-08-2009 at 01:39 PM.
p3lim is offline Report comment to moderator   Edit/Delete Message Reply With Quote
Old 09-08-2009, 01:11 PM  
Icerat
A Fallenroot Satyr

Forum posts: 23
File comments: 41
Uploads: 0
Quote:
Originally posted by p3lim
This is not intended, and a fix for it is on its way.
Cool thanks works as intended now,

Ive been playing around with the way you show the experience bar with the rested in it and trying to auto hide it on mouse over.

The problem I'm having is the text and the green part of the bar hide on mouse over but I'm left with the rested blue bar still showing.

How can i get the bar that shows rested to hide also when i mouse over?

Code:
		if(unit == 'player' or unit == 'pet') then
		if(IsAddOnLoaded('oUF_Experience')) then
			self.Experience = CreateFrame('StatusBar', nil, self)
			self.Experience:SetPoint('TOPLEFT', self, 'BOTTOMLEFT', 0, -10)
			self.Experience:SetPoint('TOPRIGHT', self, 'BOTTOMRIGHT', 0, -10)
			self.Experience:SetHeight(11)
			self.Experience:SetStatusBarTexture(texture2)
			self.Experience:SetStatusBarColor(0.15, 0.7, 0.1)
			self.Experience.Tooltip = true

			self.Experience.Rested = CreateFrame('StatusBar', nil, self)
			self.Experience.Rested:SetAllPoints(self.Experience)
			self.Experience.Rested:SetStatusBarTexture(texture2)
			self.Experience.Rested:SetStatusBarColor(0, 0.4, 1, 0.6)
			self.Experience.Rested:SetBackdrop(backdrop)
			self.Experience.Rested:SetBackdropColor(0, 0, 0)
			
			self.Experience.Text = self.Experience:CreateFontString(nil, 'OVERLAY', 'GameFontHighlightSmall')
			self.Experience.Text:SetPoint('CENTER', self.Experience)

			self.Experience.bg = self.Experience.Rested:CreateTexture(nil, 'BORDER')
			self.Experience.bg:SetAllPoints(self.Experience)
			self.Experience.bg:SetTexture(0.3, 0.3, 0.3)
			
			self.Experience:SetScript ('OnEnter', function(self) self:SetAlpha(1) end)
			self.Experience:SetScript ('OnLeave', function(self) self:SetAlpha(0) end)

			
		end
		end
I'm sorry if its a little a stupid question, I'm still learning.
Icerat is offline Report comment to moderator   Edit/Delete Message Reply With Quote
Old 09-07-2009, 06:17 PM  
p3lim
A Molten Giant
 
p3lim's Avatar
Interface Author - Click to view interfaces

Forum posts: 558
File comments: 838
Uploads: 19
Quote:
Originally posted by Icerat
I removed
Code:
self.Experience:EnableMouse(true)
but it didn't make any difference i still get no rested line

EDIT: Only way i could get the tool tip to display the rested line was to add
Code:
self.Experience.Rested = CreateFrame('StatusBar', nil, self)
and then it would show the amount of rested line with no problems.

I now have
Code:
if(IsAddOnLoaded("oUF_Experience") and (unit == "player" or unit == "pet")) then
		self.Experience = CreateFrame("StatusBar", nil, self)
		self.Experience:SetPoint("BOTTOM", self, "TOP", 0, 5)
		if(unit == "pet") then
			self.Experience:SetPoint("BOTTOM", self, "TOP", 0, -31)
		end
		self.Experience:SetHeight(6)
		self.Experience:SetWidth((unit == "pet") and 110 or width)		
		self.Experience:SetStatusBarTexture(texture2)
		self.Experience:SetBackdrop(backdrop)
		self.Experience:SetBackdropColor(0,0,0)	
		self.Experience.PostUpdate = PostUpdateExperience		
		
		self.Experience.Rested = CreateFrame('StatusBar', nil, self)

		self.Experience.bg = self.Experience:CreateTexture(nil, "BORDER")
		self.Experience.bg:SetAllPoints(self.Experience)
		self.Experience.bg:SetTexture(0.3, 0.3, 0.3)
		
		self.Experience:SetScript ('OnEnter', function(self) self:SetAlpha(1) end)
		self.Experience:SetScript ('OnLeave', function(self) self:SetAlpha(0) end)
		self.Experience.Tooltip = true	
	end
Is this correct way to do it, sorry for all the questions i'm learning and its fun
This is not intended, and a fix for it is on its way.
p3lim is offline Report comment to moderator   Edit/Delete Message Reply With Quote
Old 09-07-2009, 01:23 PM  
Icerat
A Fallenroot Satyr

Forum posts: 23
File comments: 41
Uploads: 0
Quote:
Originally posted by p3lim
Works fine for me atleast, though you dont need to enable the mouse, as using .Tooltip does that for you
I removed
Code:
self.Experience:EnableMouse(true)
but it didn't make any difference i still get no rested line

EDIT: Only way i could get the tool tip to display the rested line was to add
Code:
self.Experience.Rested = CreateFrame('StatusBar', nil, self)
and then it would show the amount of rested line with no problems.

I now have
Code:
if(IsAddOnLoaded("oUF_Experience") and (unit == "player" or unit == "pet")) then
		self.Experience = CreateFrame("StatusBar", nil, self)
		self.Experience:SetPoint("BOTTOM", self, "TOP", 0, 5)
		if(unit == "pet") then
			self.Experience:SetPoint("BOTTOM", self, "TOP", 0, -31)
		end
		self.Experience:SetHeight(6)
		self.Experience:SetWidth((unit == "pet") and 110 or width)		
		self.Experience:SetStatusBarTexture(texture2)
		self.Experience:SetBackdrop(backdrop)
		self.Experience:SetBackdropColor(0,0,0)	
		self.Experience.PostUpdate = PostUpdateExperience		
		
		self.Experience.Rested = CreateFrame('StatusBar', nil, self)

		self.Experience.bg = self.Experience:CreateTexture(nil, "BORDER")
		self.Experience.bg:SetAllPoints(self.Experience)
		self.Experience.bg:SetTexture(0.3, 0.3, 0.3)
		
		self.Experience:SetScript ('OnEnter', function(self) self:SetAlpha(1) end)
		self.Experience:SetScript ('OnLeave', function(self) self:SetAlpha(0) end)
		self.Experience.Tooltip = true	
	end
Is this correct way to do it, sorry for all the questions i'm learning and its fun

Last edited by Icerat : 09-07-2009 at 02:58 PM.
Icerat is offline Report comment to moderator   Edit/Delete Message Reply With Quote
Old 09-06-2009, 09:24 AM  
p3lim
A Molten Giant
 
p3lim's Avatar
Interface Author - Click to view interfaces

Forum posts: 558
File comments: 838
Uploads: 19
Quote:
Originally posted by Icerat
I get the 2 lines but no rested xp I know the toon in the pic has 54% rested xp.



I don't know a huge amount about lua but getting there very slowly,i use the following to get my xp bar hidden and how i want it.

Code:
if(IsAddOnLoaded("oUF_Experience") and (unit == "player" or unit == "pet")) then
		self.Experience = CreateFrame("StatusBar", nil, self)
		self.Experience:SetPoint("BOTTOM", self, "TOP", 0, 5)
		if(unit == "pet") then
			self.Experience:SetPoint("BOTTOM", self, "TOP", 0, -31)
		end
		self.Experience:SetHeight(6)
		self.Experience:SetWidth((unit == "pet") and 110 or width)		
		self.Experience:SetStatusBarTexture(texture2)
		self.Experience:SetBackdrop(backdrop)
		self.Experience:SetBackdropColor(0,0,0)	
		self.Experience.PostUpdate = PostUpdateExperience		
		self:RegisterEvent("UPDATE_EXHAUSTION", PostUpdateExperience)
		
		self.Experience.bg = self.Experience:CreateTexture(nil, "BORDER")
		self.Experience.bg:SetAllPoints(self.Experience)
		self.Experience.bg:SetTexture(0.3, 0.3, 0.3)
		
		self.Experience:SetScript ('OnEnter', function(self) self:SetAlpha(1) end)
		self.Experience:SetScript ('OnLeave', function(self) self:SetAlpha(0) end)
		self.Experience:EnableMouse(true)
		self.Experience.Tooltip = true	
	end
Is the correct way to do it?
Works fine for me atleast, though you dont need to enable the mouse, as using .Tooltip does that for you
p3lim is offline Report comment to moderator   Edit/Delete Message Reply With Quote
Old 09-02-2009, 01:23 PM  
Icerat
A Fallenroot Satyr

Forum posts: 23
File comments: 41
Uploads: 0
Quote:
Originally posted by p3lim
It does, though I changed the tooltip a tid bit in the latest few versions.
Should be on the 3rd line in the tooltip though.
I get the 2 lines but no rested xp I know the toon in the pic has 54% rested xp.



I don't know a huge amount about lua but getting there very slowly,i use the following to get my xp bar hidden and how i want it.

Code:
if(IsAddOnLoaded("oUF_Experience") and (unit == "player" or unit == "pet")) then
		self.Experience = CreateFrame("StatusBar", nil, self)
		self.Experience:SetPoint("BOTTOM", self, "TOP", 0, 5)
		if(unit == "pet") then
			self.Experience:SetPoint("BOTTOM", self, "TOP", 0, -31)
		end
		self.Experience:SetHeight(6)
		self.Experience:SetWidth((unit == "pet") and 110 or width)		
		self.Experience:SetStatusBarTexture(texture2)
		self.Experience:SetBackdrop(backdrop)
		self.Experience:SetBackdropColor(0,0,0)	
		self.Experience.PostUpdate = PostUpdateExperience		
		self:RegisterEvent("UPDATE_EXHAUSTION", PostUpdateExperience)
		
		self.Experience.bg = self.Experience:CreateTexture(nil, "BORDER")
		self.Experience.bg:SetAllPoints(self.Experience)
		self.Experience.bg:SetTexture(0.3, 0.3, 0.3)
		
		self.Experience:SetScript ('OnEnter', function(self) self:SetAlpha(1) end)
		self.Experience:SetScript ('OnLeave', function(self) self:SetAlpha(0) end)
		self.Experience:EnableMouse(true)
		self.Experience.Tooltip = true	
	end
Is the correct way to do it?
Icerat is offline Report comment to moderator   Edit/Delete Message Reply With Quote
Old 08-30-2009, 03:00 PM  
p3lim
A Molten Giant
 
p3lim's Avatar
Interface Author - Click to view interfaces

Forum posts: 558
File comments: 838
Uploads: 19
Quote:
Originally posted by roguegenius
is there any addons that let you have more than one experiance bar like the one blizzard already give like a mod that can give u the option to do more.
Try searching this website? Stop asking in my comments, its completely off-topic.
p3lim is offline Report comment to moderator   Edit/Delete Message Reply With Quote
Old 08-30-2009, 02:51 PM  
roguegenius
A Kobold Labourer

Forum posts: 0
File comments: 15
Uploads: 0
Quote:
Originally posted by p3lim
Well, yeah, it requires oUF and a layout that has support for this plug-in
is there any addons that let you have more than one experiance bar like the one blizzard already give like a mod that can give u the option to do more.
roguegenius is offline Report comment to moderator   Edit/Delete Message Reply With Quote
Old 08-30-2009, 02:44 PM  
p3lim
A Molten Giant
 
p3lim's Avatar
Interface Author - Click to view interfaces

Forum posts: 558
File comments: 838
Uploads: 19
Quote:
Originally posted by roguegenius
hey when i downloaded this and installed it i get some weared error on the plugin page saying file depency missing
Well, yeah, it requires oUF and a layout that has support for this plug-in
p3lim is offline Report comment to moderator   Edit/Delete Message Reply With Quote
Old 08-30-2009, 02:42 PM  
roguegenius
A Kobold Labourer

Forum posts: 0
File comments: 15
Uploads: 0
Quote:
Originally posted by p3lim
It does, though I changed the tooltip a tid bit in the latest few versions.
Should be on the 3rd line in the tooltip though.
hey when i downloaded this and installed it i get some weared error on the plugin page saying file depency missing
roguegenius is offline Report comment to moderator   Edit/Delete Message Reply With Quote
Old 08-30-2009, 08:35 AM  
p3lim
A Molten Giant
 
p3lim's Avatar
Interface Author - Click to view interfaces

Forum posts: 558
File comments: 838
Uploads: 19
Quote:
Originally posted by Icerat
After some messing about i got it to auto hide my experience bar and bring it back when i mouse over it and it now shows a tool tip.

Once thing i have noticed though is that it doesn't show the amount of rested in the tool tip anymore, is this by design?

Keep up the great work
It does, though I changed the tooltip a tid bit in the latest few versions.
Should be on the 3rd line in the tooltip though.
p3lim is offline Report comment to moderator   Edit/Delete Message Reply With Quote
Old 08-29-2009, 06:18 PM  
Icerat
A Fallenroot Satyr

Forum posts: 23
File comments: 41
Uploads: 0
After some messing about i got it to auto hide my experience bar and bring it back when i mouse over it and it now shows a tool tip.

Once thing i have noticed though is that it doesn't show the amount of rested in the tool tip anymore, is this by design?

Keep up the great work
Icerat is offline Report comment to moderator   Edit/Delete Message Reply With Quote
Old 08-22-2009, 04:56 PM  
p3lim
A Molten Giant
 
p3lim's Avatar
Interface Author - Click to view interfaces

Forum posts: 558
File comments: 838
Uploads: 19
Quote:
Originally posted by Subere
Not sure if you've fixed this yet or not but I think it's not disabling properly because of your enable / disable functions.

I'm not sure but I don't think the enable / disable functions actually pass a unit argument.

Changing both of the enable / disable functions to:
Code:
local function enable (self)
instead of:
Code:
local function enable (self, unit)
and either changing all the references to unit to self.unit or just adding a local unit = self.unit seemed to fix the problem.
You are right, I'll bring it up with haste.

Last edited by p3lim : 08-22-2009 at 04:59 PM.
p3lim is offline Report comment to moderator   Edit/Delete Message Reply With Quote
Old 08-22-2009, 03:36 PM  
Subere
A Cyclonian
Interface Author - Click to view interfaces

Forum posts: 41
File comments: 22
Uploads: 1
Not sure if you've fixed this yet or not but I think it's not disabling properly because of your enable / disable functions.

I'm not sure but I don't think the enable / disable functions actually pass a unit argument.

Changing both of the enable / disable functions to:
Code:
local function enable (self)
instead of:
Code:
local function enable (self, unit)
and either changing all the references to unit to self.unit or just adding a local unit = self.unit seemed to fix the problem.
Subere is offline Report comment to moderator   Edit/Delete Message Reply With Quote
Old 08-08-2009, 08:42 AM  
p3lim
A Molten Giant
 
p3lim's Avatar
Interface Author - Click to view interfaces

Forum posts: 558
File comments: 838
Uploads: 19
Havent updated anything to wowi yet, just some untested versions so far.
p3lim is offline Report comment to moderator   Edit/Delete Message Reply With Quote
Post A Reply



Category Jump:

Support AddOn Development!

You have just downloaded by the author . If you like this AddOn why not consider supporting the author? This author has set up a donation account. Donations ensure that authors can continue to develop useful tools for everyone.




The Network:
EQInterface | EQ2Interface | LoTROInterface | MMOInterface | War.MMOUI | WoWInterface | VGInterface | Allakhazam | Thottbot | Wowhead | Zam


©2009 MMOUI / ZAM Network
vBulletin - Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.