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

All Activity

This stream auto-updates     

  1. Today
  2. Yesterday
  3. noahthegame

    make opencomputers processors faster

    i'm currecly useing CC becuse of the fact that the speed of witch lua commands is run is based on a speed factor in the processor item limiting the update speed of a program OC is better that CC in all otherways then this, CC does not limit speed (not on purpes anyway) nor does it limit the amout of RAM a spesific computer can use (allso CC have made too much of an effort optimiseing the mod for servers makeing CC look like a simplyfired version of OC - witch i supose it is) anyway of removieing (i know that ain't going to happen) the limit or at least let the computers run faster?
  4. Last week
  5. IlynPayne

    The Guard - security system

    The Guard - security system The Guard is a base security control program I've written in 2016. It allows you to use some of the security devices from the OpenSecurity mod. It has modular architecture - all features are implemented in independent modules that can be replaced. It has action-driven - you can specify how everything behaves using the action system. Features modular architecture action-driven configurable behavior redstone support (Redstone I/O blocks) support of security devices from OpenComputes: keypads biometric readers RFID card readers turrets entity detectors motion sensors alarms Further reading The guard has its own wiki, on which you can find the installation instructions as well as the example configuration and other information. If somebody is interested in writing a new module, I can create a wiki page with API documentation (basic information is provided in the_guard.lua file). WIKI Disclaimer Although I have tested this program, a few issues might have slipped through. In that case feel free to report them in this thread or, even better, on the issue tracker if you have Gitlab account. If there's an error, be sure to include log contents (logs button on the right side of the program's interface) containing that error. Screenshots
  6. Molinko

    Problem with threads

    Lua is single threaded. Meaning that only one chunck of code can ever run at a time. Coroutines are considered co-operative in that they yield to allow others to compute before they themselves finish. The idea is that we can do a little work we need right now and do it quickly, then yield so others can do the same, hence co-operative. Threads are fancy coroutines, but they are still limited to cooperation, so they must yield if you wish to begin another. Use term.read or io.read or os.sleep.... etc.
  7. Lizzy Trickster

    Problem with threads

    Do you sleep/yeild in the while true loops?
  8. Earlier
  9. Molinko

    Inventory Access Side

    I believe this is actually by design so that OC(particularly robots) isn't considered too 'OP'
  10. Wima

    Inventory Access Side

    Hello, some machines have for each inventory Slot a specific side (Input "up" - output "down") like vanilla Furnace. is there any way to choose the access side without moving the robot arround? Steve's Factory manager and XNET with Advanced controller can that. why not OC!
  11. Gamingwelle

    Problem with threads

    Hello, Im currently working on a programm to controll SGCrafts stargates. Im trying to run multiple operations: * Reading inputs from User * check for an open connection (and send a redstone signal it it connected) But its not working. thread = require("thread") function check() while(true) do -- Check and manage the signal end end function userInput() while(true) do -- Process inputs end end thread.create(check) thread.create(userInput) What is the Problem? When I start the first loop the other wont get started. (The same problem with coroutines) So my Questions: 1) Is there any way to get this working? 2) (if not) is there any way to process code while waiting for an userinput via io.read()? Thanks!
  12. SpaceBeeGaming

    Serialization problems

    That was part of the problem, also the issue might have been some typos, which I fixed before. It now works as expected.
  13. Molinko

    Serialization problems

    I haven't tested but I believe the file descriptor has a file position. After the call to :read("*all") you're at the end of the file and thus nil is returned.
  14. SpaceBeeGaming

    Serialization problems

    So, I have been working on an API which allows me to assign additional addresses to computers. And No I have a moment of confusion: function internal.dns.loadHosts() local HOST_FILE_LOC = os.getenv("HOST_FILE_LOC") print(HOST_FILE_LOC) --Prints /usr/misc/hosts.txt assert(HOST_FILE_LOC, "Missing environment variable: HOST_FILE_LOC pointing to a file used for storing dns mamppings ") if (filesystem.exists(HOST_FILE_LOC)) then local hostFile = io.open(HOST_FILE_LOC) print(serialization.unserialize(hostFile:read("*all"))) --prints a table local hosts hosts = serialization.unserialize(hostFile:read("*all")) print(hosts) -- prints nil hostFile:close() return hosts --Return a table of hosts, if successful else return nil --Return nil if hostfile doesnt exist end end Why is it that these two seemingly same calls return different values. one is table other is nil?
  15. Luubstar

    StattenOS - Base control system

    Hey, I liked your OS, but I'm not able to install it, when I try, crashing the pc, saying something about int 24. could you explain how to install it? What do I have to do with the github file? thanks (I'm noob, sorry if this message bothers you:3)
  16. Luubstar

    Opencomputer & Moon base program

    hello, I have some doubts about whether opencomputers and galacticraft are compatible to automate a moon base, sease, automatic airlock, oxygen control, generation graph and storage, plus, if you could look from the earth, thanks: 3
  17. Elektron72

    player program to set off firework machine

    local component = require("component") local sides = require("sides") local rs = component.redstone local dbg = component.debug local computer = component.computer local x = 0 local input = sides.left local output = sides.right while true do if rs.getInput(input) > 0 then x = #dbg.getPlayers() print("Players Updated!") end if x >= 500 then rs.setOutput(output, 15) os.sleep(5) computer.beep() computer.stop() end print(x) os.sleep(0.1) end Requires a redstone card and a debug card. Feel free to change the definitions of the sides input and output. Download from pastebin with this command: pastebin get suXkJWnw fireworks.lua
  18. im new to open computers and I need this for a convention limbocon fuction: set off firework machine if we get 500 players description: ok so heres what I need I need a program which uses this command getplayers()table and link it to a variable x. so I need it to be like this if redstone signal is false do nothing if true run the getplayers()table command tie it to x and make a rule if x>500 (over 500) then send redstone signal and power off machine if x <500 do nothing deadline: preferably today/tomorrow in time for the event
  19. AlexDerErste

    Simple HDD Cloner

    This is a simple program to copy everything from one HDD to another one. https://pastebin.com/kexD5sfq
  20. LordNocturnus

    Internetcard github download

    ok i changed the programm a bit: local c = require("component") local computer = require("computer") local internet = require("internet") local f = io.open("test.txt", "wb") local imax = 0 local xmax = 0 local ymax = 41 local zmax = 1 local TIMEOUT = 5 -- in seconds local link = "https://raw.githubusercontent.com/LordNocturnus/sf-" local folder = "/master/" local pos = 0 for i = 0, imax do for xb = pos, xmax do for yb = 0, ymax do for zb = 0, zmax do print(xb, yb, zb) local file = xb .. "-" .. yb .. "-" .. zb .. ".mb3d" local url = link .. i .. folder .. file local status, connection = pcall(internet.request, url) if not status or not connection then print("Download of " .. url .. " failed.") else local startTime = computer.uptime() while true do local response, isFinished = pcall(connection.finishConnect) if response and isFinished then flagg = true break elseif not response then print("Could not connect to " .. url .. ".") flagg = false break elseif computer.uptime() - startTime > TIMEOUT then print("Request to " .. url .. " timed out") flagg = false break else os.sleep(0.25) end end if flagg == true then local f = io.open(file, "wb") for chunk in response do f:write(chunk) end f:close() connection:close() flagg = false end end end end end end but now i get for file 0 41 0 (first existing file) in line for chunk in response do a "attempt to call a nil value" error
  21. ikillglitch

    Server - no bootable medium

    I have tried that too but it doesn't want to start up too :/ Edit : after playing around i finally found a fix
  22. Molinko

    Internetcard github download

    local c = require("component") local computer = require("computer") local internet = require("internet") local f = io.open("test.txt", "wb") local imax = 0 local xmax = 75 local ymax = 180 local zmax = 87 local TIMEOUT = 5 -- in seconds local link = "https://raw.githubusercontent.com/LordNocturnus/sf-" local folder = "/master/" local pos = 0 for i = 0, imax do for xb = pos, xmax do for yb = 0, ymax do for zb = 0, zmax do print(xb, yb, zb) local file = xb .. "-" .. yb .. "-" .. zb .. ".mb3d" local url = link .. i .. folder .. file local status, connection = pcall(internet.request, url) if not status or not connection then print("Download of " .. url .. " failed.") else local startTime = computer.uptime() while true do local response, isFinished = pcall(connection.finishConnect) if response and isFinished then break elseif not response then print("Could not connect to " .. url .. ".") os.exit() elseif computer.uptime() - startTime > TIMEOUT then print("Request to " .. url .. " timed out") os.exit() else os.sleep(0.25) end end local f = io.open(file, "wb") for chunk in response do f:write(chunk) end f:close() connection:close() end end end end end Fixed some typos and made some things more readable. And a bug...
  23. XyFreak

    Big Reactors Grid Control

    The installer is just badly written and needs to copy everything to ram first *cough* BRGC needs less ram to run than the installer needs ^^;
  24. greenrhino33

    Big Reactors Grid Control

    @XyFreak Ok, thanks. I had a single stick of T2 ram in a T3 case with a T3 and a T2 Hard Drive. Guess that's not quite enough. Installed an additional T3.5 RAM stick and it works like a charm. Thanks for the help!
  25. Elektron72

    Server - no bootable medium

    This means that the computer/server cannot find an operating system. Try adding a disk drive and inserting an operating system disk, such as the OpenOS floppy disk.
  26. ikillglitch

    Server - no bootable medium

    I tried setting up a server as seen in the first picture, but it doesn't want to boot and when i use the analyzer it just says that there is no boot file init.lua as seen in picture 2. How do i fix this?
  27. LordNocturnus

    Internetcard github download

    now i get a "attempt to call method 'close' (a table value)" error
  28. XyFreak

    Big Reactors Grid Control

    @greenrhino33 You need more ram for the installer. Also T1 screens and gpus are not supported (if you intend to use the gui that is)
  29. Fingercomp

    Internetcard github download

    Oh, right... I forgot about that, sorry. Replace socket:close() with response:close().
  1. Load more activity
  • Newsletter

    Want to keep up to date with all our latest news and information?

    Sign Up
×

Important Information

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