Xander Lopez Posted May 3, 2020 Share Posted May 3, 2020 So i can see from wiki that llCastRay will accept four filters RC_REJECT_AGENTS RC_REJECT_PHYSICAL RC_REJECT_NONPHYSICAL RC_REJECT_LAND What I am trying to achieve is a bit complicated. I am trying to create a weapon that can detect Avatar, AND ALSO certain type of prims. This special prims might have some special script inside, or maybe created by certain avatar, or maybe has some other indicator that says the prim is eligible for llCastRay to recognize. Is there any way to do this? If the ray hits any normal prims that are not eligible, i want it to just continue on until it hits any avatar or any valid prims. It seems very complicated to come up with this kind of rule. Any suggestions? Link to comment Share on other sites More sharing options...
Wulfie Reanimator Posted May 3, 2020 Share Posted May 3, 2020 The short and simple answer is "you can't." That said, there are a couple ways to do it. You either increase the value of RC_MAX_HITS and check each hit separately, or you keep it at 1 and create new rays for every hit that isn't eligible, either from where the previous ray ended or with some additional offset. Link to comment Share on other sites More sharing options...
Tactical UwU Posted May 3, 2020 Share Posted May 3, 2020 (edited) It's possible. You would have to use RC_REJECT_LAND, a higher RC_MAX_HITS, and either RC_REJECT_NONPHYSICAL or RC_REJECT_PHYSICAL depending on if these special objects are physical (movable via collision) or not. Each hit would require you to run llGetObjectDetails to find the specific parameters of the object you're looking for. Though, you cannot view the items inside 1 object with an object it isn't linked to - You can get how many total but not what they are or their names. So you won't be able to see whatever script it is you're looking for, so you will have to find some other way to store the required information. Edited May 3, 2020 by Secondary Lionheart Link to comment Share on other sites More sharing options...
Lindens Rider Linden Posted May 4, 2020 Lindens Share Posted May 4, 2020 19 hours ago, Secondary Lionheart said: Though, you cannot view the items inside 1 object with an object it isn't linked to - You can get how many total but not what they are or their names. So you won't be able to see whatever script it is you're looking for, so you will have to find some other way to store the required information. He could send the object in question a message on a predetermined channel (llRegionSayTo) and add a script to your discovered object that would respond with a "yes, I'm your object". If you don't get the response back you know it isn't one of yours. Link to comment Share on other sites More sharing options...
Lucia Nightfire Posted May 4, 2020 Share Posted May 4, 2020 2 hours ago, Rider Linden said: He could send the object in question a message on a predetermined channel (llRegionSayTo) and add a script to your discovered object that would respond with a "yes, I'm your object". If you don't get the response back you know it isn't one of yours. I don't think he's looking to prep all objects with such overhead. Link to comment Share on other sites More sharing options...
Recommended Posts
Please take a moment to consider if this thread is worth bumping.
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now