LibPeriodicTable-3.1
Forum Discussion Thread
- Editing - how to maintain PeriodicTable.
- Usage - how to include and use PT sets in your mod.
- API - how to use PeriodicTable in your mod.
- Forum - discussion thread.
- Brush up on your chemistry knowledge.
Periodic Table organizes many WoW items and spells into sets. Like most Ace addons it's focus is efficiency. PT is a LibStub library for managing these sets (ex: Misc.Spell.Mount, Consumable.Food.Edible.Cheese, Misc.Minipet, ClassSpell) for other addons.
If you are looking for a tooltip display addon check out Mendeleev, which you can find on Curse or WoWI.
Item sets are stored as a comma-delimited strings and parsed out into a table only if requested. This speeds up load time and ensures that memory is only used for sets that are actively used.
If you are interested in using PT with your mod feel free to read the source code (there's not a lot). The comments will tell you everything you need to know.
Modules
PeriodicTable's "modules" are simply sets of sets. Particular mods can link the exact sets they need.
- ClassSpell - Spells for all classes with subsets for each tree.
- Consumable - Foods, Potions, Elixirs, Buffing items including type (fruit, meat, etc), quality (inedible, buff) and HP-recovery info.
- CurrencyItems - Items purchasable with various currencies.
- Gear - Socketed gear, Trinkets, Vendor Badge gear
- GearSet - Set Gear. Tier, Reputation, PvP, etc.
- InstanceLoot - Loot tables for instances and the bosses in those instances (only higher-level instances currently)
- InstanceLootHeroic - Loot tables for heroic instances
- Misc - Random stuff like Currency, Containers, Mounts, etc.
- Reputation - Rewards and Turnins for factions
- Tradeskill : Profession recipes
- TradeskillLevels : Profession recipes with level requirements
- TradeskillResultMats : Some kinda mats required sets for the recipes it looks like
I have found what I belive is an error in the DB. I solved a problem I have with the addon MrPlow, http://www.wowace.com/addons/mr-plow/, by deleting a line in LibPeriodic Table-3.1-Misc\LibPeriodicTable-3.1-Misc.lua
This is what I wrote on Curse.com MrPlow addon (yeah Im lazy)
"Ok, I found a solution to my trouble with old warlock bags. I don't recommend you do this unless you have some clue about computers and understand what I did.
The file called "LibPeriodicTable-3.1-Misc.lua" contains information about a lot of items, for example "containers".
They have filled in the warlock bags as "basic" bags witch normal bags are listed as, they just forgot to remove them as warlock bags as well. I guess that causes problems. My solution, delete the whole line with the warlock bags. Im not sure if this solution of mine is a really good one, but it works for me.
Before you edit ANYTHING in that file make a backup of the original so you know how that one looked and can roll back if everything went wrong, ofc you can also reinstall the whole MrPlow addon so its not the end of the world if you mess up.
This is the file you should edit:
AddOns\MrPlow\Libs\LibPeriodic Table-3.1-Misc\LibPeriodicTable-3.1-Misc.lua
On row 15 it says:
["Misc.Bag.Special.Soulshard"]="22243:12,22244:16,21340:20,21341:24,21342:28,21872:28,41597:32",
I deleted the whole line, these numbers on the bags can, as I mentioned earlier, also be found on row 5 "Misc.Bag.Basic"".
I dont know if the author implemented anything wrong but I highly doubt it.
Thanks for a great addon and I hope I contributed a bit... :)
Is there a reason you keep updating the addon but never change the game version to at least 4.0.1?
Hi i got this Error on german realm:
5x LibPeriodicTable-3.1-90006:285: Invalid arg1: invalid item. LibPeriodicTable-3.1-90006:285: in function <...e\libs\LibPeriodicTable-3.1\LibPeriodicTable-3.1.lua:280> (tail call): ?: MiniPet-5.1.215\Companions.lua:608: in function `OnCheckItem' LibLordFarlander-Randomizer-2.0-90152:370: in function <...r-Randomizer-2.0\LibLordFarlander-Randomizer-2.0.lua:317> (tail call): ?: MiniPet-5.1.215\MiniPet.lua:470: in function `OnUpdate' LibLordFarlander-UI-2.0-90177:443: in function <...\LibLordFarlander-UI-2.0\LibLordFarlander-UI-2.0.lua:438>
Locals: self = <table> { ItemSearch = <function> @ DataStore\libs\LibPeriodicTable-3.1\LibPeriodicTable-3.1.lua:344: GetSetString = <function> @ DataStore\libs\LibPeriodicTable-3.1\LibPeriodicTable-3.1.lua:244: IsSetMulti = <function> @ DataStore\libs\LibPeriodicTable-3.1\LibPeriodicTable-3.1.lua:249: ItemInSet = <function> @ DataStore\libs\LibPeriodicTable-3.1\LibPeriodicTable-3.1.lua:280: AddData = <function> @ DataStore\libs\LibPeriodicTable-3.1\LibPeriodicTable-3.1.lua:304: embedversions = <table> {} IterateSet = <function> @ DataStore\libs\LibPeriodicTable-3.1\LibPeriodicTable-3.1.lua:264: sets = <table> {} GetSetTable = <function> @ DataStore\libs\LibPeriodicTable-3.1\LibPeriodicTable-3.1.lua:239: } item = 0 set = "PetAndMountDatabase.Critters" assert = <function> defined =[C]:-1 type = <function> defined =[C]:-1 getItemID = <function> @ DataStore\libs\LibPeriodicTable-3.1\LibPeriodicTable-3.1.lua:50: cache = <table> { InstanceLoot.The Shattered Halls.Warbringer O'mrogg = <table> {} InstanceLoot.Wailing Caverns.Lord Pythas = <table> {} Reputation.Reward.Ironforge = <table> {} InstanceLoot.Blackrock Depths.Panzor the Invincible = <table> {} InstanceLoot.Blackrock Depths.Ok'thor the Breaker = <table> {} InstanceLoot.Upper Blackrock Spire.Warchief Rend Blackhand = <table> {} Reputation.Reward.Undercity = <table> {} InstanceLootHeroic.Auchenai Crypts.Shirrak the Dead Watcher = <table> {} InstanceLootHeroic.Icecrown Citadel.Gunship Armory.10 Man = <table> {} InstanceLootHeroic.Ulduar Hub = <table> {} Tradeskill.Crafted.Engineering.Gnomish = <table> {} InstanceLoot.Trial of the Crusader.The Twin Val'kyr.25 Man = <table> {} InstanceLoot.Zul'Farrak.Zul'Farrak Dead Hero = <table> {} InstanceLoot.The Violet Hold.Moragg = <table> {} InstanceLoot.Lower Blackrock Spire.Spirestone Lord Magus = <table> {} Misc.QuestMats.Arcanum.Protection = <table> {} Reputation.Turnin.Ravenholdt = <table> {} InstanceLoot.Lower Blackrock Spire.Spirestone Battle Lord = <table> {} InstanceLoot.Dire Maul Arena.Mushgog = <table> {} InstanceLoot.Dire Maul.Tendris Warpwood = <table> {} InstanceLootHeroic.Icecrown Citadel.Prince Valanar = <table> {} InstanceLootHeroic.Naxxramas.Sapphiron = <table> {} InstanceLoot.The Obsidian Sanctum.Sartharion = <table> {} InstanceLootHeroic.The Steamvault = <table> {} InstanceLoot.Uldaman.Ancient Stone Keeper = <table> {} InstanceLoot.Serpentshrine Cavern.Hydross the Unstable = <table> {} InstanceLoot.Naxxramas.Patchwerk = <table> {} InstanceLootHeroic.The Arcatraz.Wrath-Scryer Soccothrates = <table> {} InstanceLoot.Uldaman.Ironaya = <table> {} CurrencyItems.Isle of Conquest Mark of Honor = <table> {} InstanceLoot.Ruins of Ahn'Qiraj.Moam = <table> {} InstanceLoot.Blackrock Depths.Seeth'rel = <table> {} CurrencyItems.Arena Points = <table> {} InstanceLoot.Upper Blackrock Spire.Jed Runewatcher = <table> {} InstanceLoot.Trial of the Champion.The Black Knight = <table> {} InstanceLoot.Ahn'kahet: The Old Kingdom.Prince Taldaram = <table> {} InstanceLoot.The Stockade.Hamhock = <table> {} InstanceLoot.Naxxramas.Four Horsemen Chest = <table> {} InstanceLootHeroic.Ulduar.Cache of Storms = <table> {} InstanceLoot.Zul'Gurub.Wushoolay = <table> {} InstanceLoot.Lower Blackrock Spire.Ghok Bashguud = <table> {} Reputation.Reward.Wintersaber Trainers = <table> {} Misc.Bag.Special.Jewelcrafting = <table> {} InstanceLoot.Halls of Reflection.Marwyn = <table> {} InstanceLootHeroic.The Violet Hold.Cyanigosa = <table> {} Reputation.Turnin.The Scryers = <table> {} InstanceLoot.Karazhan.The Curator = <table> {} CurrencyItems.Brewfest Prize Token = <table> {} InstanceLoot.The Stockade.Kam Deepfury = <table> {} Tradeskill.Crafted.Alchemy = <table> {} Reputation.Reward.Frostwolf Clan = <table> {} InstanceLo
-