Thread Tools Display Modes
Prev Previous Post   Next Post Next
04/16/14, 03:36 AM   #1
BadVolt
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 74
LUA table: link to self as value

Hello, guys. I'm developing addon MobileBank and I'm stuck... need some advice and fresh look.
So, what do we have. We have "ZO_PlayerBankBackpack.data" table which contents item information about guildbank items. I want to dump it and then give player possibility to open his guildbank in wild. No deposit/withdraw ofc.
It looks simple enought: create black table and use for k,v in pairs()... BUT. Developers "data" table have several links to other controls. And that's worst of it: link to self. Dunno why did developers did such a thing, but it have no scence for me at all
So, when trying do dump such table, it becomes cyclic, unable so save and crashes client.

Any ideas how to dump such table without linking to itself? May be loading emply data and replace values after table created or etc? If so, how can it be done? Anyway, need your advice.

Screenshot of Zgoo (God bless creators of this addon) is below.

Last edited by BadVolt : 04/16/14 at 03:38 AM.
  Reply With Quote
 

ESOUI » Developer Discussions » Lua/XML Help » LUA table: link to self as value


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