Download
(151Kb)
Download
Updated: 08-03-10 03:18 AM
Pictures
File Info
Updated:08-03-10 03:18 AM
Created:04-09-10 08:35 AM
Downloads:4,714
Favorites:38
MD5:

Broker H3DungeonCooldowns

Version: r017
by: SuranthianH3 [More]

All users with revision 10 or under, delete it before you install a newer version

***IMPORTANT***
This requires a databroker addon such as
Chocolate Bar or TitanPanel.

Broker_H3DungeonCooldown is only available in English and was designed for enUS. If you aren't enUS, the only thing that should break is expansion sorting. Just disable expansion headers.

Broker H3 DungeonCooldowns started out as a quick "Hello World" test to start out coding Lua in WoW and eventually turned into this. It is a somewhat simple DataBroker Display that shows what dungeons you are saved to and how long until they unlock.

Please provide feedback in comments. Also provide suggestions for more features. I will update with a list of features I plan on adding when there are enough.

It is important that if you find a bug that you please a comment here, otherwise the bug will not be fixed.

Features
Self explanatory section title is self explanatory.

  • Showing data on any/every character on your account (current server). (Note: Requires you to log in atleast once so the addon can register the toon's data into the database.)
  • *NEW* Time for dungeon deserter and random dungeon queue cooldown.
  • Customizing the look of your tooltip with options such as:
    • 2 optional columns for the save's ID and the unlock's date and time (rounded to the nearest 15 minutes, based off of local time)
    • Enabling and disabling the display of expansion content
    • Enabling and disabling the icon's text.
    • *NEW* Adding whitespaces or expansion names between expansion content.
    • Toggling showing unlocked dungeons.
    • Changing the maximum height of the tooltip before it uses a scrollbar.
    • Font options:
      • Change tooltip's text font using shared media (Default Friz Quadrata TT)
      • Change tooltip text sizes (Header, name, hints, text)
    • Change colors of:
      • Dungeon Names
      • Dungeon Difficulties
      • Unlock time remaining (Gradually changes colors as the time expires. So, assuming you are on the default settings and it's a heroic, it will be red at 24 hours, orange at 18, yellow at 12, lime at 6, and green when it's a few minutes.)
      • Class colors (for name display)
      • The separators (Horizontal lines in the tooltip)

  • *NEW* Dungeon Finder Information Including:
    • The average time and average time for every role
    • The role(s) you are queued as in the dungeon finder.
    • *NEW* The time left to accept the invite and what role you are assigned in the group.
    • The roles for the group that have been found (also shows beside the icon, regardless of icon only)
    • Who has accepted the invitation (when the group has been made), even before you accept it!
    • *NEW* Hiding the minimap icon (if wanted)
  • Clicking Line Scripts:
    • Clicking a line to report its info to chat (Doesn't matter what type of click, as long as it isn't a shift click on a current toon's line)
    • Shift-Clicking a line to toggle lock extensions


Known Issues
Issues that are.. Known...
The chat report feature inserts the text without enabling text input, so pressing enter opens the edit box (sets it to full opacity), and clears what was in it.
I am aware of this issue but I do not have a solution at the moment. I am not very experienced in handling widgets. Before, I was using ChatFrameEditBox:Show() and ChatFrameEditBox:Insert(string), but with the new chatbox, the now "ChatFrame1EditBox" is already shown, but doesn't input text unless you hit enter. So I will have to find another way.

Just click the edit box after clicking the line then hit enter, or hit enter, click the line, then hit enter again.

Revision 016 - Bugfix (3.3.5)
- Uploaded a fix by spAnser for the random dungeon cooldown and dungeon deserter.

Revision 016 - Bugfix (3.3.5)
- Forgot for a second that some functions return nil instead of 0 sometimes. Quick fix. Only need this update if you got revision 15.

Revision 015 - FEATURES (Minor) (3.3.5)
- Added Dungeon Deserter and Random Queue Cooldown
- Fixed a minor typo. Removed brackets from dungeon invite roles, but not on the queue. They are now removed from both.
Sorry for the wait, been busy

Revision 014 - FEATURES (3.3.5)
- Removed brackets from LFD roles to preserve space
- Added whitespaces between expansions (none, whitespace, or expansion name)
- Made seperators customizable (color and height)
- Added showing time left and your role on the icon when an invite is avaliable.
- Added a teleport in and out button at the top of the tooltip (EXPERIMENTAL: Only shows if you have a role assigned)
- Added the ability to hide the minimap icon for the LFD system, since this does everything it does

Revision 013 - FEATURES (3.3.3)
- Added dungeon sorting (Expansion, then name, then difficulty)
- Made current character display at the top of the character list instead of where it is alphabetically.
- Added dungeon finder information! Shows average time for every role, average time in general, what you are queued as, what your currently forming group has so far, who accepted the invitation (even before you accept it!)

Revision 012 - BUGFIX (3.3.3)
- Readded AceLocale-3.0


Revision 011 - MAJOR VERSION (3.3.3)
- Rerelease. Remade the entire addon because I know more about Lua now. The nil table bug is now 100% gone without using garbage collection. Delete your old version before installing this new one. It's a "new" addon (different folder name).


Revision 010 fix (3.3.3)
- Nothing important or new, just makes it appear in the addons list next to all of my other mods instead of alone.


Revision 010 - BUGFIX (3.3.3)
- Added garbage collection. No more random nil tables! :D


Revision 009 - BUGFIX (3.3.3)
- Sometimes, if you crash or disconnect, a characters data will go nil (usually the one you're on when you DC). Now, it will notify you upon login/reload that it happened and clear the toon's data, turning it into an empty table with 3 more empty tables (Vanilla, BC, WotLK) instead of getting an error that breaks the addon's tooltip display altogether by leaving it nil. TL;DR - No more table errors.


Revision 008 - BUGFIX (3.3.3)
- Formatting on the chat report had a bug with the name with some settings configured in certain ways (it was either considered nil or it was the wrong character, depended on your character selection setting).


Revision 007 - BUGFIX (3.3.3)
- The report did not have the correct character name and server. It instead reported the last saved character's name.


Revision 006 - FRIDAY-FEATURES (3.3.3)
- Added 2 new columns (optional) for ID and unlock date/time and save ID. Allows toggling expansion headers and whitespaces, setting column alignment, toggling instance extensions for your current toon, and even sending a lines data to chat! I also updated the libraries and showed how long until the addon will load on the icon (when you change options or logon), and made it update the data on rollover instead of every 20 seconds.


Revision 005 - BUGFIX (3.3.3)
- Fixed a bug for people who don't have any other addons that use LibQTip (minor spelling error in the .toc file caused it to not be included). This patch is only needed if you are experiencing a certain error regarding LibQTip in the comments.


Revision 004 - BUGFIX (3.3.3)
- Instances that are unlocked not being registered as an unlocked dungeon if you aren't on that character.


Revision 003 - FRIDAY-FEATURES (3.3.3)
- Allows the showing of date on every single character on your account that you have logged onto with the addon installed.


Revision 002 - BUGFIX (3.3.3)
- Addon's variable tables being invalid on characters that have never done a savable dungeon.


Revision 001 - Initial release (3.3.3)
- Had a bug for toons that have never been in an instance that is savable, so a new version was released less than 30 minutes later.
Post A Reply Comment Options
Unread 12-04-11, 03:57 AM  
Bargan
A Kobold Labourer

Forum posts: 0
File comments: 9
Uploads: 0
for it to work properly in 4.3, you need to change the Broker_H3DungeonCooldowns.lua file.

Inside you will find GetLFGQueueStats in 4 places. Replace each of those lines with the following

Code:
hasData, leaderNeeds, tankNeeds, healerNeeds, dpsNeeds, totalTanks, totalHealers, totalDPS, instanceType, instanceSubType, instanceName, averageWait, tankWait, healerWait, damageWait, myWait, queuedTime = GetLFGQueueStats()

Thanks for that, is working fine now.
Report comment to moderator  
Reply With Quote
Unread 12-03-11, 08:36 PM  
Shamino
A Theradrim Guardian
AddOn Author - Click to view AddOns

Forum posts: 66
File comments: 70
Uploads: 7
Originally Posted by Wall
still no 4.x update?
for it to work properly in 4.3, you need to change the Broker_H3DungeonCooldowns.lua file.

Inside you will find GetLFGQueueStats in 4 places. Replace each of those lines with the following

Code:
hasData, leaderNeeds, tankNeeds, healerNeeds, dpsNeeds, totalTanks, totalHealers, totalDPS, instanceType, instanceSubType, instanceName, averageWait, tankWait, healerWait, damageWait, myWait, queuedTime = GetLFGQueueStats()
Report comment to moderator  
Reply With Quote
Unread 11-18-10, 09:06 AM  
Tntdruid
Premium Member
 
Tntdruid's Avatar
Premium Member
AddOn Author - Click to view AddOns

Forum posts: 55
File comments: 138
Uploads: 3
still no 4.x update?
Report comment to moderator  
Reply With Quote
Unread 08-08-10, 06:11 PM  
Balsta
Guest

Join Date: Not Yet
Forum posts: 0
File comments: 0
Uploads: 0
Yep swapped to Choc and it works so there is a ninjapanel issue somewhere.
Report comment to moderator  
Edit/Delete Message Reply With Quote
Unread 08-08-10, 03:01 PM  
ffcloud2000
A Fallenroot Satyr

Forum posts: 24
File comments: 98
Uploads: 0
Originally posted by Balsta
For some reason I dont get a tooltip at all with this. The tooltip just says "LDBplugin". I use ninjapanel for a display. Any ideas?
I actually had the same issue and had to switch to Chocolate Bar in order for it to show up properly
__________________
Report comment to moderator  
Reply With Quote
Unread 08-08-10, 02:42 PM  
Balsta
Guest

Join Date: Not Yet
Forum posts: 0
File comments: 0
Uploads: 0
For some reason I dont get a tooltip at all with this. The tooltip just says "LDBplugin". I use ninjapanel for a display. Any ideas?
Report comment to moderator  
Edit/Delete Message Reply With Quote
Unread 08-03-10, 03:12 AM  
SuranthianH3
A Murloc Raider
 
SuranthianH3's Avatar
AddOn Author - Click to view AddOns

Forum posts: 8
File comments: 41
Uploads: 4
Originally posted by zaphon
Well it wasn't working for me right either, but I did fix it. Couple things I did.

1. I got rid of the redundant calls to GetLFGRandomCooldownExpiration() and GetLFGDeserterExpiration()

2. I changed the time display to show the time until it resets, versus the time at which it resets (which didn't work anyway, it showed 23 days).

Here's the diff

Code:
***************
*** 1376,1393 ****
  
  	hasData, leaderNeeds, tankNeeds, healerNeeds, dpsNeeds, instanceType, instanceName, averageWait, tankWait, healerWait, damageWait, myWait, queuedTime = GetLFGQueueStats()
  	-- Dungeon Cooldown info (At request of ffcloud2000) --
! 	if (GetLFGRandomCooldownExpiration()) or (GetLFGDeserterExpiration()) then
  		tooltip:AddSeparator(db.separatorSize, db.separatorCol[1], db.separatorCol[2], db.separatorCol[3])
  		-- Time until you can queue for a random again --
! 		if GetLFGRandomCooldownExpiration() then
  			placeHolder = tooltip:AddLine(" ")
! 			tooltip:SetCell(placeHolder, 1, "Random Queue - " .. SecondsToTime(GetLFGRandomCooldownExpiration()), headerFont, "CENTER", tooltip:GetColumnCount())
  		end
  
  		-- Time until you can queue again after leaving a group prematurely --
! 		if GetLFGDeserterExpiration() then
  			placeHolder = tooltip:AddLine(" ")
! 			tooltip:SetCell(placeHolder, 1, "Dungeon Deserter - " .. SecondsToTime(GetLFGDeserterExpiration()), headerFont, "CENTER", tooltip:GetColumnCount())
  		end
  
  		if GetLFGProposal() or hasData then return end
--- 1376,1394 ----
  
  	hasData, leaderNeeds, tankNeeds, healerNeeds, dpsNeeds, instanceType, instanceName, averageWait, tankWait, healerWait, damageWait, myWait, queuedTime = GetLFGQueueStats()
  	-- Dungeon Cooldown info (At request of ffcloud2000) --
! 	local random, deserter, now = GetLFGRandomCooldownExpiration(), GetLFGDeserterExpiration(), GetTime()
! 	if ((random) or (deserter)) then
  		tooltip:AddSeparator(db.separatorSize, db.separatorCol[1], db.separatorCol[2], db.separatorCol[3])
  		-- Time until you can queue for a random again --
! 		if random then
  			placeHolder = tooltip:AddLine(" ")
! 			tooltip:SetCell(placeHolder, 1, "Random Queue - " .. SecondsToTime(random-now), headerFont, "CENTER", tooltip:GetColumnCount())
  		end
  
  		-- Time until you can queue again after leaving a group prematurely --
! 		if deserter then
  			placeHolder = tooltip:AddLine(" ")
! 			tooltip:SetCell(placeHolder, 1, "Dungeon Deserter - " .. SecondsToTime(deserter-now), headerFont, "CENTER", tooltip:GetColumnCount())
  		end
  
  		if GetLFGProposal() or hasData then return end
NOTE: You will see the number show up when you zone into a random, if you mouse over it, as you have the random cooldown until either 15 minutes pass or the instance is completed.
Ok, thanks for the help, never worked with that function before.. I'm out of town right now but I'll do a quick upload of that fix right now.
Report comment to moderator  
Reply With Quote
Unread 07-28-10, 01:52 AM  
spAnser
A Fallenroot Satyr
 
spAnser's Avatar
AddOn Author - Click to view AddOns

Forum posts: 25
File comments: 45
Uploads: 3
when i select my role and it starts turning some of the letters green to show me what it has found its not showing myself as green

btw i have been choosing tank as my role havent tried it as anything else just yet
Report comment to moderator  
Reply With Quote
Unread 07-27-10, 10:22 AM  
zaphon
A Defias Bandit

Forum posts: 2
File comments: 27
Uploads: 0
Originally posted by SuranthianH3
It SHOULD show up at the top of the tooltip, but only when you are a deserter. The code isn't the problem:
Code:
		-- Time until you can queue again after leaving a group prematurely --
		if GetLFGDeserterExpiration() then
			placeHolder = tooltip:AddLine(" ")
			tooltip:SetCell(placeHolder, 1, "Dungeon Deserter - " .. SecondsToTime(GetLFGDeserterExpiration()), headerFont, "CENTER", tooltip:GetColumnCount())
		end
So if it isn't working, then the bug where it doesn't show in the dungeon browser isn't a UI bug, it's the function itself working improperly.

tl;dr - Nothing I can do about it.
Well it wasn't working for me right either, but I did fix it. Couple things I did.

1. I got rid of the redundant calls to GetLFGRandomCooldownExpiration() and GetLFGDeserterExpiration()

2. I changed the time display to show the time until it resets, versus the time at which it resets (which didn't work anyway, it showed 23 days).

Here's the diff

Code:
***************
*** 1376,1393 ****
  
  	hasData, leaderNeeds, tankNeeds, healerNeeds, dpsNeeds, instanceType, instanceName, averageWait, tankWait, healerWait, damageWait, myWait, queuedTime = GetLFGQueueStats()
  	-- Dungeon Cooldown info (At request of ffcloud2000) --
! 	if (GetLFGRandomCooldownExpiration()) or (GetLFGDeserterExpiration()) then
  		tooltip:AddSeparator(db.separatorSize, db.separatorCol[1], db.separatorCol[2], db.separatorCol[3])
  		-- Time until you can queue for a random again --
! 		if GetLFGRandomCooldownExpiration() then
  			placeHolder = tooltip:AddLine(" ")
! 			tooltip:SetCell(placeHolder, 1, "Random Queue - " .. SecondsToTime(GetLFGRandomCooldownExpiration()), headerFont, "CENTER", tooltip:GetColumnCount())
  		end
  
  		-- Time until you can queue again after leaving a group prematurely --
! 		if GetLFGDeserterExpiration() then
  			placeHolder = tooltip:AddLine(" ")
! 			tooltip:SetCell(placeHolder, 1, "Dungeon Deserter - " .. SecondsToTime(GetLFGDeserterExpiration()), headerFont, "CENTER", tooltip:GetColumnCount())
  		end
  
  		if GetLFGProposal() or hasData then return end
--- 1376,1394 ----
  
  	hasData, leaderNeeds, tankNeeds, healerNeeds, dpsNeeds, instanceType, instanceName, averageWait, tankWait, healerWait, damageWait, myWait, queuedTime = GetLFGQueueStats()
  	-- Dungeon Cooldown info (At request of ffcloud2000) --
! 	local random, deserter, now = GetLFGRandomCooldownExpiration(), GetLFGDeserterExpiration(), GetTime()
! 	if ((random) or (deserter)) then
  		tooltip:AddSeparator(db.separatorSize, db.separatorCol[1], db.separatorCol[2], db.separatorCol[3])
  		-- Time until you can queue for a random again --
! 		if random then
  			placeHolder = tooltip:AddLine(" ")
! 			tooltip:SetCell(placeHolder, 1, "Random Queue - " .. SecondsToTime(random-now), headerFont, "CENTER", tooltip:GetColumnCount())
  		end
  
  		-- Time until you can queue again after leaving a group prematurely --
! 		if deserter then
  			placeHolder = tooltip:AddLine(" ")
! 			tooltip:SetCell(placeHolder, 1, "Dungeon Deserter - " .. SecondsToTime(deserter-now), headerFont, "CENTER", tooltip:GetColumnCount())
  		end
  
  		if GetLFGProposal() or hasData then return end
NOTE: You will see the number show up when you zone into a random, if you mouse over it, as you have the random cooldown until either 15 minutes pass or the instance is completed.
Report comment to moderator  
Reply With Quote
Unread 07-19-10, 03:16 AM  
SuranthianH3
A Murloc Raider
 
SuranthianH3's Avatar
AddOn Author - Click to view AddOns

Forum posts: 8
File comments: 41
Uploads: 4
Originally posted by cacomixl8
Two problems I'm having...

1. If you're the last person out of the dungeon, there is no option to teleport out of dungeon. I've had to reenable the minimap icon to be able to get out.

2. Sometimes it does not track the cooldown for the dungeon. I run heroics on 5 characters a day, and just about every day one cooldown is missing in the broker list.

Thanks for the great addon!
1. Not very good with figuring out when you can't teleport in and out of the dungeon, right now it goes off of role, which you can't do if you don't have a role (last one in the instance/everyone else left the group).. Anyone know of a specific variable or function to figure it out? This is why I didn't want to add it, there would be bugs like this :P

2. If you are checking the tooltip RIGHT AFTER the lock, that's probably why, rollover it once to allow it to update the data then rollover again (also, it takes a while for even the official raidlock window to update sometimes). It tries to update every minute or so on a toon, so I don't see why it would be missing. Is anyone else getting this bug of a couple instances flat out not showing? If so maybe a screenshot of the tooltip and one of the raidinfo window? The only reason I could think would be some expansion content being disabled or your client being something other than enUS

Thanks for the feedback. I'll try to update at least once a month, but I haven't been playing much WoW lately.
Last edited by SuranthianH3 : 07-19-10 at 03:23 AM.
Report comment to moderator  
Reply With Quote
Unread 07-18-10, 07:58 PM  
cacomixl8
A Kobold Labourer

Forum posts: 0
File comments: 1
Uploads: 0
Two problems I'm having...

1. If you're the last person out of the dungeon, there is no option to teleport out of dungeon. I've had to reenable the minimap icon to be able to get out.

2. Sometimes it does not track the cooldown for the dungeon. I run heroics on 5 characters a day, and just about every day one cooldown is missing in the broker list.

Thanks for the great addon!
Report comment to moderator  
Reply With Quote
Unread 07-14-10, 05:25 PM  
SuranthianH3
A Murloc Raider
 
SuranthianH3's Avatar
AddOn Author - Click to view AddOns

Forum posts: 8
File comments: 41
Uploads: 4
Originally posted by Nevyr28
Where is the deserter cooldown supposed to show up? I'm using r016 with Bazooka and it's not showing up in the tooltip or the LDB itself.
It SHOULD show up at the top of the tooltip, but only when you are a deserter. The code isn't the problem:
Code:
		-- Time until you can queue again after leaving a group prematurely --
		if GetLFGDeserterExpiration() then
			placeHolder = tooltip:AddLine(" ")
			tooltip:SetCell(placeHolder, 1, "Dungeon Deserter - " .. SecondsToTime(GetLFGDeserterExpiration()), headerFont, "CENTER", tooltip:GetColumnCount())
		end
So if it isn't working, then the bug where it doesn't show in the dungeon browser isn't a UI bug, it's the function itself working improperly.

tl;dr - Nothing I can do about it.
Last edited by SuranthianH3 : 07-15-10 at 12:40 AM.
Report comment to moderator  
Reply With Quote
Unread 07-14-10, 03:57 PM  
Nevyr28
A Defias Bandit

Forum posts: 2
File comments: 24
Uploads: 0
Where is the deserter cooldown supposed to show up? I'm using r016 with Bazooka and it's not showing up in the tooltip or the LDB itself.
Report comment to moderator  
Reply With Quote
Unread 07-14-10, 02:02 PM  
SuranthianH3
A Murloc Raider
 
SuranthianH3's Avatar
AddOn Author - Click to view AddOns

Forum posts: 8
File comments: 41
Uploads: 4
Attempt to compare number with nil: Minor function usage typo

Sorry 'bout that. Will fix it right away.

The issue was me thinking GetLFGRandomCooldownExpiration() and GetLFGDeserterExpiration() were returning 0 if they didn't exist for some reason. But they returned nil. Did a real quick fix and uploaded it. Sorry for the inconvenience.
Last edited by SuranthianH3 : 07-14-10 at 03:34 PM.
Report comment to moderator  
Reply With Quote
Unread 07-14-10, 02:00 PM  
ts7348
A Defias Bandit

Forum posts: 2
File comments: 3
Uploads: 0
There is no popup when moving over the LBD button, but also no error in BugSack (I'm using DockingStation)
Report comment to moderator  
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.