lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Hi.
 
Is there some way fo know how much memory a table uses?
 
I'm using Lua to describe the data of my game, but I think that I'm using
too many table contructors.
Here's a sample:
 
 
Object{
 
  name = "object1",
  flags = F_MONSTER,
 
  itens = {
       skill_easy = { item1, item2 },
       skill_normal = { item3, item4 },
       skill_hard = { item4, item5 },
}
 
}
 
 
Object is a function.
 
I'll have dozens (almost hundreds) of objects like this.
 
Is there som better way of do this? O Lua manges efficiently the memory?
 
Thanks a lot.
 
 



Desafio AntiZona: participe do jogo de perguntas e respostas que vai dar
1 Renault Clio, computadores, câmeras digitais, videogames e muito mais!