remove a odd raycastv3 config option

melanie
UbitUmarov 2016-12-21 20:39:38 +00:00
parent 7286b27ff9
commit 7367f03d6e
2 changed files with 14 additions and 25 deletions

View File

@ -233,7 +233,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
protected int m_maxHitsPerPrimInCastRay = 16; protected int m_maxHitsPerPrimInCastRay = 16;
protected int m_maxHitsPerObjectInCastRay = 16; protected int m_maxHitsPerObjectInCastRay = 16;
protected bool m_detectExitsInCastRay = false; protected bool m_detectExitsInCastRay = false;
protected bool m_filterPartsInCastRay = false;
protected bool m_doAttachmentsInCastRay = false; protected bool m_doAttachmentsInCastRay = false;
protected int m_msThrottleInCastRay = 200; protected int m_msThrottleInCastRay = 200;
protected int m_msPerRegionInCastRay = 40; protected int m_msPerRegionInCastRay = 40;
@ -391,7 +390,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
m_maxHitsPerPrimInCastRay = lslConfig.GetInt("MaxHitsPerPrimInLlCastRay", m_maxHitsPerPrimInCastRay); m_maxHitsPerPrimInCastRay = lslConfig.GetInt("MaxHitsPerPrimInLlCastRay", m_maxHitsPerPrimInCastRay);
m_maxHitsPerObjectInCastRay = lslConfig.GetInt("MaxHitsPerObjectInLlCastRay", m_maxHitsPerObjectInCastRay); m_maxHitsPerObjectInCastRay = lslConfig.GetInt("MaxHitsPerObjectInLlCastRay", m_maxHitsPerObjectInCastRay);
m_detectExitsInCastRay = lslConfig.GetBoolean("DetectExitHitsInLlCastRay", m_detectExitsInCastRay); m_detectExitsInCastRay = lslConfig.GetBoolean("DetectExitHitsInLlCastRay", m_detectExitsInCastRay);
m_filterPartsInCastRay = lslConfig.GetBoolean("FilterPartsInLlCastRay", m_filterPartsInCastRay);
m_doAttachmentsInCastRay = lslConfig.GetBoolean("DoAttachmentsInLlCastRay", m_doAttachmentsInCastRay); m_doAttachmentsInCastRay = lslConfig.GetBoolean("DoAttachmentsInLlCastRay", m_doAttachmentsInCastRay);
m_msThrottleInCastRay = lslConfig.GetInt("ThrottleTimeInMsInLlCastRay", m_msThrottleInCastRay); m_msThrottleInCastRay = lslConfig.GetInt("ThrottleTimeInMsInLlCastRay", m_msThrottleInCastRay);
m_msPerRegionInCastRay = lslConfig.GetInt("AvailableTimeInMsPerRegionInLlCastRay", m_msPerRegionInCastRay); m_msPerRegionInCastRay = lslConfig.GetInt("AvailableTimeInMsPerRegionInLlCastRay", m_msPerRegionInCastRay);
@ -15063,8 +15061,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
return; return;
if (isPhantom && notdetectPhantom) if (isPhantom && notdetectPhantom)
return; return;
if (m_filterPartsInCastRay)
return;
if (isAttachment && !m_doAttachmentsInCastRay) if (isAttachment && !m_doAttachmentsInCastRay)
return; return;
@ -15072,25 +15068,21 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
// Iterate over all prims/parts in object/group // Iterate over all prims/parts in object/group
foreach(SceneObjectPart part in group.Parts) foreach(SceneObjectPart part in group.Parts)
{ {
// Check part filters if configured // ignore PhysicsShapeType.None as physics engines do
if (m_filterPartsInCastRay) // or we will get into trouble in future
{ if(part.PhysicsShapeType == (byte)PhysicsShapeType.None)
// ignore PhysicsShapeType.None as physics engines do continue;
// or we will get into trouble in future isPhysical = (part.PhysActor != null && part.PhysActor.IsPhysical);
if(part.PhysicsShapeType == (byte)PhysicsShapeType.None) isNonphysical = !isPhysical;
continue; isPhantom = ((part.Flags & PrimFlags.Phantom) != 0) ||
isPhysical = (part.PhysActor != null && part.PhysActor.IsPhysical); (part.VolumeDetectActive);
isNonphysical = !isPhysical;
isPhantom = ((part.Flags & PrimFlags.Phantom) != 0) ||
(part.VolumeDetectActive);
if (isPhysical && rejectPhysical) if (isPhysical && rejectPhysical)
continue; continue;
if (isNonphysical && rejectNonphysical) if (isNonphysical && rejectNonphysical)
continue; continue;
if (isPhantom && notdetectPhantom) if (isPhantom && notdetectPhantom)
continue; continue;
}
// Parse prim/part and project ray if passed filters // Parse prim/part and project ray if passed filters
Vector3 scalePart = part.Scale; Vector3 scalePart = part.Scale;

View File

@ -1635,9 +1635,6 @@
; Report ray intersections with surfaces on exits from a prim as hits in llCastRay V3 if true ; Report ray intersections with surfaces on exits from a prim as hits in llCastRay V3 if true
DetectExitHitsInLlCastRay = false DetectExitHitsInLlCastRay = false
; Filter on parts instead of groups in llCastRay V3 if true
FilterPartsInLlCastRay = false
; Detect attachments in llCastRay V3 if true ; Detect attachments in llCastRay V3 if true
DoAttachmentsInLlCastRay = false DoAttachmentsInLlCastRay = false