This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
donnysobonny's profile picture

Completely baffled.

Started by donnysobonny, 07 November 2012 - 01:47 PM
donnysobonny #1
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!
Orwell #2
Posted 07 November 2012 - 04:28 PM
Those issues are due to bugs in the multiplayer version of ccSensors. Development was discontinued, but has been picked up again under the form of an open source project (Cloudy seems to be leading development now :P/>/>). More info can be found here: http://www.computercraft.info/forums2/index.php?/topic/126-mc-125-cc-133-ccsensors-smpssp/

Also, even when this gets finished, I doubt there will be a version of this for MC 1.2.5 (though I'm not sure). So even then you couldn't use it on the current version of Tekkit.
donnysobonny #3
Posted 08 November 2012 - 01:12 AM
Ahh okay, well that certainly clears things up!

Thanks very much for the response!