以下我们演示了Lua 面向对象的完整实例: -- Meta class Shape = {area = 0} -- 基础类方法 new function Shape:new (o,side) o = o or {} setmetatable(o, self) self ...
確定! 回上一頁