Mercurial > wow > reagentmaker
comparison utils.lua @ 85:996aaa818d04 v1.0beta4
Clarify error message with cross-tradeskill, and clarify the use of GetTradeSkillLine() internally
| author | contrebasse | 
|---|---|
| date | Sun, 15 May 2011 12:45:52 +0200 | 
| parents | cf1da2654dc6 | 
| children | 8dd86b6b76d8 | 
   comparison
  equal
  deleted
  inserted
  replaced
| 84:10a6078e132f | 85:996aaa818d04 | 
|---|---|
| 249 return unique | 249 return unique | 
| 250 end | 250 end | 
| 251 | 251 | 
| 252 --[[ | 252 --[[ | 
| 253 function A.isTradeskillUnique(itemData) | 253 function A.isTradeskillUnique(itemData) | 
| 254 local spellID = itemData[1].spellID | 254 local spellName = itemData[1].spellName | 
| 255 | 255 | 
| 256 -- Check if the item is made by only one recipe. If not, return | 256 -- Check if the item is made by only one recipe. If not, return | 
| 257 if #itemData>1 then | 257 if #itemData>1 then | 
| 258 for _,v in ipairs(itemData) do | 258 for _,v in ipairs(itemData) do | 
| 259 if v.spellID ~= spellID then | 259 if v.spellName ~= spellName then | 
| 260 spellID = nil | 260 spellName = nil | 
| 261 break | 261 break | 
| 262 end | 262 end | 
| 263 end | 263 end | 
| 264 end | 264 end | 
| 265 | 265 | 
| 266 return spellID | 266 return spellName | 
| 267 end | 267 end | 
| 268 --]] | 268 --]] | 
