diff --git a/.luacheckrc b/.luacheckrc new file mode 100644 index 0000000..f75893c --- /dev/null +++ b/.luacheckrc @@ -0,0 +1,4 @@ +return { + std = 'lua51+love', + ignore = {'212'}, +} \ No newline at end of file diff --git a/baton.lua b/baton.lua index 49a9350..245ea90 100644 --- a/baton.lua +++ b/baton.lua @@ -27,8 +27,6 @@ local baton = { ]] } --- utility functions -- - local function parseSource(source) return source:match '(.+):(.+)' end @@ -41,8 +39,6 @@ local function parseHat(value) return value:match '(%d)(.+)' end --- source functions -- - local sf = {kbm = {}, joy = {}} function sf.kbm.key(key) @@ -81,8 +77,6 @@ function sf.joy.hat(joystick, value) return joystick:getHat(hat) == direction and 1 or 0 end --- player class - internal functions -- - local Player = {} Player.__index = Player @@ -219,8 +213,6 @@ function Player:_updatePairs() end end --- player class - public API -- - function Player:update() self:_setActiveDevice() self:_updateControls() @@ -281,8 +273,6 @@ function Player:getActiveDevice() return self._activeDevice end --- baton functions -- - function baton.new(config) local player = setmetatable({}, Player) player:_init(config)