WoW:TradeSkillLink: Difference between revisions

m
Move page script moved page TradeSkillLink to WoW:TradeSkillLink without leaving a redirect
(→‎Notes: Link maldivia's TradeLinks addon)
m (Move page script moved page TradeSkillLink to WoW:TradeSkillLink without leaving a redirect)
 
(7 intermediate revisions by 6 users not shown)
Line 1: Line 1:
{{Wowapi}}
{{wowapitype}}<br>
 
== tradeSkillLink API Type (String) ==
== tradeSkillLink API Type (String) ==


Line 33: Line 34:


If the recipe list portion of a tradeSkillLink is:
If the recipe list portion of a tradeSkillLink is:
  U<<<<<<<\<<<<<<<\<<<<<
  ZAAAAAAAgAAAAAAAgAAAAA


Then the recipe list bitset is:
Then the recipe list bitset is:
Line 40: Line 41:
This set indicates that four (4) specific recipes are available (note that there are 5 bits; there is no information on why there is an extra bit at this time). Also note that the bitset is unique for each tradeskill; a recipe denoted by bit N in one tradeskill is not the same as a recipe denoted by bit N in another tradeskill.
This set indicates that four (4) specific recipes are available (note that there are 5 bits; there is no information on why there is an extra bit at this time). Also note that the bitset is unique for each tradeskill; a recipe denoted by bit N in one tradeskill is not the same as a recipe denoted by bit N in another tradeskill.


The bitset is encoded into a type of Base64 on a range from character '<' (ASCII 60 or 0x3C) to '{' (ASCII 123 or 0x7B) inclusive. Being Base64, there are 6 bits per digit (similar to how hexadecimal has 4 bits per digit); this allows one to easily determine if a specific bit is set by looking only at a single digit in the string.
The bitset is encoded into standard [http://www.hcidata.info/base64.htm Base64], using the characters A-Z, a-z, 0-9, +, and /. Being Base64, there are 6 bits per digit (similar to how hexadecimal has 4 bits per digit); this allows one to easily determine if a specific bit is set by looking only at a single digit in the string.


TODO: Document bitfield ordering, perhaps by looking at [http://www.wowinterface.com/downloads/info10316-TradeLinks.html Maldivia's TradeLinks addon]
TODO: Document bitfield ordering, perhaps by looking at [http://www.wowinterface.com/downloads/info10316-TradeLinks.html Maldivia's TradeLinks addon]
== Bitsets to Spell IDs ==
To convert a bitset to a list of known skill spell IDs, look in [http://wiki.nibbits.com/wiki/SkillLineAbility.dbc SkillLineAbility.dbc]. Get the lines for your given SkillLineID (column 2), then sort numerically by minSkillLineRank (column 8) ascending, then by SkillLineAbilityID (column 1) ascending. Your spell IDs are in order in column 3, and a set bit in your bitstring corresponds to knowing the spell ID in that position. Column positions are accurate as of this writing (Patch 3.3.3) but may change in future patches.
== Bit Maps ==
These provide bitmaps for 3.1 with all the in-game professions. (please verify these are based on standard Base64)
*Cooking
2/7///7///9////7//////////g+/B
*First Aid
8bffAA


== Link Checking ==
== Link Checking ==
Line 56: Line 69:
  /script DEFAULT_CHAT_FRAME:AddMessage(gsub([[API GetTradeSkillListLink|GetTradeSkillListLink]](), "\124", "\124\124"))
  /script DEFAULT_CHAT_FRAME:AddMessage(gsub([[API GetTradeSkillListLink|GetTradeSkillListLink]](), "\124", "\124\124"))


* [http://www.wowinterface.com/downloads/info10316-TradeLinks.html Maldivia's TradeLinks addon] can create custom tradelinks
* [http://www.wowinterface.com/downloads/info10316-TradeLinks.html Maldivia's TradeLinks addon] can create custom tradelinks.
* [http://wow.curse.com/downloads/wow-addons/details/gnomishyellowpages.aspx Gnomish Yellow Pages] provides examples with full bitmaps, and stores data based on bitmap.
* [http://www.lastcallguild.com/forums/last-call-forums/general-chat/decode-wow-tradeskilllink-recipe-list-c C# TradeSkillList Recipe List Decode] forum post showing example code in C# to decode recipe list.
* [http://www.wowtradeshare.com/ WowTradeShare] is a website where players can post and search tradelinks collected by the TradeShare addon.
Anonymous user