Posted 07 November 2012 - 02:47 PM
Hey computercraft pros.
I currently play minecraft on a server (tekkit) and am currently working on a lua script for the server users to allow them to select some options and display reading results on a peripheral monitor.
However, I am confronted with an error that has continued to baffle me and some fellow scripters of mine, and is stopping me from being able to finish the script. This error is to do with the ccSensors addition. Please let me know if I am out of place posting my issue here.
The issue:
The problem that I am having seems to be a mixture of a few things. Firstly, after calling the getController api, and then moving onto the getSensor, (either via the built in /console or through some manual script), it is only displaying one sensor, of which has the name "Sensor". This is a problem because one: there are at present atleast 4 sensors in range, and two: none of them have the name "Sensor".
I have tried working around this issue in every way that I can think of. I have renamed everything, rebuilt everything after destroying the items and leaving one controller up and running, causing a newly placed one to link up to a new channel. The issue has persisted on all of these occasions. I have been puzzled with this one for a few days now, and as far as I can remember, it has never come to the point where it shows any other sensors other than the non existant "Sensor" sensor.
It does however show the sensors in range when right-clicking on the controller and navigating down to sensors to see the available sensors…
Ultimately, when I later get to the stage of trying to pass the controller and selected sensor to get the probes, I get the nil error. I get the feeling this issue might be an error within the script somewhere but i've been unable to get as far as debugging it because of the above issue.
Could it possibly be something to do with the server?
I have noticed that even when destroying the sensors themselves, I can still see their names in the list of available sensors when right-clicking the controller…
I could look to gain access to the server files if seeing snippets of the code will help
Many thanks in advance for any help!
I currently play minecraft on a server (tekkit) and am currently working on a lua script for the server users to allow them to select some options and display reading results on a peripheral monitor.
However, I am confronted with an error that has continued to baffle me and some fellow scripters of mine, and is stopping me from being able to finish the script. This error is to do with the ccSensors addition. Please let me know if I am out of place posting my issue here.
The issue:
The problem that I am having seems to be a mixture of a few things. Firstly, after calling the getController api, and then moving onto the getSensor, (either via the built in /console or through some manual script), it is only displaying one sensor, of which has the name "Sensor". This is a problem because one: there are at present atleast 4 sensors in range, and two: none of them have the name "Sensor".
I have tried working around this issue in every way that I can think of. I have renamed everything, rebuilt everything after destroying the items and leaving one controller up and running, causing a newly placed one to link up to a new channel. The issue has persisted on all of these occasions. I have been puzzled with this one for a few days now, and as far as I can remember, it has never come to the point where it shows any other sensors other than the non existant "Sensor" sensor.
It does however show the sensors in range when right-clicking on the controller and navigating down to sensors to see the available sensors…
Ultimately, when I later get to the stage of trying to pass the controller and selected sensor to get the probes, I get the nil error. I get the feeling this issue might be an error within the script somewhere but i've been unable to get as far as debugging it because of the above issue.
Could it possibly be something to do with the server?
I have noticed that even when destroying the sensors themselves, I can still see their names in the list of available sensors when right-clicking the controller…
I could look to gain access to the server files if seeing snippets of the code will help
Many thanks in advance for any help!