Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- f = fs.open("/.quotes","r")
- quote1 = f.readLine()
- quote2 = f.readLine()
- quote3 = f.readLine()
- quote4 = f.readLine()
- quote5 = f.readLine()
- function say(str)
- peripheral.find("command").setCommand("sudo @p ping &d[&c&lGLa&4&lDOS&d] "..str)
- peripheral.find("command").runCommand()
- end
- while true do
- local scrap, message = rednet.receive()
- if message == "quotetest" then
- say(quote1)
- say(quote2)
- say(quote3)
- say(quote4)
- say(quote5)
- elseif message == "start" then
- shell.run("/Quote")
- until message == "end" do
- random = math.random(1,5)
- if random == 1 then
- say(quote1)
- sleep(1)
- elseif random == 2 then
- say(quote2)
- sleep(1)
- elseif random == 3 then
- say(quote3)
- sleep(1)
- elseif random == 4 then
- say(quote4)
- sleep(1)
- elseif random == 5 then
- say(quote5)
- sleep(1)
- end
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement