diff options
author | Aki <nthirtyone@gmail.com> | 2016-05-26 17:22:08 +0200 |
---|---|---|
committer | Aki <nthirtyone@gmail.com> | 2016-05-26 17:22:08 +0200 |
commit | d82539a68559c79f3c5488d585354dfcb4f072ad (patch) | |
tree | 37f23be49a4150d547d9854fd2fea56220fa4420 | |
parent | 2252cd12fdceb2799e38bc3cb375c3bbd9be5e7a (diff) | |
download | roflnauts-d82539a68559c79f3c5488d585354dfcb4f072ad.zip roflnauts-d82539a68559c79f3c5488d585354dfcb4f072ad.tar.gz roflnauts-d82539a68559c79f3c5488d585354dfcb4f072ad.tar.bz2 |
F5 fixed
-rw-r--r-- | controller.lua | 1 | ||||
-rw-r--r-- | main.lua | 30 |
2 files changed, 3 insertions, 28 deletions
diff --git a/controller.lua b/controller.lua index 808d660..9e1d8c9 100644 --- a/controller.lua +++ b/controller.lua @@ -15,6 +15,7 @@ Controller = { } -- Constructor +-- joystick, left, right, up, down, attack, jump function Controller:new(joystick, ...) local o = {} setmetatable(o, self) @@ -31,34 +31,6 @@ function love.load () w.Nauts[1]:assignController(cont1) w.Nauts[2]:assignController(cont2) - -- Temporary settings for second player - w.Nauts[2].key_left = "a" - w.Nauts[2].key_right = "d" - w.Nauts[2].key_up = "w" - w.Nauts[2].key_down = "s" - w.Nauts[2].key_jump = "g" - w.Nauts[2].key_hit = "f" - - -- Temporary settings for third player - if third ~= nil then - w.Nauts[3].key_left = "kp4" - w.Nauts[3].key_right = "kp6" - w.Nauts[3].key_up = "kp8" - w.Nauts[3].key_down = "kp5" - w.Nauts[3].key_jump = "kp2" - w.Nauts[3].key_hit = "kp3" - end - - -- Temporary settings for fourth player - if fourth ~= nil then - w.Nauts[4].key_left = "b" - w.Nauts[4].key_right = "m" - w.Nauts[4].key_up = "h" - w.Nauts[4].key_down = "n" - w.Nauts[4].key_jump = "k" - w.Nauts[4].key_hit = "l" - end - -- Menu bijaczes --m = Menu:new() --m:newSelector() @@ -83,6 +55,8 @@ function love.keypressed (key) end if key == "f5" and debug then local new = World:new("default", "leon", "lonestar", third, fourth) + w.Nauts[1]:assignController(cont1) + w.Nauts[2]:assignController(cont2) w = nil w = new end |