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

    1. Announcements

      OpenComputers official announcements.

    2. Feedback

      Tell us what you think.

    3. IRC

      #OC channel discussion
      irc.esper.net #oc

  2. Code Central

    1. Support

      Ask for support from the OpenComputers community

    2. Showcase

      Showcase what you have created for OC. No 'malware' or other junk!

    3. Tutorials

      Help other users out. Please no 'false tutorials'

  3. Addons & More

    1. Addons Mods

      Show off your OC addons mods

    2. Architectures

      Discussions for Architectures

    3. OpenEngineering Task Force

      Discussion board for the OETF documents

  4. General

    1. Lounge

      Just lounge around or have an open discussion.

    2. Forum Games

      Fight boredom!

    3. Showcase

      Show off your creations! (not for your programs)

    4. Servers

      A place to advertise your servers

  5. Archives

    1. Public Archives

      OpenComputers public archive forum

  • Forum Upkeep

    In order to keep the forums updated with improvements and security fixes, we need to pay for a subscription.

    Currently, this is: $25/6-months for the forums itself and $10/6-months for the Theme (totalling $35 USD/6-months).

    You're not obligated to donate anything, but anything you do donate will be much appreciated. :)

    Donate Sidebar by DevFuse
  • Topics

  • Posts

    • local GUI = require("GUI") local component = require 'component' local thread = require 'thread' local event = require 'event' local reactor = component.reactor_chamber local currentTemps = reactor.getHeat() -------------------------------------------------------------------------------- -- Create new application local application = GUI.application() -- Add panel that fits application application:addChild(GUI.panel(1, 1, application.width, application.height, 0x262626)) -- Add smaller panels application:addChild(GUI.panel(4, 2, 23, 4, 0x880000)) application:addChild(GUI.text(5, 3, 0xFFFFFF, "Current Reactor Temps")) -- Grab a reference to the text object you need to update local gui_temp = GUI.text(5, 5, 0xFFFFFF, currentTemps) application:addChild(gui_temp) application:draw(true) -- initial paint thread.create(application.start, application) -- Start the app event handler as a subprocess of this one while true do os.sleep(3) -- Update the element every 3 seconds gui_temp.text = tostring(reactor.getHeat()) gui_temp:update() -- Signal the app that this element should be refreshed end This is just another attempt in case I missed something... If this doesn't work yet again, then could you run `cat /tmp/event.log` after running this (if it fails), and reply with its output if it's available. Threads and event timers don't throw errors in the main process.  
    • 1) yes. The quotes. 2) autorun isn't depricated ( I don't think..) but you might like the .shrc format better. Run 'edit .shrc' in the home dir and add the path to the file you want to run on the first available line. It's super simple and can have multiple programs to run on startup. Also programs can take shell args just like typing it in yourself.
    • hello. i have password lock on my computer and i want to run it automaticaly. i looked to internet and i find some about autorun.lua file (HERE) and i create the file, edit /autorun.lua  and writed this to it : os.execute(/home/door) (i have file named "door") i save it and reboot the OS and for 0.3second there is some red text and after it it goes normaly to /home/ menu i edited the code to os.execute(/home/door.lua) and there is still the same red text and it goes again to /home menu. what i am doing wrong ? edit: i recorded the error and slowed down it in sony vegas and looked to error and i have missing quotes
    • Thank you for your help. Didn't seem to want to update that variable. It will get the first reading when you first run the program up but doesn't want to update properly after that. I may have to refer to the library creator on this.
    • Hello, I would like to use the function .suckFromSlot in a robot so he can suck one item in the slot number 5 from a chest above him. But I don't understand how to use the function because when I've test some program, I've don't success to use it.   Thank you for helping me.
  • Popular Contributors

  • Create New...

Important Information

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