Posted 08 March 2014 - 11:18 PM
OK, so I have written my own API named Nico.lua that is located in the folder .technic>modpacks>tekkit>mods>ComputerCraft>lua>rom>apis
(Yes, I am using the modpack tekkit classic which includes computer craft and is running on minecraft version 1.2.5 but i dont know what computer craft version is inculded in tekkit classic)
Now here is what I type in my mining turtle (red is what is actually typed while ">" indicates i hit the enter key): lua>Nico.dig
Now after trying to activate the dig function in my API named Nico.lua I run into this error message over and over again: lua:1: attempt to index ? (a nil value)
Here is what my function is supposed to make the mining turtle do: The turtle is supposed to mine a straight row of ground until it detects there is no more blocks in its path, then it will turn right, move foward, and turn right again to mine another row down the opposite way to complete the proccess.
I have tryed two different ways to code this specific function which will both be included in the pastebin link I provide and both of them have been getting the same error message. I am hoping that you will be able to tell me which version I should use. Please help by telling me what I need to change or pasting my code back with the areas that you have changed in it colored in red. I also hope that the error message will be explained so that if it happens again I can locate what i did wrong and fix the error it is trying to tell me.
Thanks!
Pastebin: http://pastebin.com/6NdZjDQ0
(Yes, I am using the modpack tekkit classic which includes computer craft and is running on minecraft version 1.2.5 but i dont know what computer craft version is inculded in tekkit classic)
Now here is what I type in my mining turtle (red is what is actually typed while ">" indicates i hit the enter key): lua>Nico.dig
Now after trying to activate the dig function in my API named Nico.lua I run into this error message over and over again: lua:1: attempt to index ? (a nil value)
Here is what my function is supposed to make the mining turtle do: The turtle is supposed to mine a straight row of ground until it detects there is no more blocks in its path, then it will turn right, move foward, and turn right again to mine another row down the opposite way to complete the proccess.
I have tryed two different ways to code this specific function which will both be included in the pastebin link I provide and both of them have been getting the same error message. I am hoping that you will be able to tell me which version I should use. Please help by telling me what I need to change or pasting my code back with the areas that you have changed in it colored in red. I also hope that the error message will be explained so that if it happens again I can locate what i did wrong and fix the error it is trying to tell me.
Thanks!
Pastebin: http://pastebin.com/6NdZjDQ0