android - Remove an object class in Corona -
i have new problem... have constuctor this:
function box.new(indexbox, item, imgclose, imgopen) -- constructor local object = { indexbox = indexbox, item = item, imgclose = display.newimage( imgclose ), imgopen = imgopen } return setmetatable( object, box_mt ) end during process i've created box objects , i've finished use them, want remove box objects removing content of object, included image. there easy way this?
thanks!
to delete all box objects, need way access of them. traditional , far (imho) approach have table storing references box 'instances'. such approach need is:
--boxestable contains boxes declared _,box in ipairs(boxestable) box:removeself() end
Comments
Post a Comment