From f9d6f8e3a41835671da69f20702c0313bda96fe0 Mon Sep 17 00:00:00 2001 From: Aki Date: Fri, 27 May 2016 17:43:34 +0200 Subject: Controller --- controller.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'controller.lua') diff --git a/controller.lua b/controller.lua index d00f434..d6dcb6d 100644 --- a/controller.lua +++ b/controller.lua @@ -62,7 +62,7 @@ function Controller:keypressed(key, scancode) if self.parent ~= nil and self.joystick == nil then local control = self:testControl(key) if control ~= nil then - self.parent:controllerPressed(control) + self.parent:controllerPressed(control, self) end end end @@ -71,7 +71,7 @@ function Controller:keyreleased(key, scancode) if self.parent ~= nil and self.joystick == nil then local control = self:testControl(key) if control ~= nil then - self.parent:controllerReleased(control) + self.parent:controllerReleased(control, self) end end end @@ -80,6 +80,6 @@ function Controller:isDown(control) if self.joystick == nil then return love.keyboard.isDown(self[control]) else - return self.joystick:isGamepadDown(self[control]) + return self.joystick:isGamepadDown(self[control], self) end end \ No newline at end of file -- cgit v1.1