• Sky
  • Blueberry
  • Slate
  • Blackcurrant
  • Watermelon
  • Strawberry
  • Orange
  • Banana
  • Apple
  • Emerald
  • Chocolate
  • Charcoal
Welcome to OpenComputers

Register now to gain access to all of our features. Once registered and logged in, you will be able to contribute to this site by submitting your own content or replying to existing content. You'll be able to customize your profile, receive reputation points as a reward for submitting content, while also communicating with other members via your own private inbox, plus much more!

This message will be removed once you have signed in.

  • Announcements

    • Lizzy Trickster

      Latest Stable OpenComputers Version   11/26/16

      The latest released version of OpenComputers is version 1.6.1 for MC 1.7.10, 1.8.9, 1.9.4 & 1.10.2. See more information here! Beta/Dev builds can be found at the Jenkins Build Server (ci.cil.li)

Gorzoid

Members
  • Content count

    89
  • Joined

  • Last visited

  • Days Won

    14

About Gorzoid

  • Rank
    Junior Member

Contact Methods

  • Minecraft
    PG_Gorzoid

Recent Profile Visitors

400 profile views
  1. Why not just return
  2. io.read() is a blocking call, you either need to remove that input or use one of the coroutine APIs like threads to run both at the "same" time.
  3. No sides are only available in the 6 axial directions. You can't give arbitrary vectors/angles
  4. getBundledOutput does not return a table, sadly there is no way to get the entire bundled output in 1 call. However that doesn't mean this is impossible, it's actually way easier than you think, you are just using the alternate version of setBundledOutput. According to the docs the first version of setBundledOutput takes side, color, value. So you really don't need functions to do this, but if you're still unsure here is the fixed version. local component = require("component") local rs = component.redstone function addcol(sid, col) rs.setBundledOutput(sid, col, 15) end function remcol(sid, col) rs.setBundledOutput(sid, col, 0) end Also while I was able to understand the attempt in your code, it was both syntactically and logically wrong. You tried to reference your variables by prepending the table which contains the type, and the function arguments were completely wrong. I'd suggest you watch/read a few Lua and OC tutorials, and most importantly read the docs.
  5. My method mimics the general method used in computercraft which would allow easier conversion, many of the oc users used cc before hand or still do so it isn't crazy to believe op might be converting old cc code. pcall method does however fit the op's description while also seeming like less of a hackish method. But just saying pcall will fix it may confuse newer users. It's different to the first method as instead of blocking the interrupt, it just catches it and returns early, causing some of the code not to run. The method of overriding an os function is not ideal and I'd rather the way to cause the interrupt to be passed as an event instead of an error.
  6. Yep whoops thanks for that
  7. Go watch tutorials before screaming for help on forums. ??? Profit
  8. As in locate any player anywhere in the map? You can't, atleast not without a debug card i believe. Motion sensor can detect movement in a small radius and navigation card can get your position relative to a map or waypoint.
  9. https

    I don't think you're using the correct function, internet.open creates a TCP socket with the IP at the port. Try using internet.request, although OC may not support HTTPS, pretty sure computercraft doesn't.
  10. filesystem.open or io.open used like this local io = require("io") local f = io.open("file.txt","w") f:write("file contents") f:close()
  11. geolyzer

    stands for relative x, relative z, relative y, width(x), depth(z), height(y) dunno what last one does.
  12. This is the video I used when drones first came out, the interactive prompt makes it very easy to experiment
  13. Since you have probably done arrays in your C/C++ tables can be explained like this: there are 2 types of tables, numerically indexed table which is like an array (except you start at array[1] rather than array[0]) and there is the hash table which contains 2 values, the key which is used to look up the value, this can be a a number, a string, any type except another table I think. Luckily for you getItemsInNetwork returns this type, so you can just loop from 1 to #essentiatable to get essentiatable. The itemstack values inside the array are hash tables though, you can think of them like structs/classes in C/C++ in this case. They have a specific format and the easiest way to find that format is just by doing what Fingercomp stated above: =component.me_controller.getItemsInNetwork()[1] I'm pretty sure it has a field named "name" so as an example if you wanted to check if the item is cobblestone then you'd do for i = 1,#essentiatable do local item = essentiatable[i] if item.name == "minecraft:cobblestone" then print(serialization.serialize(item) end end
  14. If files and processing was all done client side then having multiple users use a computer would be next to impossible, requiring the server to relay the state of the computer back and forth continuosly. It's also bad networking practice to do any important processing client side.
  15. Have you tried using robot.swingDown from robot API provided by OpenOS?