Jump to content


_Zoopy_'s Content

There have been 2 items by _Zoopy_ (Search limited from 29-March 23)


By content type

See this member's

Sort by                Order  

#56092 Lua bundled cables and pistons

Posted by _Zoopy_ on 03 December 2012 - 12:05 AM in Ask a Pro

aaah, thank you very much, spent about 3 hours trying to get this to work.



#56085 Lua bundled cables and pistons

Posted by _Zoopy_ on 02 December 2012 - 10:33 PM in Ask a Pro

Ok, so ive written a code that (is supposed to) push out a piston on the corresponding floor to what is written , heres the code

term.clear()
write ("")
print ("Please Choose a floor")
print ("Floor Choices")
print ("Reactor")
print ("Computer")
print ("Railcraft")


x = io.read()

if x == ("Reactor") then
rs.setBundledOutput ("back", 0)
rs.setBundledOutput ("back", colors.purple)
print ("Have a nice day.")
sleep(3)


if x == ("Computer") then
rs.setBundledOutput ("back", 0)
rs.setBundledOutput ("back", colors.red)
print ("Have a nice day.")
sleep(3)

if x == ("Railcraft") then
rs.setBundledOutput ("back", 0)
print ("Have a nice day.")
sleep(3)
else

print ("Invalid floor name.")
sleep(3)

end
end
end



When i type "Reactor" it works fine and disables the other redstone outputs and enables purple then says have a nice day, but when i type "Computer" it disables other outputs but doesnt enable red and doesnt say have a nice day. When i type "Railcraft" it diables other outputs and doesnt say have a nice day.

Any help would be greatly appreciated.