aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2011-07-12 22:13:15 +0100
committerJustin Clark-Casey (justincc)2011-07-12 22:13:15 +0100
commit3e456163dd284fa04ab17465041a1a27f7b632b9 (patch)
treebaaa8a470f4afa7637e8919d41e161ec4215ce21 /OpenSim
parenttemporarily fix the build break with building the OdePlugin tests assembly. (diff)
downloadopensim-SC_OLD-3e456163dd284fa04ab17465041a1a27f7b632b9.zip
opensim-SC_OLD-3e456163dd284fa04ab17465041a1a27f7b632b9.tar.gz
opensim-SC_OLD-3e456163dd284fa04ab17465041a1a27f7b632b9.tar.bz2
opensim-SC_OLD-3e456163dd284fa04ab17465041a1a27f7b632b9.tar.xz
Port implementation of llCastRay() from Aurora.
I haven't been able to test this since the viewer won't parse the llCastRay() function. Maybe some activation cap is missing. Could wait until it is activated by default in the viewer.
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Region/Physics/Manager/PhysicsScene.cs24
-rw-r--r--OpenSim/Region/Physics/OdePlugin/ODERayCastRequestManager.cs92
-rw-r--r--OpenSim/Region/Physics/OdePlugin/OdeScene.cs28
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs166
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Interface/ILSL_Api.cs5
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs16
6 files changed, 298 insertions, 33 deletions
diff --git a/OpenSim/Region/Physics/Manager/PhysicsScene.cs b/OpenSim/Region/Physics/Manager/PhysicsScene.cs
index 13ea084..0de4626 100644
--- a/OpenSim/Region/Physics/Manager/PhysicsScene.cs
+++ b/OpenSim/Region/Physics/Manager/PhysicsScene.cs
@@ -37,6 +37,18 @@ namespace OpenSim.Region.Physics.Manager
37 public delegate void physicsCrash(); 37 public delegate void physicsCrash();
38 38
39 public delegate void RaycastCallback(bool hitYN, Vector3 collisionPoint, uint localid, float distance, Vector3 normal); 39 public delegate void RaycastCallback(bool hitYN, Vector3 collisionPoint, uint localid, float distance, Vector3 normal);
40 public delegate void RayCallback(List<ContactResult> list);
41
42 /// <summary>
43 /// Contact result from a raycast.
44 /// </summary>
45 public struct ContactResult
46 {
47 public Vector3 Pos;
48 public float Depth;
49 public uint ConsumerID;
50 public Vector3 Normal;
51 }
40 52
41 public abstract class PhysicsScene 53 public abstract class PhysicsScene
42 { 54 {
@@ -61,7 +73,6 @@ namespace OpenSim.Region.Physics.Manager
61 } 73 }
62 } 74 }
63 75
64
65 public abstract void Initialise(IMesher meshmerizer, IConfigSource config); 76 public abstract void Initialise(IMesher meshmerizer, IConfigSource config);
66 77
67 public abstract PhysicsActor AddAvatar(string avName, Vector3 position, Vector3 size, bool isFlying); 78 public abstract PhysicsActor AddAvatar(string avName, Vector3 position, Vector3 size, bool isFlying);
@@ -225,6 +236,17 @@ namespace OpenSim.Region.Physics.Manager
225 retMethod(false, Vector3.Zero, 0, 999999999999f, Vector3.Zero); 236 retMethod(false, Vector3.Zero, 0, 999999999999f, Vector3.Zero);
226 } 237 }
227 238
239 public virtual void RaycastWorld(Vector3 position, Vector3 direction, float length, int Count, RayCallback retMethod)
240 {
241 if (retMethod != null)
242 retMethod(new List<ContactResult>());
243 }
244
245 public virtual List<ContactResult> RaycastWorld(Vector3 position, Vector3 direction, float length, int Count)
246 {
247 return new List<ContactResult>();
248 }
249
228 private class NullPhysicsScene : PhysicsScene 250 private class NullPhysicsScene : PhysicsScene
229 { 251 {
230 private static int m_workIndicator; 252 private static int m_workIndicator;
diff --git a/OpenSim/Region/Physics/OdePlugin/ODERayCastRequestManager.cs b/OpenSim/Region/Physics/OdePlugin/ODERayCastRequestManager.cs
index ba77dae..6c2bdde 100644
--- a/OpenSim/Region/Physics/OdePlugin/ODERayCastRequestManager.cs
+++ b/OpenSim/Region/Physics/OdePlugin/ODERayCastRequestManager.cs
@@ -45,11 +45,16 @@ namespace OpenSim.Region.Physics.OdePlugin
45 public class ODERayCastRequestManager 45 public class ODERayCastRequestManager
46 { 46 {
47 /// <summary> 47 /// <summary>
48 /// Pending Raycast Requests 48 /// Pending raycast requests
49 /// </summary> 49 /// </summary>
50 protected List<ODERayCastRequest> m_PendingRequests = new List<ODERayCastRequest>(); 50 protected List<ODERayCastRequest> m_PendingRequests = new List<ODERayCastRequest>();
51 51
52 /// <summary> 52 /// <summary>
53 /// Pending ray requests
54 /// </summary>
55 protected List<ODERayRequest> m_PendingRayRequests = new List<ODERayRequest>();
56
57 /// <summary>
53 /// Scene that created this object. 58 /// Scene that created this object.
54 /// </summary> 59 /// </summary>
55 private OdeScene m_scene; 60 private OdeScene m_scene;
@@ -96,6 +101,29 @@ namespace OpenSim.Region.Physics.OdePlugin
96 } 101 }
97 102
98 /// <summary> 103 /// <summary>
104 /// Queues a raycast
105 /// </summary>
106 /// <param name="position">Origin of Ray</param>
107 /// <param name="direction">Ray normal</param>
108 /// <param name="length">Ray length</param>
109 /// <param name="count"></param>
110 /// <param name="retMethod">Return method to send the results</param>
111 public void QueueRequest(Vector3 position, Vector3 direction, float length, int count, RayCallback retMethod)
112 {
113 lock (m_PendingRequests)
114 {
115 ODERayRequest req = new ODERayRequest();
116 req.callbackMethod = retMethod;
117 req.length = length;
118 req.Normal = direction;
119 req.Origin = position;
120 req.Count = count;
121
122 m_PendingRayRequests.Add(req);
123 }
124 }
125
126 /// <summary>
99 /// Process all queued raycast requests 127 /// Process all queued raycast requests
100 /// </summary> 128 /// </summary>
101 /// <returns>Time in MS the raycasts took to process.</returns> 129 /// <returns>Time in MS the raycasts took to process.</returns>
@@ -112,15 +140,23 @@ namespace OpenSim.Region.Physics.OdePlugin
112 if (reqs[i].callbackMethod != null) // quick optimization here, don't raycast 140 if (reqs[i].callbackMethod != null) // quick optimization here, don't raycast
113 RayCast(reqs[i]); // if there isn't anyone to send results 141 RayCast(reqs[i]); // if there isn't anyone to send results
114 } 142 }
115 /* 143
116 foreach (ODERayCastRequest req in m_PendingRequests) 144 m_PendingRequests.Clear();
145 }
146 }
147
148 lock (m_PendingRayRequests)
149 {
150 if (m_PendingRayRequests.Count > 0)
151 {
152 ODERayRequest[] reqs = m_PendingRayRequests.ToArray();
153 for (int i = 0; i < reqs.Length; i++)
117 { 154 {
118 if (req.callbackMethod != null) // quick optimization here, don't raycast 155 if (reqs[i].callbackMethod != null) // quick optimization here, don't raycast
119 RayCast(req); // if there isn't anyone to send results to 156 RayCast(reqs[i]); // if there isn't anyone to send results
120
121 } 157 }
122 */ 158
123 m_PendingRequests.Clear(); 159 m_PendingRayRequests.Clear();
124 } 160 }
125 } 161 }
126 162
@@ -146,7 +182,6 @@ namespace OpenSim.Region.Physics.OdePlugin
146 // Remove Ray 182 // Remove Ray
147 d.GeomDestroy(ray); 183 d.GeomDestroy(ray);
148 184
149
150 // Define default results 185 // Define default results
151 bool hitYN = false; 186 bool hitYN = false;
152 uint hitConsumerID = 0; 187 uint hitConsumerID = 0;
@@ -177,6 +212,31 @@ namespace OpenSim.Region.Physics.OdePlugin
177 req.callbackMethod(hitYN, closestcontact, hitConsumerID, distance, snormal); 212 req.callbackMethod(hitYN, closestcontact, hitConsumerID, distance, snormal);
178 } 213 }
179 214
215 /// <summary>
216 /// Method that actually initiates the raycast
217 /// </summary>
218 /// <param name="req"></param>
219 private void RayCast(ODERayRequest req)
220 {
221 // Create the ray
222 IntPtr ray = d.CreateRay(m_scene.space, req.length);
223 d.GeomRaySet(ray, req.Origin.X, req.Origin.Y, req.Origin.Z, req.Normal.X, req.Normal.Y, req.Normal.Z);
224
225 // Collide test
226 d.SpaceCollide2(m_scene.space, ray, IntPtr.Zero, nearCallback);
227
228 // Remove Ray
229 d.GeomDestroy(ray);
230
231 // Find closest contact and object.
232 lock (m_contactResults)
233 {
234 // Return results
235 if (req.callbackMethod != null)
236 req.callbackMethod(m_contactResults);
237 }
238 }
239
180 // This is the standard Near. Uses space AABBs to speed up detection. 240 // This is the standard Near. Uses space AABBs to speed up detection.
181 private void near(IntPtr space, IntPtr g1, IntPtr g2) 241 private void near(IntPtr space, IntPtr g1, IntPtr g2)
182 { 242 {
@@ -342,10 +402,7 @@ namespace OpenSim.Region.Physics.OdePlugin
342 m_contactResults.Add(collisionresult); 402 m_contactResults.Add(collisionresult);
343 } 403 }
344 } 404 }
345
346
347 } 405 }
348
349 } 406 }
350 407
351 /// <summary> 408 /// <summary>
@@ -365,11 +422,12 @@ namespace OpenSim.Region.Physics.OdePlugin
365 public RaycastCallback callbackMethod; 422 public RaycastCallback callbackMethod;
366 } 423 }
367 424
368 public struct ContactResult 425 public struct ODERayRequest
369 { 426 {
370 public Vector3 Pos; 427 public Vector3 Origin;
371 public float Depth;
372 public uint ConsumerID;
373 public Vector3 Normal; 428 public Vector3 Normal;
429 public int Count;
430 public float length;
431 public RayCallback callbackMethod;
374 } 432 }
375} 433} \ No newline at end of file
diff --git a/OpenSim/Region/Physics/OdePlugin/OdeScene.cs b/OpenSim/Region/Physics/OdePlugin/OdeScene.cs
index 7b8a80c..ba8cba4 100644
--- a/OpenSim/Region/Physics/OdePlugin/OdeScene.cs
+++ b/OpenSim/Region/Physics/OdePlugin/OdeScene.cs
@@ -3736,6 +3736,34 @@ Console.WriteLine("AddPhysicsActorTaint to " + taintedprim.Name);
3736 } 3736 }
3737 } 3737 }
3738 3738
3739 public override void RaycastWorld(Vector3 position, Vector3 direction, float length, int Count, RayCallback retMethod)
3740 {
3741 if (retMethod != null)
3742 {
3743 m_rayCastManager.QueueRequest(position, direction, length, Count, retMethod);
3744 }
3745 }
3746
3747 public override List<ContactResult> RaycastWorld(Vector3 position, Vector3 direction, float length, int Count)
3748 {
3749 ContactResult[] ourResults = null;
3750 RayCallback retMethod = delegate(List<ContactResult> results)
3751 {
3752 ourResults = new ContactResult[results.Count];
3753 results.CopyTo(ourResults, 0);
3754 };
3755 int waitTime = 0;
3756 m_rayCastManager.QueueRequest(position, direction, length, Count, retMethod);
3757 while (ourResults == null && waitTime < 1000)
3758 {
3759 Thread.Sleep(1);
3760 waitTime++;
3761 }
3762 if (ourResults == null)
3763 return new List<ContactResult> ();
3764 return new List<ContactResult>(ourResults);
3765 }
3766
3739#if USE_DRAWSTUFF 3767#if USE_DRAWSTUFF
3740 // Keyboard callback 3768 // Keyboard callback
3741 public void command(int cmd) 3769 public void command(int cmd)
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
index fd6d64c..c8bce60 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
@@ -10309,51 +10309,191 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
10309 return rq.ToString(); 10309 return rq.ToString();
10310 } 10310 }
10311 10311
10312 public LSL_List llCastRay(LSL_Vector start, LSL_Vector end, LSL_List options)
10313 {
10314 m_host.AddScriptLPS(1);
10315
10316 Vector3 dir = new Vector3((float)(end-start).x, (float)(end-start).y, (float)(end-start).z);
10317 Vector3 startvector = new Vector3((float)start.x, (float)start.y, (float)start.z);
10318 Vector3 endvector = new Vector3((float)end.x, (float)end.y, (float)end.z);
10319
10320 int count = 0;
10321// int detectPhantom = 0;
10322 int dataFlags = 0;
10323 int rejectTypes = 0;
10324
10325 for (int i = 0; i < options.Length; i += 2)
10326 {
10327 if (options.GetLSLIntegerItem(i) == ScriptBaseClass.RC_MAX_HITS)
10328 {
10329 count = options.GetLSLIntegerItem(i + 1);
10330 }
10331// else if (options.GetLSLIntegerItem(i) == ScriptBaseClass.RC_DETECT_PHANTOM)
10332// {
10333// detectPhantom = options.GetLSLIntegerItem(i + 1);
10334// }
10335 else if (options.GetLSLIntegerItem(i) == ScriptBaseClass.RC_DATA_FLAGS)
10336 {
10337 dataFlags = options.GetLSLIntegerItem(i + 1);
10338 }
10339 else if (options.GetLSLIntegerItem(i) == ScriptBaseClass.RC_REJECT_TYPES)
10340 {
10341 rejectTypes = options.GetLSLIntegerItem(i + 1);
10342 }
10343 }
10344
10345 LSL_List list = new LSL_List();
10346 List<ContactResult> results = World.PhysicsScene.RaycastWorld(startvector, dir, dir.Length(), count);
10347
10348 double distance = Util.GetDistanceTo(startvector, endvector);
10349
10350 if (distance == 0)
10351 distance = 0.001;
10352
10353 Vector3 posToCheck = startvector;
10354 ITerrainChannel channel = World.RequestModuleInterface<ITerrainChannel>();
10355
10356 bool checkTerrain = !((rejectTypes & ScriptBaseClass.RC_REJECT_LAND) == ScriptBaseClass.RC_REJECT_LAND);
10357 bool checkAgents = !((rejectTypes & ScriptBaseClass.RC_REJECT_AGENTS) == ScriptBaseClass.RC_REJECT_AGENTS);
10358 bool checkNonPhysical = !((rejectTypes & ScriptBaseClass.RC_REJECT_NONPHYSICAL) == ScriptBaseClass.RC_REJECT_NONPHYSICAL);
10359 bool checkPhysical = !((rejectTypes & ScriptBaseClass.RC_REJECT_PHYSICAL) == ScriptBaseClass.RC_REJECT_PHYSICAL);
10360
10361 for (float i = 0; i <= distance; i += 0.1f)
10362 {
10363 posToCheck = startvector + (dir * (i / (float)distance));
10364
10365 if (checkTerrain && channel[(int)(posToCheck.X + startvector.X), (int)(posToCheck.Y + startvector.Y)] < posToCheck.Z)
10366 {
10367 ContactResult result = new ContactResult();
10368 result.ConsumerID = 0;
10369 result.Depth = 0;
10370 result.Normal = Vector3.Zero;
10371 result.Pos = posToCheck;
10372 results.Add(result);
10373 checkTerrain = false;
10374 }
10375
10376 if (checkAgents)
10377 {
10378 World.ForEachScenePresence(delegate(ScenePresence sp)
10379 {
10380 if (sp.AbsolutePosition.ApproxEquals(posToCheck, sp.PhysicsActor.Size.X))
10381 {
10382 ContactResult result = new ContactResult ();
10383 result.ConsumerID = sp.LocalId;
10384 result.Depth = 0;
10385 result.Normal = Vector3.Zero;
10386 result.Pos = posToCheck;
10387 results.Add(result);
10388 }
10389 });
10390 }
10391 }
10392
10393 int refcount = 0;
10394 foreach (ContactResult result in results)
10395 {
10396 if ((rejectTypes & ScriptBaseClass.RC_REJECT_LAND)
10397 == ScriptBaseClass.RC_REJECT_LAND && result.ConsumerID == 0)
10398 continue;
10399
10400 ISceneEntity entity = World.GetSceneObjectPart(result.ConsumerID);
10401
10402 if (entity == null && (rejectTypes & ScriptBaseClass.RC_REJECT_AGENTS) != ScriptBaseClass.RC_REJECT_AGENTS)
10403 entity = World.GetScenePresence(result.ConsumerID); //Only check if we should be looking for agents
10404
10405 if (entity == null)
10406 {
10407 list.Add(UUID.Zero);
10408
10409 if ((dataFlags & ScriptBaseClass.RC_GET_LINK_NUM) == ScriptBaseClass.RC_GET_LINK_NUM)
10410 list.Add(0);
10411
10412 list.Add(result.Pos);
10413
10414 if ((dataFlags & ScriptBaseClass.RC_GET_NORMAL) == ScriptBaseClass.RC_GET_NORMAL)
10415 list.Add(result.Normal);
10416
10417 continue; //Can't find it, so add UUID.Zero
10418 }
10419
10420 /*if (detectPhantom == 0 && intersection.obj is ISceneChildEntity &&
10421 ((ISceneChildEntity)intersection.obj).PhysActor == null)
10422 continue;*/ //Can't do this ATM, physics engine knows only of non phantom objects
10423
10424 if (entity is SceneObjectPart)
10425 {
10426 if (((SceneObjectPart)entity).PhysActor != null && ((SceneObjectPart)entity).PhysActor.IsPhysical)
10427 {
10428 if (!checkPhysical)
10429 continue;
10430 }
10431 else
10432 {
10433 if (!checkNonPhysical)
10434 continue;
10435 }
10436 }
10437
10438 refcount++;
10439 if ((dataFlags & ScriptBaseClass.RC_GET_ROOT_KEY) == ScriptBaseClass.RC_GET_ROOT_KEY && entity is SceneObjectPart)
10440 list.Add(((SceneObjectPart)entity).ParentGroup.UUID);
10441 else
10442 list.Add(entity.UUID);
10443
10444 if ((dataFlags & ScriptBaseClass.RC_GET_LINK_NUM) == ScriptBaseClass.RC_GET_LINK_NUM)
10445 {
10446 if (entity is SceneObjectPart)
10447 list.Add(((SceneObjectPart)entity).LinkNum);
10448 else
10449 list.Add(0);
10450 }
10451
10452 list.Add(result.Pos);
10453
10454 if ((dataFlags & ScriptBaseClass.RC_GET_NORMAL) == ScriptBaseClass.RC_GET_NORMAL)
10455 list.Add(result.Normal);
10456 }
10457
10458 list.Add(refcount); //The status code, either the # of contacts, RCERR_SIM_PERF_LOW, or RCERR_CAST_TIME_EXCEEDED
10459
10460 return list;
10461 }
10462
10312 #region Not Implemented 10463 #region Not Implemented
10313 // 10464 //
10314 // Listing the unimplemented lsl functions here, please move 10465 // Listing the unimplemented lsl functions here, please move
10315 // them from this region as they are completed 10466 // them from this region as they are completed
10316 // 10467 //
10317 public void llCastRay(LSL_Vector start, LSL_Vector end, LSL_List options)
10318 {
10319 m_host.AddScriptLPS(1);
10320 NotImplemented("llCastRay");
10321
10322 }
10323 10468
10324 public void llGetEnv(LSL_String name) 10469 public void llGetEnv(LSL_String name)
10325 { 10470 {
10326 m_host.AddScriptLPS(1); 10471 m_host.AddScriptLPS(1);
10327 NotImplemented("llGetEnv"); 10472 NotImplemented("llGetEnv");
10328
10329 } 10473 }
10330 10474
10331 public void llGetSPMaxMemory() 10475 public void llGetSPMaxMemory()
10332 { 10476 {
10333 m_host.AddScriptLPS(1); 10477 m_host.AddScriptLPS(1);
10334 NotImplemented("llGetSPMaxMemory"); 10478 NotImplemented("llGetSPMaxMemory");
10335
10336 } 10479 }
10337 10480
10338 public void llGetUsedMemory() 10481 public void llGetUsedMemory()
10339 { 10482 {
10340 m_host.AddScriptLPS(1); 10483 m_host.AddScriptLPS(1);
10341 NotImplemented("llGetUsedMemory"); 10484 NotImplemented("llGetUsedMemory");
10342
10343 } 10485 }
10344 10486
10345 public void llRegionSayTo( LSL_Key target, LSL_Integer channel, LSL_String msg ) 10487 public void llRegionSayTo(LSL_Key target, LSL_Integer channel, LSL_String msg)
10346 { 10488 {
10347 m_host.AddScriptLPS(1); 10489 m_host.AddScriptLPS(1);
10348 NotImplemented("llRegionSayTo"); 10490 NotImplemented("llRegionSayTo");
10349
10350 } 10491 }
10351 10492
10352 public void llScriptProfiler( LSL_Integer flags ) 10493 public void llScriptProfiler(LSL_Integer flags)
10353 { 10494 {
10354 m_host.AddScriptLPS(1); 10495 m_host.AddScriptLPS(1);
10355 NotImplemented("llScriptProfiler"); 10496 NotImplemented("llScriptProfiler");
10356
10357 } 10497 }
10358 10498
10359 public void llSetSoundQueueing(int queue) 10499 public void llSetSoundQueueing(int queue)
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Interface/ILSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Interface/ILSL_Api.cs
index 654ea81..27f9c84 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Interface/ILSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Interface/ILSL_Api.cs
@@ -60,6 +60,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api.Interfaces
60 LSL_String llBase64ToString(string str); 60 LSL_String llBase64ToString(string str);
61 void llBreakAllLinks(); 61 void llBreakAllLinks();
62 void llBreakLink(int linknum); 62 void llBreakLink(int linknum);
63 LSL_List llCastRay(LSL_Vector start, LSL_Vector end, LSL_List options);
63 LSL_Integer llCeil(double f); 64 LSL_Integer llCeil(double f);
64 void llClearCameraParams(); 65 void llClearCameraParams();
65 LSL_Integer llClearPrimMedia(LSL_Integer face); 66 LSL_Integer llClearPrimMedia(LSL_Integer face);
@@ -404,7 +405,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api.Interfaces
404 LSL_String llXorBase64StringsCorrect(string str1, string str2); 405 LSL_String llXorBase64StringsCorrect(string str1, string str2);
405 void print(string str); 406 void print(string str);
406 407
407 void SetPrimitiveParamsEx(LSL_Key prim, LSL_List rules); 408 void SetPrimitiveParamsEx(LSL_Key prim, LSL_List rules);
408 LSL_List GetLinkPrimitiveParamsEx(LSL_Key prim, LSL_List rules); 409 LSL_List GetLinkPrimitiveParamsEx(LSL_Key prim, LSL_List rules);
409 } 410 }
410} 411}
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs
index 9377cda..3f90788 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs
@@ -593,5 +593,21 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase
593 593
594 public const string URL_REQUEST_GRANTED = "URL_REQUEST_GRANTED"; 594 public const string URL_REQUEST_GRANTED = "URL_REQUEST_GRANTED";
595 public const string URL_REQUEST_DENIED = "URL_REQUEST_DENIED"; 595 public const string URL_REQUEST_DENIED = "URL_REQUEST_DENIED";
596
597 public static readonly LSLInteger RC_REJECT_TYPES = 2;
598 public static readonly LSLInteger RC_DATA_FLAGS = 4;
599 public static readonly LSLInteger RC_MAX_HITS = 8;
600 public static readonly LSLInteger RC_DETECT_PHANTOM = 16;
601
602 public static readonly LSLInteger RC_REJECT_AGENTS = 2;
603 public static readonly LSLInteger RC_REJECT_PHYSICAL = 4;
604 public static readonly LSLInteger RC_REJECT_NONPHYSICAL = 8;
605 public static readonly LSLInteger RC_REJECT_LAND = 16;
606
607 public static readonly LSLInteger RC_GET_NORMAL = 2;
608 public static readonly LSLInteger RC_GET_ROOT_KEY = 4;
609 public static readonly LSLInteger RC_GET_LINK_NUM = 8;
610
611 public static readonly LSLInteger RCERR_CAST_TIME_EXCEEDED = 1;
596 } 612 }
597} 613}