DurabilityStatus

Description
-----------
A World of Warcraft add-on that allows you to easily view your current equipment durability and can be configured to remind you to repair at merchant. The features are:

- Shows durability of all equipped and bagged items as a percentage in the top right corner of the character model window. A red exclamation mark indicator is shown when an equipped item is broken. The percentage text can be moved by holding down the shift key, clicking and holding the left mouse button, and moving the mouse. The text is always bound to the character window so even if it is moved outside of that window, it will disappear when the character window is closed and reappear when it is opened.

- Displays a small draggable, hideable window that displays the current durability percentage.

- Mousing over the durablity percentages displays a tooltip with estimated equipped item, bagged item, and total repair costs.

- When visiting a merchant who can repair, you are shown a window that reminds you to repair your equipment.

- The character window percentge text, that durability percentage window, and the merchant repair window can all be moved by holding down <shift> and dragging with the mouse.

- Allows you to repair equipped items and items in bags separately if desired.

- Allows you to set a durability warning level from 0 to 99, and displays a dialog box when your durability percentage reaches the specified level or lower.

This addon was initially created by Derkyle, was adapted to patch 1.11 and imported to Cosmos by Zespri, and is currently being maintained by Yarko.


-----------
Keybindings

You can configure keybindings for toggling the display of the floating durability percentage window and for toggling the percentage calculation formula.


----------------
Additional Notes

    * When the merchant option is turned on, the popup window that appears allows you to repair equipped gear (including weapons), items in your bags, or everything. Note that in the standard Blizzard UI since patch 1.11 'Repair all' button will repair everything. If you don't want to spend money on repairing vendor trash you might be carrying, use the 'equipped' button of the popup window. 

    * Note that the tooltip doesn't take into account faction discount if any, unless the merchant window is open. So if you see an amount in the tooltip while you are out in the wild, you may get a better deal for repair if you visit a merchant belonging to a faction with which you are friendly or better. BLIZZARD BUG in patch 2.3: Blizzard's standard API functions do not return the correct discount costs for display in tooltips. The actual cost when repairing will be discounted correctly, but the tooltip won't show the actual final cost. Since DurabilityStatus uses Blizzard's APIs to get cost while at a repair merchant, DS also reports erroneous discounted repair costs. If Blizzard fixes this bug, DS ought to show discounted costs properly. 

    * Report option only works with non-guild repairs done through the DurabilityStatus popup window by pressing one of the three buttons on it. It doesn't affect repairs done with the standard UI or with guild-funded repairs. 

    * Checking the 'Display average durability percentage' option allows to display 'average' durability percent across all equipped items. When off the durability percent of the most damaged equipped item is displayed. 

    * If the DurabilityStatus percentage window is hidden, the reset command will reset its position, but it will remain hidden. 

    * If your logged-in character has been granted guild fund access for repair purposes, an additional button labeled 'Use Guild Funds' will be displayed in the repair popup window. Clicking this button will cause all damaged items, both equipped and in bags, to be repaired using guild funds. If the button appears but is disabled, then there aren't enough guild funds available to you at that time to repair all your damaged items.


-------
Credits

This addon was initially created by Derkyle.
AnduinLothar - thank you for guidelines for including this addon to Cosmos.
Morac, and other Cosmos forums users - thank you for contributing ideas.