Posted 15 February 2013 - 10:21 AM
hey, i've been very bussy since i got help here. but i forgot to add a thing so i can remote controled say to the computer i want the pod to go up. i've got great help here last time and i'm so close to finishing this project.
i added a remote reciever on the black line from the bundled cable at the back of the computer.
how in gods name do i include it in my current program so it wil trigger the lines that make the pod go up then down and then stealth again. pls help.
i added a remote reciever on the black line from the bundled cable at the back of the computer.
how in gods name do i include it in my current program so it wil trigger the lines that make the pod go up then down and then stealth again. pls help.
while 1 == 1 do
term.clear()
term.setCursorPos(1, 1)
local input
print("do you want to call the pod?")
print()
print("y/n")
print()
input = read()
string.lower(input)
-- answer to the question: do you want to call the pod
if input == "y" then
print("the pod is on it's way down")
for a = 1,12 do -- pod coming down
c = colors.combine (c, colors.white)
rs.setBundledOutput("back", c)
sleep(0.5)
c = colors.subtract (c, colors.white)
rs.setBundledOutput("back", c)
sleep(0.5)
end
sleep(5.0)
for a = 1,15 do -- pod going to surface
c = colors.combine (c, colors.orange)
rs.setBundledOutput("back", c)
sleep(0.5)
c = colors.subtract (c, colors.orange)
rs.setBundledOutput("back", c)
sleep(0.5)
end
sleep(5.0)
for a = 1,3 do -- back to stealth mode
c = colors.combine (c, colors.white)
rs.setBundledOutput("back", c)
sleep(0.5)
c = colors.subtract (c, colors.white)
rs.setBundledOutput("back", c)
sleep(0.5)
end
elseif input == "n" then
print("do you want to send the pod up?")
print()
print("y/n")
print()
input = read() -- if input = "y" pod goes up
string.lower(input)
if input == "y" then
print("the pod is on its way up")
for a = 1,3 do -- pod to surface
c = colors.combine(c, colors.orange)
rs.setBundledOutput("back", c)
sleep(0.5)
c = colors.subtract(c, colors.orange)
rs.setBundledOutput("back", c)
sleep(0.5)
end
sleep(5.0)
for a = 1,15 do -- pod goes down
c = colors.combine(c, colors.white)
rs.setBundledOutput("back", c)
sleep(0.5)
c = colors.subtract(c, colors.white)
rs.setBundledOutput("back", c)
sleep(0.5)
end
sleep(5.0)
for a = 1,12 do -- pod goes stealth
c = colors.combine(c, colors.orange)
rs.setBundledOutput("back", c)
sleep(0.5)
c = colors.subtract(c, colors.orange)
rs.setBundledOutput("back", c)
sleep(0.5)
end
elseif input == "n" then
print("okay the pod will stay where it is")
else
print("that is not a valid input, please try again")
end
else
print("that is not a valid input please try again")
end
end