Ta©ti Tac0Z Posted September 15, 2017 Posted September 15, 2017 where is the thread api. as i understand it, then the thread api is a build in api in openos aka in /lib (/lib/thread.lua) require("thread") >> file not found (module "thread" not found in: (and so on) ) please tell me if i miss understood this and then were i can get it NOTE: i know that you can get this file on the internet but it does not work that well (at all) Quote
0 Nexarius Posted September 15, 2017 Posted September 15, 2017 What version of OpenOS do you have? (restart the computer and it will tell you at the top) Quote
0 Gorzoid Posted September 15, 2017 Posted September 15, 2017 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/ Quote
0 Ta©ti Tac0Z Posted September 15, 2017 Author Posted September 15, 2017 it's not a modpack i am useing i'am installling all of my mods my self it's oldere version off open os becuse i am useing minecraft version 1.7.10 becuse a lot off the mods i am useing is old thanks for the OS updater program BUT: i found a bug in that updater program the computer that i run it on came whit this boot script error (number 2 computer i run it on worked) unrecoverable error /lib/core/boot.lua:72: boot/94_shell.lua:3: attempt to call a nil value becuse off this is a boot script error (aka the hole os that's failing on boot) it can't be turn on again now this is a computer that there is a lot off thing's i need to use again so if you have a fix then please help me (again) you have been a big help to me thanks Quote
0 Nexarius Posted September 17, 2017 Posted September 17, 2017 I just tried it again (but I have OpenOS 1.6) and it updated normally to OpenOS 1.6.8 Now that the OS is broken there isn't really a way to fix it. I suggest that you make another HDD with a fresh copy of OpenOS then update it to 1.6.8 and then insert your old HDD and copy the files to your new one. Quote
0 Ta©ti Tac0Z Posted September 17, 2017 Author Posted September 17, 2017 i fix it by deleting the broken hard disk. luckly my server program was on a seperate floppy disk so no data lost. thank you (all) for helping me. may god thank you for your good help but i have a new question if you have the time by trying this power full thread system my self i runned in to a problem i don't know if this is even possible but what i am trying to do is this NOTE: that is know that useing a thread in this scene is 100% Unnecessary but remeber this is a simple test -------------------------------------------------------------------------------- thread = require "thread" e = require "event" running = true t = thread.create(function() e.pull("touch") running = false end) while running do --some random thing to run a io.read() will be a good combo print( "you said: "..io.read() ) end ----------------------------------------------------------------------------------------------- so this ends the thread as inspected but does not end the loop my guess is that all things in the thread function is local only but what can i then do to update the "running" value in the global process aka in the while loop all help will be great so please help me again --I beg you Quote
where is the thread api. as i understand it, then the thread api is a build in api in openos aka in /lib (/lib/thread.lua)
please tell me if i miss understood this and then were i can get it
NOTE: i know that you can get this file on the internet but it does not work that well (at all)