Last active
December 10, 2015 00:59
-
-
Save warmist/4355458 to your computer and use it in GitHub Desktop.
A list of functions easily called
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--show a list of 'spells' | |
local dlg=require("gui.dialogs") | |
function doNothing() | |
print("Doing nothing real good") | |
end | |
function greetAndStuff() | |
dlg.showMessage("Greetings", "Season's greatings and lols") | |
end | |
listofspells={ | |
{text="nothing", spell=doNothing,icon='*'}, | |
{text="hello world", spell=greetAndStuff,key="CUSTOM_C"}, | |
} | |
dlg.showListPrompt("Spelz","Choze spel",nil, listofspells,function(index,choice) choice.spell() end) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment