Posted 23 April 2017 - 04:31 PM
I am attempting to make a program that has computers using rednet to check usernames and passwords, I currently trying to make it so when it gets a rednet message it will open a multishell tab but when the it is finished I want it to close the tab.
Does anyone know a way to do this, I am currently trying to make it switch to the tab then terminate it but when I use multishell.getCurrent() in a tab launched by multishell it give me "attempt to index ?" when I tried this without creating the tab with multishell it works.
here is the code that is running in the tab
Does anyone know a way to do this, I am currently trying to make it switch to the tab then terminate it but when I use multishell.getCurrent() in a tab launched by multishell it give me "attempt to index ?" when I tried this without creating the tab with multishell it works.
here is the code that is running in the tab
local args = {...}
local sender = args[1]
local message = args[2]
local s, m = rednet.receive()
if sender == s then
rednet.send(sender,"Correct")
else
print(sender)
print(s)
end
multishell.getCurrent()
os.queueEvent("terminate")
and here is the code starting the tab
rednet.open("left")
while true do
local s, m = rednet.receive("First")
print("Gotten")
multishell.launch ({},"GetRednet",s,m)
end
does anyone know how to fix this or another way of closing the program?