Jump to content

Problema com setAccountData


Recommended Posts

  • Other Languages Moderators
-- Para salvar as cores na conta:
local colors = toJSON({r, g, b}) -- Converte a tabela {r, g, b} numa string e salva essa string como accountData.
setAccountData(account, "colors", colors)

-- Para obter as cores da conta:
local data = fromJSON(getAccountData(account, "colors")) -- Converte a string da tabela numa tabela normal.
local r, g, b = unpack(data)

 

  • Thanks 1
Link to comment
Guest
This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...