So, I'm trying to load multiple functions in a string, passing them to load(), but whenever I pass them the load() doesn't do ANYTHING. I don't know why..
The string looks like this:
local testString = [[os.queueEvent('char','t')
os.queueEvent('char','e')
os.queueEvent('char','s')
os.queueEvent('char','t')]]
I've tried the other way of doing it..
local testString = "os.queueEvent('char','t'); os.queueEvent('char','e'); os.queueEvent('char','s'); os.queueEvent('char','t')"
Just for clarification, the function is being sent over rednet to another computer which listens with this bit of code:
while true do
local event,id,msg = os.pullEvent()
if event == "rednet_message" then
load(msg)()
end
end
It does work if I just do one function in the string (e.g. 'os.queueEvent('char','t')'), but whenever I add more it doesn't like it.
I know I could pass a function over rednet and call it over the other side but I want to get this working, because it should be and since it's not I needa fix it!