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

Molinko

Members
  • Content Count

    451
  • Joined

  • Last visited

  • Days Won

    35

Everything posted by Molinko

  1. From what I understand you're on the right path. What I think* you're missing is a grouping algorithm. Iterate the table for like-pixels chunks by fore/background color and character to draw together. This should result in less gpu calls overall. I'm working on something similar
  2. No, not that I've seen. You can use the Lua interpreter and call process.info(lvl) to explore the returned process. Beware some of the metadata is linked with metatables and so may not appear directly* on the process handle.
  3. Here's a little demo to get you started.. But, the warning I received using this method is that it's an 'internal' method and so subject to possible change in the future. Just FYI. local process = require "process" local term = require "term" local function window(program, dx, dy, width, height) local _window = term.internal.open(dx, dy, width, height) -- # Create a new window term.bind(term.gpu(), _window) -- # derp process.info().data.window = _window -- # Get current process, tack _window unto ...data.window os.execute(program)
  4. That library part is for delay loading and shouldn't be something you need to touch. Just require the keyboard library like normal. To check for key presses other than printable chars use keyboard.isControl(char:number) or catch the key event and compare char codes with entries in the keyboard.keys table.
  5. Both the modem card and the Redstone card have wake methods. See the docs specifically for the mentioned component APIs. I believe they're redstone.setWakeThreshold(level:number) and modem.setWakeMessage(message:string). See http://ocdoc.cil.li/component:modem. Also, pretty sure the modem will still need to have a port open to receive the wake message but don't trust me on that. Test it out
  6. Good suggestion Cpt. I'd also like to suggest table.concat as well.
  7. local input = io.read() if not tonumber(input) then -- input is not a number end
  8. This is working great, although I have some questions. I have read the docs, man, and readme files. Is there a way to route the LAN traffic of a local Relay with a Linked card to a server with the matching linked card? This is the current network diagram. c1---r1--c2 c:computer#n, --:wired connection, r1:relay(with link to s1) s1--back--s2 s1 wired via internal 'back' bus to s2 (s1 has link to r1 | s2 has link to r2)('link' is a linked card) c3--r2--c4 c:computer#n, --:wired, r2:relay (with link to s2) I hope my diagram makes sense. Am I routi
  9. @CptMercury nice detective work. Helpful and informative response. A+
  10. @RGB_Leader You can try this program from the forums by @Nexarius. You can download it from pastebin or github using an internet card and the pastebin or wget program. This has worked for me in the past although I cant speak as to how far back compatibility will be possible. Anywho, it's worth a shot as I have had similar issues before with a version of OpenOS not having the thread library and this worked great for me. Good luck
  11. @BrisingrAerowing, Thanks for the clarification. I was under the impression that the only issue was the OpenOS thread library, which could be downloaded with the latest OpenOS version and without actually needing to update the OC mod itself. My misunderstanding.
  12. @RGB_Leader, XyFreak is referring to OpenOS, the open source OS of Opencomputers. Not the mod or mod pack. You can find it on GitHub.
  13. This is working great for me! Really sweet and tiny too! Although the link to your demo is down.. I'd like to see some examples thank you very mucho.
  14. The problem with your code on the left is that you never define the value of the variable 'message', so when you try to print it you get 'nil' which in lua is a value for nothing. When calling the function event.pull you must capture the return values and store them for use at a later point in the program such as printing or whatever. Here's an example. -- # your code above. this is just in the loop while true do -- # event.pull 'modem_message' return multiple values the fifth being the message data. local laddress, saddress, port, dist, message = event.pull("modem_message") print(me
  15. The first line 'clear' should be 'term.clear()'. That's what's throwing the error.
  16. Threads are just fancy coroutines. This means that they still have to obey and yield like any other process, coroutine, or block of code. All blocks must yield or finish execution in a 5 seconds or they are terminated. Looking into your code as it's arranged now I would suggest yielding once or perhaps several times throughout the checkDmg function depending on the drawing performance. Here would be my two suggested alterations.. function checkDmg() local dmg=0 for i=1,li-1,1 do if inv.getStackInSlot(2,lzhs[i][3]) then dmg=inv.getStackInSlot(2,lzhs[i][3]).customDamage f
  17. You can mock events with computer.pushSignal or event.push.
  18. The mouse position is only available through the aforementioned touch event. It's a client server lag thing.
  19. The OpenOS operating system is itself a program. It needs ram too. It's the most complex program likely to be running on most OC computers. Also, it's a program that runs and controls 0 or more programs, so it uses a bit of ram. However things like the microcontroller don't load an operating system and so 1 tier 1 stick is usually quite enough for most things.
  20. The error is no bootable medium. You needed something to boot. An OS. Stuck an OpenOS floppy in there and run the install program.
  21. It could perhaps be an out of memory error? The getting started tutorial says to use a 1 tier 1 memory stick. Though technically OpenOS has been optimized to run on one it could help to add more memory to the computer. If I'm going to be able to continue to be any help I'm going to need an error message or at least some pictures to let me know where to start looking.
  22. Have you run the install program for OpenOS? Do you get any errors?
  23. @payonel Howdy! About the term lib documentation; I was specifically referring to the doc for term.bind. The optional [screen & keyboard] parameters suggested in the doc dont seem to have an actual implementation in the current OpenOS( although at the time of this response i havent bothered to double check that. Just referring to previous hair pulling encounters ). Ill add a ticket tomorrow if I dont totally space. You did warn me about messing with anything under the .internal space of an OpenOS lib, but I like dancing on sharp edges . Love what you're doing with the place too! (Ope
  24. If you had installed then this shouldn't be your issue as (newer versions of) OpenOS caches the boot drive in the eeprom upon installation. Successive boots should boot from the hdd with the os installed. Though the fact that the autostock program itself is running from /tmp and looking for the config in the /autostock dir, which is in root dir (barf), is a sign of either improper installation or perhaps just poor software quality in the port to OC. Preferably user level programs should be installed somewhere above /home or /usr or even /home/usr. Likewise their libraries or configs probably s
  25. Have you installed OpenOS to the hdd with the install command? It looks like the program is installed to /tmp and the directory /autostock indeed doesnt exist because you booted OpenOS from the floppy? Just a guess.
×
×
  • Create New...

Important Information

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