Posted 22 September 2012 - 12:54 AM
Hi Guys,
I am new to the forum and am relatively new to ComputerCraft. I have been working on a script that takes the users input and displays the corresponding block title for the ID that they entered. My code is as follows:
Thanks,
Daniel
I am new to the forum and am relatively new to ComputerCraft. I have been working on a script that takes the users input and displays the corresponding block title for the ID that they entered. My code is as follows:
write("What item ID?\n")
local ID = read()
if ID == 1 then
write("Stone Selected\n")
end
For some reason the if statement will not work. By this I mean that it just takes the user's input and then does nothing. Nothing is displayed, the code just ends. I have tried everything to the extend of my knowledge and am completely lost. I get no errors, it just does not work when it gets to that section of the code. Please help!Thanks,
Daniel