aboutsummaryrefslogtreecommitdiff
path: root/oop_example.lua
diff options
context:
space:
mode:
authorDeterminant <[email protected]>2015-05-14 08:08:32 +0800
committerDeterminant <[email protected]>2015-05-14 08:08:32 +0800
commita774bfc860471ac880a9b33bbe68761ec9187caf (patch)
tree67be5f7a04719750441845698ab7426ce9fd8a63 /oop_example.lua
init
Diffstat (limited to 'oop_example.lua')
-rw-r--r--oop_example.lua7
1 files changed, 7 insertions, 0 deletions
diff --git a/oop_example.lua b/oop_example.lua
new file mode 100644
index 0000000..a4e7009
--- /dev/null
+++ b/oop_example.lua
@@ -0,0 +1,7 @@
+a = nerv.point()
+print(a:get_sinx())
+a:set_x(3.14)
+print(a:get_sinx())
+print(a[2])
+a[2] = 3
+print(a[2])