diff options
author | chai <chaifix@163.com> | 2018-08-08 21:42:33 +0800 |
---|---|---|
committer | chai <chaifix@163.com> | 2018-08-08 21:42:33 +0800 |
commit | a03a35b6cfe6399ceaff86a1cc035f1131427955 (patch) | |
tree | ef20b98e6d74ca8a7c2d612b0ef8ad56f1f74a3b /bin/class/class.lua | |
parent | c302ed889e01dcca8fd15ccca34e9f23972c8704 (diff) |
*update
Diffstat (limited to 'bin/class/class.lua')
-rw-r--r-- | bin/class/class.lua | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/bin/class/class.lua b/bin/class/class.lua new file mode 100644 index 0000000..6cff4d7 --- /dev/null +++ b/bin/class/class.lua @@ -0,0 +1,15 @@ +local class = {} + +class.new = function(self, ...) + local c = {} + setmetatable(c, self) + self.__index = self + if self.init then + self.init(...) + end + return c +end + +class.static = {} + +return class
\ No newline at end of file |