Skip to content
/ Self Public

Simple and compact OOP library for Lua

License

Notifications You must be signed in to change notification settings

Miqueas/Self

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

90 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

License

Self

A small and simple library for OOP in Lua.

Basic usage

Here's a simple example:

local class = require("Self")
local Point = class {
  x = 0,
  y = 0
}

function Point:new(x, y)
  self.x = x
  self.y = y
end

local p = Point(10, 40)

Read the docs here