You can customize the font, color scheme, spacing and sizing by editing the library directly, all easily found in the top of the file.
Example code:
Code: Select all
GAME_STATE = "MY_MENU"
myMain = StateBasedMenu.create("My Menu",
{"Menu Item 1", "Menu Item 2", "Menu Item 3"},
{"MENU_ITEM_1", "MENU_ITEM_2", "MENU_ITEM_3"})
function love.update(delta)
if GAME_STATE == "MY_MENU" then
myMenu:update()
if myMenu:getState() ~= nil then GAME_STATE = myMenu:getState() end
end
end
function love.draw()
if GAME_STATE == "MY_MENU" then
myMenu:draw()
end
end