Thread Tools Display Modes
09-17-05, 05:52 PM   #1
Sorian
A Deviate Faerie Dragon
AddOn Author - Click to view addons
Join Date: Sep 2005
Posts: 19
Help getting item price data

I'm trying to get backpacktotal to work with KC_Items. I've gotten it to work so far except for one error. Iget the following error only when I log in. I cna move items around and such and the total value will update and everything works properly. That first error is the only problem.

Here's the error: Interface\Addons\AceDB.lua:81 :attempt to index local `node' (a nil value)

Here's the code I'm using to get price info:
if ((KC_SellValue) and (myValue < 1)) then
local KCitemCode = KC_Items:GetCode(itemLink);
myValue = KC_SellValue:GetPrice(KCitemCode);
end

Anyone have any ideas?
  Reply With Quote
09-17-05, 05:58 PM   #2
Kaelten
Jack's raging bile duct
 
Kaelten's Avatar
Featured
Join Date: May 2005
Posts: 782
try changing

Code:
local KCitemCode = KC_Items:GetCode(itemLink);
myValue = KC_SellValue:GetPrice(KCitemCode);
to

Code:
 
local KCitemCode = KC_Items:GetCode(itemLink);
if (KCitemCode) then
myValue = KC_SellValue:GetPrice(KCitemCode);
end
that error is generally caused by a nil path being sent into the AceDB class. I think this will filter that out.
__________________
WowAce.com & CurseForge.com Adminstrator
Developer of Ace3, OneBag3, and many other addons and libraries
Project lead and Mac developer for the Curse Client

Anyone that needs what they want
And doesn't want what they need
I want nothing to do with
  Reply With Quote
09-17-05, 07:36 PM   #3
Sorian
A Deviate Faerie Dragon
AddOn Author - Click to view addons
Join Date: Sep 2005
Posts: 19
Change didn't help. I made a debug line to show the value of KCitemCode in the text box as each item was being scanned and didn't see any nil or weird values. I also changed the TOC file to make titan panel and KC items a dependency so those 2 addons would load first, no dice.
  Reply With Quote
09-17-05, 07:57 PM   #4
Sorian
A Deviate Faerie Dragon
AddOn Author - Click to view addons
Join Date: Sep 2005
Posts: 19
Fixed

Addon worls perfectly now. I updated to the new version of ace and changed the event handler. The addon author had a weird event handler. Don't know which one fixed it but it works so that's cool. Thanks for your help.
  Reply With Quote
09-17-05, 08:16 PM   #5
Kaelten
Jack's raging bile duct
 
Kaelten's Avatar
Featured
Join Date: May 2005
Posts: 782
hehe glad it works.
__________________
WowAce.com & CurseForge.com Adminstrator
Developer of Ace3, OneBag3, and many other addons and libraries
Project lead and Mac developer for the Curse Client

Anyone that needs what they want
And doesn't want what they need
I want nothing to do with
  Reply With Quote

WoWInterface » AddOns, Compilations, Macros » Released AddOns » Help getting item price data


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off