summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorAki <nthirtyone@gmail.com>2017-03-19 02:50:40 +0100
committerAki <nthirtyone@gmail.com>2017-03-19 02:50:40 +0100
commita8551f5da9549453381a0f2daa0ff4aefd06272f (patch)
tree5272b1cd7010399b60a0b78787ad7596efb76572
parent4652d69cc88e3d0137cac118344d21853c6a7605 (diff)
downloadroflnauts-a8551f5da9549453381a0f2daa0ff4aefd06272f.zip
roflnauts-a8551f5da9549453381a0f2daa0ff4aefd06272f.tar.gz
roflnauts-a8551f5da9549453381a0f2daa0ff4aefd06272f.tar.bz2
Added tempalte for not.Player
-rw-r--r--not/Player.lua22
1 files changed, 22 insertions, 0 deletions
diff --git a/not/Player.lua b/not/Player.lua
new file mode 100644
index 0000000..bcd72bc
--- /dev/null
+++ b/not/Player.lua
@@ -0,0 +1,22 @@
+--- `Player`
+-- Special `not.Hero` controllable by a player.
+Player = {
+ -- TODO: move functions and properties related to controls from `not.Hero`.
+}
+
+-- `Player` is a child of `Hero`.
+require "not.Hero"
+Player.__index = Player
+setmetatable(Player, Hero)
+
+-- Constructor of `Player`.
+function Player:new (...)
+ local o = setmetatable({}, self)
+ o:init(...)
+ return o
+end
+
+-- Initializator of `Player`.
+function Player:init (...)
+ Hero.init(self, ...)
+end \ No newline at end of file