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

    • Lizzy Trickster

      Latest Stable OpenComputers Version   11/26/16

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

Gorzoid

Members
  • Content count

    98
  • Joined

  • Last visited

  • Days Won

    20

Gorzoid last won the day on August 30

Gorzoid had the most liked content!

About Gorzoid

  • Rank
    Junior Member

Contact Methods

  • Minecraft
    Gorzoid
  • GitHub
    Gorzoid

Recent Profile Visitors

499 profile views
  1. term.read() problems

    If you want it to work for all words/strings then use "1" instead of 1. In lua numbers and strings are not the same, ie 1 != "1". It seems that lua for some reason allows strings to be implicitly converted to numbers when using arithmetic operators(who do they think they are, JavaScript). So if your inputs aren't restricted to being numbers only then just compare with the number as a string(in quotes)
  2. what am i doing wrong?

    component.invoke(address, "setEnabled", true) Or component.proxy(address).setEnabled(true)
  3. what am i doing wrong?

    excavators.on isnt a function did you mean to use component.invoke/component.proxy
  4. thread question #2

    When you say the loop doesn't end do you mean it doesn't end immediately or it doesn't end after you press enter.
  5. where is the thread api

    Threads are added in 1.6.4, Nexarius seems to have made a very useful program that updates OpenOS even on lower modpack versions. https://oc.cil.li/index.php?/topic/1261-openos-updater/
  6. Robot on top of the shoulder

    The thread containing info on applying is here although considering there is only 10 "entitled players" in over 2 years since the thread was posted (most being staff), I'd say it's pretty difficult to get. Ofcourse you could be evil and just add your name to the list in the code, but I never said that Anyway it would only be client side and only visible in F5 mode so nowhere near as cool as the real deal.
  7. Calculating energy needed for robot travel distance

    Weird the code doesn't show anything about being a variable cost, it seems to be fixed value defined in configs (15 by default)
  8. Redstone Bundle clearity

    The table containing bundled Colour values is colors. If using the lua prompt you can simply do conponent.redstone.setBundledOutput(sides.west, colors.green, 200) but if using a program you must require it. local colors = require("colors") local sides = require("sides") local rs = require("component").redstone rs.setBundledOutputsides.west, colors.green, 200)
  9. Easy item ids?

    NEI has some resource dumpers that you may want to check out, from what I can remember you can dump all items and all recipes into json/csv files.
  10. Motion sensor isn't working

    Why not just return
  11. Motion sensor isn't working

    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.
  12. Sides api custom value

    No sides are only available in the 6 axial directions. You can't give arbitrary vectors/angles
  13. Adding a color to Bundled Output

    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.
  14. 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.
  15. Locate Player

    Yep whoops thanks for that
×