Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Sensor Question

Smithy Zeno
ownes 9 pet cacti
Join date: 3 Aug 2006
Posts: 52
12-25-2007 19:11
Hey Everyone,
First of all, Merry Christmas!!! Anyways, is it possible to make a sensor sense objects in a line? To be more specific, say I have two objects parallel to each other. I want one object to be able to detect the other object, but only in a straight line. I could use collision, but I'd prefer sensors. Thanks for any help in advance.
_____________________
-Smithy
Mrc Homewood
Mentor of Randomness
Join date: 24 Feb 2007
Posts: 779
12-25-2007 19:54
i dont belive so, but you can have it detect scripted objects
Xhawkx Holden
Registered User
Join date: 1 Nov 2006
Posts: 86
12-25-2007 20:51
I am not sure I understand what you are asking.. A sensor can detect up to 95 meters away.. and can be configured to detect anywhere from a full sphere around, to half a sphere, down to a very narrow cone shape.. This would almost be a line if the cone were narrow enough. Maybe that helps..
You can find some excellent explanations and visualizations here:

http://rpgstats.com/wiki/index.php?title=LlSensor
Krista Chaffe
Registered User
Join date: 16 Jun 2007
Posts: 96
12-26-2007 09:33
I think to get a 'real' line you would have to do the math on their positions.

That way it would me independent of the sensor location
Ordinal Malaprop
really very ordinary
Join date: 9 Sep 2005
Posts: 4,607
12-26-2007 10:10
You do - you can't just narrow the cone down to a very thin one, because the centre of the detected object has to be within the cone, and thus you'd have to be very lucky to hit it.

I'm not precisely sure what is being asked here either but this might be useful as an example of the maths concerned, though I'm sure it could be tidied up:
http://ordinalmalaprop.com/wiki/index.php?title=Script:Forward_avatar_intersect
_____________________
http://ordinalmalaprop.com/forum/ - visit Ordinal's Scripting Colloquium for scripting discussion with actual working BBCode!

http://ordinalmalaprop.com/engine/ - An Engine Fit For My Proceeding, my Aethernet Journal

http://www.flickr.com/groups/slgriefbuild/ - Second Life Griefbuild Digest, pictures of horrible ad griefing and land spam, and the naming of names