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

payonel

Developer
  • Content Count

    172
  • Joined

  • Last visited

  • Days Won

    14

Everything posted by payonel

  1. https://github.com/MightyPirates/OpenComputers/issues/2987
  2. `setWirelessFrequency` was a method for rednet wireless redstone, which integration was removed in and after 1.11. in 1.12 we only have redstone and bundled redstone also, updating is a great idea a whole lot was fixed, This is a patch release intended to fix a lot of issues
  3. @Molinkois correct that these things become complex quickly, but I think it is a LOT of fun things like term.write, print, and io.write call io.stdout:write. (by default) io.stdout is the tty stream, and io.stdout:write is https://github.com/MightyPirates/OpenComputers/blob/master-MC1.7.10/src/main/resources/assets/opencomputers/loot/openos/lib/tty.lua#L76
  4. @SpaceBeeGaming thanks for helping a fellow user I also believe 2 of us already pointed that out and the user acknowledged the mistake already (i.e. read the whole comment thread)
  5. that is a ComputerCraft disk drive, not the OpenComputers disk drive
  6. I need to see how your disk drive is "connected" to this computer
  7. Here is basically everything you would ever want to know about startup scripts and such: https://ocdoc.cil.li/tutorial:autorun_options For your needs, I would write a script in my home dir that cleared the screen, set the resolution how I wanted it, and wrote the message, and then waited for user input or something to keep it from closing the program and returning to the shell: local term = require("term") local gpu = require("component").gpu term.clear() gpu.setResolution(20, 5) term.setCursor(5, 3) term.write("Hello World") term.read() When you execute this script, it'll probabl
  8. i do want to point out that plan9k is pretty outdated, will be removed from loot disks in a future release (not the next patch, but after)
  9. A thing microcontrollers are better at than a normal computer (built with a case) is they can house upgrades and run on very low power. World interaction upgrades, such as the tank controller, require a robot or drone. Computer cases do not have an "upgrade" slot
  10. your comments in the tty changes are quite...passionate why did we have such weird \r handling? because users were copying strange mixtures of part mac, part windows, part linux files where line-endings weren't always complete, or fully copied., The output wasn't what they wanted. I agree that \r should be x=1. I might make that change myself. additionally, yes, \b i should have added I don't have any problem ignoring the charset change code. the version of tty and vt100 you have copied appear to be somewhat old, but i do recall making some vt100 fixes, might even be rela
  11. oc wired and wireless modems have addresses, and when you send a message you either broadcast or send to a specific address. You can think of this as its MAC. lua strings are technically just binary blobs, they can hold any binary data (yes, 0s included)
  12. @Elijahlordencould you just remove the / from local file = io.open("/InstallData") to be local file = io.open("InstallData") should work just fine, for both those that think they still need to `cd /` and those that forget/don't know io.open uses relative path from the current working directory
  13. payonel

    gpu.bind() BUG

    This isn't a bug, per se, but you are venturing into unsupported territory of openos For performance reasons and simplicity of code, the core of openos is optimized for the most common workflow, which is 1 screen. There is caching involved in the tty layer of openos to read and write to the same screen and gpu. Some day I'll provide a userspace api for managing multiple screens and multiple windows You'll need to release the keyboard manually See, I just don't support this in openos `require("tty").window.keyboard = nil` 1. This is NOT future proof. When the day comes
  14. local component = require("component") local term = require("term") local text = require("text") local r = component.redstone ---- config section local password = {["1234"] = true, ["foobar"] = true} local delay = 5 --time the door stays open local side = 5 --side of the door, test this ----- local wrong = false while true do term.clear() if wrong then print("Password was wrong, try again") else print("Please enter the password") end wrong = false local input = text.trim(term.read({pwchar='*'}) or "") if passwords[input] then r.setOutput(side, 15) -- check if this
  15. I read what RS devs had to say about the issue, and the problem you are running into is that you are trying to make an exact match, which requires you to specify all the tags of an item. You can't omit some you don't care about. I recommend you do a more general search for items, select the one you care about, and then reuse the search result for future exact searches.
  16. you'll need to share all the code you are using in each side
  17. You can use an item while "sneaking" with the robot component.robot.use(side: number[, sneaky: boolean[, duration: number]]): boolean[, string] see https://ocdoc.cil.li/component:robot
  18. the `block_refinedstorage_grid_2` component is kindly provided by refined storage: https://github.com/raoulvdberge/refinedstorage And in their integration source, they provide the `getItem` component method: https://github.com/raoulvdberge/refinedstorage/blob/mc1.12/src/main/java/com/raoulvdberge/refinedstorage/integration/oc/EnvironmentNetwork.java#L299 I don't know how their compare methods work (you can ask them for more support) But it looks like their getItem method takes a couple extra boolean params for comparing meta and nbt. perhaps you could try `getItem({...}, true, t
  19. also, that tutorial is super old it still works, it appears to have valid instructions but i would recommend just installing openos and rebooting so that your normal filesystem (your root filesystem) is readwrite follow this tutorial: https://ocdoc.cil.li/openos
  20. with an inventory controller, you can inspect stacks in inventories. Place an item you are curious about in a chest, then call component.inventory_controller.getStackInSlot to load data about the item you placed in the chest see https://ocdoc.cil.li/component:inventory_controller
  21. I suspect you tried to run your system on very low memory, and the package library crashed at some earlier point in your workflow, some evidence of this is that you are using `list`, and not `ls` Reboot your system, use only `list` if you are running on ultra-low memory Also, consider adding more memory please. Even 1 stick of tier 1.5 ram is far superior
  22. well...there is plenty of magic in it reading through the source would still be quite rewarding
  23. Our OpenOS threads are not preemptive, but they are also not overtly cooperative. The primary purpose of the thread library was to provide a seamless threading api that doesn't require you to manage the threads, but just trust that they will resume and yield on their own schedule (following one basic rule [continue reading]) Here is the key to understand. There is a single common limitation to your threads (openos threads) and every other normal program you write for OpenOS (and any program on OC machines) : They must periodically make a system yield (i.e. computer.pullSignal). Note that
  24. my code sample isn't using the predefined millibucket values at all. It reads user input and tries to convert it to a number. If you want to build something more clever that does a lookup for predefined sizes, you'll have to design that yourself. Here are a couple of snippets that would do some of what you're saying. local size = tonumber(arg) if not size then if arg == "ingot" then size = 144 end end or local predefined_sizes = { ingot = 144 } local size = predefined_sizes[arg] or tonumber(arg) I could write the whole program, but you'll learn more if you test your
×
×
  • Create New...

Important Information

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