28 posts
Posted 26 December 2012 - 12:37 PM
if redstone.getBundledInput ("bottom", colors.red) == true then
print("YES!")
else
print("NO!")
end
This always returns no and I cannot figure out why, the red wire is on and I have a jacketed bundled cable running up to the bottom of my turtle…any ideas?
No error is returned, only "NO!"
2088 posts
Location
South Africa
Posted 26 December 2012 - 12:41 PM
Try
if redstone.testBundledInput("bottom", colours.red) then
print("YES!")
else
print("NO!")
end
28 posts
Posted 26 December 2012 - 12:43 PM
That works, thank you, I don't know why the other one doesn't return true though :/
2088 posts
Location
South Africa
Posted 26 December 2012 - 12:47 PM
Check out the
redstone API on the wiki. Read the descriptions :)/>
redstone.getBundledInput() only has one parameter
2005 posts
Posted 26 December 2012 - 02:33 PM
And, more significantly, it returns an integer number that will never be equal to the boolean value true.