mirror of
https://github.com/parnic/breakables.git
synced 2025-06-17 01:41:51 -05:00
Compare commits
77 Commits
Author | SHA1 | Date | |
---|---|---|---|
4b31136512 | |||
f6641909ed | |||
466f952018 | |||
798fc314a3 | |||
5ff9be70da | |||
f9b0d201ea | |||
9aba362e1b | |||
6624d74b2a | |||
619e0f7479 | |||
80bf120abf | |||
d902f864db | |||
9a4c7ddf82 | |||
8bd14cd525 | |||
b086d499b8 | |||
66b0de8074 | |||
62a949cd10 | |||
8f50b7f75f | |||
3f0637641a | |||
6d5d518a8b | |||
d2895bed6a | |||
d2154a350a | |||
a41810c663 | |||
da5e9500f8 | |||
53704888fa | |||
db1819c49f | |||
fb83c4db4a | |||
33e52dc2f6 | |||
74e54e9537 | |||
abea50f496 | |||
2a8bbfcda6 | |||
b970542bfe | |||
8edeeed9e1 | |||
7c19e414e7 | |||
4e65efadff | |||
fea232d8ae | |||
993b99e7be | |||
0442d560d5 | |||
e5968d9441 | |||
814e0ca54f | |||
610f1559fe | |||
140502e508 | |||
302478f872 | |||
a1263947f0 | |||
1e45bfe622 | |||
26d83c425b | |||
8e6867ed44 | |||
a9f1b24563 | |||
a20c5fe54f | |||
e22f4ef334 | |||
c20dabea47 | |||
fa59e6137d | |||
c3ee55d04c | |||
f22c064472 | |||
5628e8d289 | |||
cf128a6a87 | |||
dbd7d69459 | |||
ef4fc31fa6 | |||
b6556dc98d | |||
64a7e73ec0 | |||
30e6b021dd | |||
a701b935b0 | |||
4158971161 | |||
1741f54321 | |||
f93465037d | |||
f9971a7818 | |||
59fd3c320d | |||
4bc72649f2 | |||
4ad9afa103 | |||
958521c6d3 | |||
1401893e2d | |||
f55cd76606 | |||
6a89a7ca11 | |||
a5f5958c5e | |||
2945e6326d | |||
8d590170fe | |||
ce9d162bd3 | |||
cdc3d1c193 |
3
.mailmap
Normal file
3
.mailmap
Normal file
@ -0,0 +1,3 @@
|
||||
parnic <parnic@parnic.com> Parnic <chris@parnic.com>
|
||||
parnic <parnic@parnic.com> Chris Pickett <cpickett@perniciousgames.com>
|
||||
parnic <parnic@parnic.com> root <root@parnic.com>
|
43
.pkgmeta
43
.pkgmeta
@ -1,13 +1,36 @@
|
||||
package-as: Breakables
|
||||
|
||||
externals:
|
||||
libs/LibStub: svn://svn.wowace.com/wow/ace3/mainline/trunk/LibStub
|
||||
libs/CallbackHandler-1.0: svn://svn.wowace.com/wow/ace3/mainline/trunk/CallbackHandler-1.0
|
||||
libs/AceAddon-3.0: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceAddon-3.0
|
||||
libs/AceGUI-3.0: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceGUI-3.0
|
||||
libs/AceConfig-3.0: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceConfig-3.0
|
||||
libs/AceConsole-3.0: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceConsole-3.0
|
||||
libs/AceDB-3.0: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceDB-3.0
|
||||
libs/AceDBOptions-3.0: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceDBOptions-3.0
|
||||
libs/AceEvent-3.0: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceEvent-3.0
|
||||
libs/LibBabble-Inventory-3.0: svn://svn.wowace.com/wow/libbabble-inventory-3-0/mainline/trunk
|
||||
libs/LibStub:
|
||||
url: svn://svn.wowace.com/wow/ace3/mainline/trunk/LibStub
|
||||
tag: latest
|
||||
libs/CallbackHandler-1.0:
|
||||
url: svn://svn.wowace.com/wow/ace3/mainline/trunk/CallbackHandler-1.0
|
||||
tag: latest
|
||||
libs/AceAddon-3.0:
|
||||
url: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceAddon-3.0
|
||||
tag: latest
|
||||
libs/AceGUI-3.0:
|
||||
url: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceGUI-3.0
|
||||
tag: latest
|
||||
libs/AceConfig-3.0:
|
||||
url: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceConfig-3.0
|
||||
tag: latest
|
||||
libs/AceConsole-3.0:
|
||||
url: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceConsole-3.0
|
||||
tag: latest
|
||||
libs/AceDB-3.0:
|
||||
url: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceDB-3.0
|
||||
tag: latest
|
||||
libs/AceDBOptions-3.0:
|
||||
url: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceDBOptions-3.0
|
||||
tag: latest
|
||||
libs/AceEvent-3.0:
|
||||
url: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceEvent-3.0
|
||||
tag: latest
|
||||
libs/AceLocale-3.0:
|
||||
url: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceLocale-3.0
|
||||
tag: latest
|
||||
libs/LibBabble-Inventory-3.0:
|
||||
url: svn://svn.wowace.com/wow/libbabble-inventory-3-0/mainline/trunk
|
||||
tag: latest
|
||||
|
1149
Breakables.lua
1149
Breakables.lua
File diff suppressed because it is too large
Load Diff
@ -1,12 +1,18 @@
|
||||
## Interface: 30300
|
||||
## Interface: 70000
|
||||
## Author: Parnic
|
||||
## Name: Breakables
|
||||
## Title: Breakables |cff7fff7f -Ace3-|r
|
||||
## Title: Breakables |cff7fff7f-Ace3-|r
|
||||
## Notes: Tracks herbs/ore/items that can be broken into component pieces
|
||||
## Version: @project-version@ (Revision: @project-revision@)
|
||||
## SavedVariables: BreakablesDB
|
||||
## OptionalDeps: Ace3, LibBabble-Inventory-3.0
|
||||
## OptionalDeps: Ace3, LibBabble-Inventory-3.0, Masque
|
||||
## X-Compatible-With: 60200
|
||||
|
||||
#@no-lib-strip@
|
||||
embeds.xml
|
||||
#@end-no-lib-strip@
|
||||
# LDB is hard-embedded so don't skip it if packaging no-lib
|
||||
LibDataBroker-1.1.lua
|
||||
loc\loc.xml
|
||||
|
||||
Breakables.lua
|
||||
Breakables.lua
|
||||
|
90
LibDataBroker-1.1.lua
Normal file
90
LibDataBroker-1.1.lua
Normal file
@ -0,0 +1,90 @@
|
||||
|
||||
assert(LibStub, "LibDataBroker-1.1 requires LibStub")
|
||||
assert(LibStub:GetLibrary("CallbackHandler-1.0", true), "LibDataBroker-1.1 requires CallbackHandler-1.0")
|
||||
|
||||
local lib, oldminor = LibStub:NewLibrary("LibDataBroker-1.1", 4)
|
||||
if not lib then return end
|
||||
oldminor = oldminor or 0
|
||||
|
||||
|
||||
lib.callbacks = lib.callbacks or LibStub:GetLibrary("CallbackHandler-1.0"):New(lib)
|
||||
lib.attributestorage, lib.namestorage, lib.proxystorage = lib.attributestorage or {}, lib.namestorage or {}, lib.proxystorage or {}
|
||||
local attributestorage, namestorage, callbacks = lib.attributestorage, lib.namestorage, lib.callbacks
|
||||
|
||||
if oldminor < 2 then
|
||||
lib.domt = {
|
||||
__metatable = "access denied",
|
||||
__index = function(self, key) return attributestorage[self] and attributestorage[self][key] end,
|
||||
}
|
||||
end
|
||||
|
||||
if oldminor < 3 then
|
||||
lib.domt.__newindex = function(self, key, value)
|
||||
if not attributestorage[self] then attributestorage[self] = {} end
|
||||
if attributestorage[self][key] == value then return end
|
||||
attributestorage[self][key] = value
|
||||
local name = namestorage[self]
|
||||
if not name then return end
|
||||
callbacks:Fire("LibDataBroker_AttributeChanged", name, key, value, self)
|
||||
callbacks:Fire("LibDataBroker_AttributeChanged_"..name, name, key, value, self)
|
||||
callbacks:Fire("LibDataBroker_AttributeChanged_"..name.."_"..key, name, key, value, self)
|
||||
callbacks:Fire("LibDataBroker_AttributeChanged__"..key, name, key, value, self)
|
||||
end
|
||||
end
|
||||
|
||||
if oldminor < 2 then
|
||||
function lib:NewDataObject(name, dataobj)
|
||||
if self.proxystorage[name] then return end
|
||||
|
||||
if dataobj then
|
||||
assert(type(dataobj) == "table", "Invalid dataobj, must be nil or a table")
|
||||
self.attributestorage[dataobj] = {}
|
||||
for i,v in pairs(dataobj) do
|
||||
self.attributestorage[dataobj][i] = v
|
||||
dataobj[i] = nil
|
||||
end
|
||||
end
|
||||
dataobj = setmetatable(dataobj or {}, self.domt)
|
||||
self.proxystorage[name], self.namestorage[dataobj] = dataobj, name
|
||||
self.callbacks:Fire("LibDataBroker_DataObjectCreated", name, dataobj)
|
||||
return dataobj
|
||||
end
|
||||
end
|
||||
|
||||
if oldminor < 1 then
|
||||
function lib:DataObjectIterator()
|
||||
return pairs(self.proxystorage)
|
||||
end
|
||||
|
||||
function lib:GetDataObjectByName(dataobjectname)
|
||||
return self.proxystorage[dataobjectname]
|
||||
end
|
||||
|
||||
function lib:GetNameByDataObject(dataobject)
|
||||
return self.namestorage[dataobject]
|
||||
end
|
||||
end
|
||||
|
||||
if oldminor < 4 then
|
||||
local next = pairs(attributestorage)
|
||||
function lib:pairs(dataobject_or_name)
|
||||
local t = type(dataobject_or_name)
|
||||
assert(t == "string" or t == "table", "Usage: ldb:pairs('dataobjectname') or ldb:pairs(dataobject)")
|
||||
|
||||
local dataobj = self.proxystorage[dataobject_or_name] or dataobject_or_name
|
||||
assert(attributestorage[dataobj], "Data object not found")
|
||||
|
||||
return next, attributestorage[dataobj], nil
|
||||
end
|
||||
|
||||
local ipairs_iter = ipairs(attributestorage)
|
||||
function lib:ipairs(dataobject_or_name)
|
||||
local t = type(dataobject_or_name)
|
||||
assert(t == "string" or t == "table", "Usage: ldb:ipairs('dataobjectname') or ldb:ipairs(dataobject)")
|
||||
|
||||
local dataobj = self.proxystorage[dataobject_or_name] or dataobject_or_name
|
||||
assert(attributestorage[dataobj], "Data object not found")
|
||||
|
||||
return ipairs_iter, attributestorage[dataobj], 0
|
||||
end
|
||||
end
|
@ -6,6 +6,8 @@
|
||||
<Include file="libs\AceConfig-3.0\AceConfig-3.0.xml"/>
|
||||
<Include file="libs\AceConsole-3.0\AceConsole-3.0.xml"/>
|
||||
<Include file="libs\AceDB-3.0\AceDB-3.0.xml"/>
|
||||
<Include file="libs\AceDBOptions-3.0\AceDBOptions-3.0.xml"/>
|
||||
<Include file="libs\AceEvent-3.0\AceEvent-3.0.xml"/>
|
||||
<Include file="libs\AceLocale-3.0\AceLocale-3.0.xml"/>
|
||||
<Include file="libs\LibBabble-Inventory-3.0\lib.xml"/>
|
||||
</Ui>
|
4
loc/deDE.lua
Normal file
4
loc/deDE.lua
Normal file
@ -0,0 +1,4 @@
|
||||
local L = LibStub("AceLocale-3.0"):NewLocale("Breakables", "deDE")
|
||||
if not L then return end
|
||||
|
||||
--@localization(locale="deDE", format="lua_additive_table", handle-subnamespaces="concat", handle-unlocalized="english")@
|
15
loc/enUS.lua
Normal file
15
loc/enUS.lua
Normal file
@ -0,0 +1,15 @@
|
||||
local debug = false
|
||||
--@debug@
|
||||
debug = true
|
||||
--@end-debug@
|
||||
|
||||
local L = LibStub("AceLocale-3.0"):NewLocale("Breakables", "enUS", true, debug)
|
||||
|
||||
--@localization(locale="enUS", format="lua_additive_table", same-key-is-true=true, handle-subnamespaces="concat")@
|
||||
--@debug@
|
||||
L["Welcome"] = [[Thanks for using |cff33ff99Breakables|r! Use |cffffff78/brk|r to open this menu or |cffffff78/breakables|r to access the same options on the command line.
|
||||
|
||||
Hold shift and drag the profession button to move the breakables bar around. You can also click directly on any breakable item button to break it without having to click the profession button first.
|
||||
|
||||
If you have any feature requests or problems, please email |cff33ff99breakables@parnic.com|r or visit the |cffffff78curse.com|r or |cffffff78wowinterface.com|r page and leave a comment.]]
|
||||
--@end-debug@
|
4
loc/esES.lua
Normal file
4
loc/esES.lua
Normal file
@ -0,0 +1,4 @@
|
||||
local L = LibStub("AceLocale-3.0"):NewLocale("Breakables", "esES")
|
||||
if not L then return end
|
||||
|
||||
--@localization(locale="esES", format="lua_additive_table", handle-subnamespaces="concat", handle-unlocalized="english")@
|
4
loc/esMX.lua
Normal file
4
loc/esMX.lua
Normal file
@ -0,0 +1,4 @@
|
||||
local L = LibStub("AceLocale-3.0"):NewLocale("Breakables", "esMX")
|
||||
if not L then return end
|
||||
|
||||
--@localization(locale="esMX", format="lua_additive_table", handle-subnamespaces="concat", handle-unlocalized="english")@
|
4
loc/frFR.lua
Normal file
4
loc/frFR.lua
Normal file
@ -0,0 +1,4 @@
|
||||
local L = LibStub("AceLocale-3.0"):NewLocale("Breakables", "frFR")
|
||||
if not L then return end
|
||||
|
||||
--@localization(locale="frFR", format="lua_additive_table", handle-subnamespaces="concat", handle-unlocalized="english")@
|
4
loc/koKR.lua
Normal file
4
loc/koKR.lua
Normal file
@ -0,0 +1,4 @@
|
||||
local L = LibStub("AceLocale-3.0"):NewLocale("Breakables", "koKR")
|
||||
if not L then return end
|
||||
|
||||
--@localization(locale="koKR", format="lua_additive_table", handle-subnamespaces="concat", handle-unlocalized="english")@
|
13
loc/loc.xml
Normal file
13
loc/loc.xml
Normal file
@ -0,0 +1,13 @@
|
||||
<Ui xmlns="http://www.blizzard.com/wow/ui/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.blizzard.com/wow/ui/..\FrameXML\UI.xsd">
|
||||
|
||||
<Script file="enUS.lua"/>
|
||||
<Script file="deDE.lua"/>
|
||||
<Script file="esES.lua"/>
|
||||
<Script file="esMX.lua"/>
|
||||
<Script file="frFR.lua"/>
|
||||
<Script file="koKR.lua"/>
|
||||
<Script file="ruRU.lua"/>
|
||||
<Script file="zhCN.lua"/>
|
||||
<Script file="zhTW.lua"/>
|
||||
|
||||
</Ui>
|
4
loc/ruRU.lua
Normal file
4
loc/ruRU.lua
Normal file
@ -0,0 +1,4 @@
|
||||
local L = LibStub("AceLocale-3.0"):NewLocale("Breakables", "ruRU")
|
||||
if not L then return end
|
||||
|
||||
--@localization(locale="ruRU", format="lua_additive_table", handle-subnamespaces="concat", handle-unlocalized="english")@
|
4
loc/zhCN.lua
Normal file
4
loc/zhCN.lua
Normal file
@ -0,0 +1,4 @@
|
||||
local L = LibStub("AceLocale-3.0"):NewLocale("Breakables", "zhCN")
|
||||
if not L then return end
|
||||
|
||||
--@localization(locale="zhCN", format="lua_additive_table", handle-subnamespaces="concat", handle-unlocalized="english")@
|
4
loc/zhTW.lua
Normal file
4
loc/zhTW.lua
Normal file
@ -0,0 +1,4 @@
|
||||
local L = LibStub("AceLocale-3.0"):NewLocale("Breakables", "zhTW")
|
||||
if not L then return end
|
||||
|
||||
--@localization(locale="zhTW", format="lua_additive_table", handle-subnamespaces="concat", handle-unlocalized="english")@
|
20
readme.md
Normal file
20
readme.md
Normal file
@ -0,0 +1,20 @@
|
||||
### **Description**
|
||||
|
||||
Displays a bar on screen that allows quick access to enchanting, jewelcrafting, and inscription professions by presenting a Disenchant/Prospect/Mill button and all of the breakable items you have for that profession next to it. Also displays a bar for any locked junkboxes in your inventory if you're a Rogue. This allows one-click access for breaking down items instead of finding the item in your bag, clicking the appropriate profession/skill button, and clicking the item for each and every item you want to break. For prospecting and milling, you will see the number of items you have alongside the number of times you can break it. In the prospecting screenshot on the right, the player has 169 total Saronite Ore in his bags which will allow for 33 total prospects.
|
||||
|
||||
### **Usage**
|
||||
|
||||
By default, if you have the appropriate profession and items in your inventory, a bar will appear with the profession ability followed by any items that are eligible for breaking. You can hold shift to drag the bar around if you want to move it. Clicking the profession button will activate that ability (disenchant/prospect/mill) and clicking an item will break it. You don't have to click the profession button first as simply clicking the item will automatically break it down.
|
||||
|
||||
### **Configuration**
|
||||
|
||||
Typing */brk* will open the configuration settings (or you can get to it from Blizzard's Interface options) which consist of:
|
||||
|
||||
* **Hide if no breakables**: this will control whether you see the profession button or not when nothing breakable is detected
|
||||
* **Max number to display**: this controls the highest number of items that you will see next to your profession button. If this is 5 but you have 10 breakable items in your bags, you will only see 5 at a time.
|
||||
* **Show soulbound items**: aimed at enchanters, this controls whether or not you will see items that are soulbound as breakable items or not.
|
||||
|
||||
|
||||
### **Known issues**
|
||||
* If you have more than 5 of a breakable item but split into stacks all smaller than 5, the game will say you do not have enough items to break. The default UI now has a built-in button to compress stacks that should solve this issue.
|
||||
* If you know Mass Milling for a specific type of herb, the current alpha will try to use this ability and fail. I am in the process of leveling a scribe up high enough to debug this problem.
|
Reference in New Issue
Block a user