Objected Oriented Lua is possible using the following approach
http://lua-users.org/wiki/SimpleLuaClasses
https://github.com/kikito/middleclass/wiki/Quick-Example
How to inherit from Corona’s Display Object , so that the new instance of the class can be insert into Display Group ?
require("middleclass")
Ball = class( DisplayObject )
function Ball:initialize(x,y)
self.sprite = display.newCircle( x, y, 10 )
end
local b1 = Ball:new(100,100)
local group = display.newGroup()
group:insert(b1)
[import]uid: 12088 topic_id: 13428 reply_id: 313428[/import]