Jump to content
  • Sky
  • Blueberry
  • Slate
  • Blackcurrant
  • Watermelon
  • Strawberry
  • Orange
  • Banana
  • Apple
  • Emerald
  • Chocolate
  • Charcoal


Popular Content

Showing content with the highest reputation on 05/28/19 in all areas

  1. 1 point
    Typically the GUI and your application are separated because of the reactive nature of the GUI library. Most of your code for reacting to GUI events will go into a GUIObjects event handler. -- # ... myButton.eventHandler = function(app, instance, event) if event == "touch" then -- # react to touch event. Alter state, etc... end end I don't have the time to test this my self but you could try using OpenOS threads to give control back to your main script. -- # ... more stuff up here local thread = require 'thread' -- # Gui logic n stuff... -- # This will now run whenever the main script yields i.e event.pulls, os.sleeps, etc.. local guiProc = thread.create(application.start, application) -- # Continue below with main program runtime logic. -- # Be aware that the GUI will only be able to process stuff when this main script yields as Lua is single threaded Multiline text is handled by GUI.textBox rather than GUI.text as far as I can tell. Hope this helps you over the initial hump. Happy to help more if you still need it
  • Newsletter

    Want to keep up to date with all our latest news and information?
    Sign Up
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.