CraftOS Themed Minimenu

Started by KingofGamesYami, Aug 13, 2018, 01:08 am

Previous topic - Next topic

KingofGamesYami

Aug 13, 2018, 01:08 am Last Edit: Aug 13, 2018, 01:11 am by KingofGamesYami Reason: Linked to new CraftOS Themed Menu post
Reposted from here

This is a small function I wrote to emulate the miniature menu of CraftOS's "edit" program. It is very easy to use, and can be used on both advanced and normal computers. It currently will not correct for smaller screen width, if you give it too many options (if you need more, see my menu). If this is a problem, I can update it, but I don't see anyone needing that many options out of this menu.

pastebin get V455UuCr

Usage
This menu is simple to use, simply call the function like so:
Code Select
local selection = minimenu( "Option1", "Option2" )
And it will return either "Option1" or "Option2". You can add as many selections as you want, just remember to use string values.


Questions? Suggestions? Post them below!
I'm a ComputerCraft veteran with over 3k posts on the old ComputerCraft Forum.  I'm mostly inactive in CC having moved on to bigger, more interesting projects but still contribute to the community.

informer

I love the simplicity of this!