From 93d3257ff23331c308fb32940557911a29ca608b Mon Sep 17 00:00:00 2001 From: Aki Date: Thu, 6 Apr 2017 19:22:26 +0200 Subject: Menu cleaned-up and moved to /not/ Menu is now similar to new code Menu.load => Menu.open --- config/menuhost.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'config/menuhost.lua') diff --git a/config/menuhost.lua b/config/menuhost.lua index 64ce0e7..ae5e3dd 100644 --- a/config/menuhost.lua +++ b/config/menuhost.lua @@ -29,14 +29,14 @@ return { end) :set("active", function (self) MAP = map_selector:getFullSelection(true)[1][1] -- please, don't kill me for this, kek - self.parent:load("menuselect") + self.parent:open("menuselect") end) , button:new(menu) :setText("Go back") :setPosition(bx,117) :set("active", function (self) - self.parent:load("menumain") + self.parent:open("menumain") end) , } \ No newline at end of file -- cgit v1.1 From 37767d6c54ea6af0b4631b5ce838ee584603895e Mon Sep 17 00:00:00 2001 From: Aki Date: Fri, 7 Apr 2017 02:53:36 +0200 Subject: Moved menu configs to subdirectory --- config/menuhost.lua | 42 ------------------------------------------ 1 file changed, 42 deletions(-) delete mode 100644 config/menuhost.lua (limited to 'config/menuhost.lua') diff --git a/config/menuhost.lua b/config/menuhost.lua deleted file mode 100644 index ae5e3dd..0000000 --- a/config/menuhost.lua +++ /dev/null @@ -1,42 +0,0 @@ -local menu = ... - -local button = require "button" -local selector = require "selector" - -local width, height = love.graphics.getWidth()/getScale(), love.graphics.getHeight()/getScale() -local bx = width/2-29 - -local map_selector = selector:new(menu) - -return { - map_selector - :setPosition(width/2, 40) - :setSize(80, 42) - :setMargin(0) - :set("global", true) - :set("first", true) - :set("list", require "maplist") - :set("icons_i", love.graphics.newImage("assets/maps.png")) - :set("icons_q", require "mapicons") - :set("shape", "panorama") - :init() - , - button:new(menu) - :setText("Next") - :setPosition(bx,101) - :set("isEnabled", function () - return map_selector:isLocked() - end) - :set("active", function (self) - MAP = map_selector:getFullSelection(true)[1][1] -- please, don't kill me for this, kek - self.parent:open("menuselect") - end) - , - button:new(menu) - :setText("Go back") - :setPosition(bx,117) - :set("active", function (self) - self.parent:open("menumain") - end) - , -} \ No newline at end of file -- cgit v1.1