aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
authorTalun2013-01-14 18:17:33 +0000
committerJustin Clark-Casey (justincc)2013-01-19 01:18:04 +0000
commit607558fe21ab6c200789a148e419f39730d3c420 (patch)
treedb359a7b16e264b0e1e38a61617115f034606543 /OpenSim/Region
parentMantis 6507 keys returned by llGetAgentList incorrect for llList2Key (diff)
downloadopensim-SC-607558fe21ab6c200789a148e419f39730d3c420.zip
opensim-SC-607558fe21ab6c200789a148e419f39730d3c420.tar.gz
opensim-SC-607558fe21ab6c200789a148e419f39730d3c420.tar.bz2
opensim-SC-607558fe21ab6c200789a148e419f39730d3c420.tar.xz
New constants for llGetObjectDetails
New constants for llGetObjectDetails OBJECT_CHARACTER_TIME, OBJECT_ROOT, OBJECT_ATTACHED_POINT, OBJECT_PATHFINDING_TYPE, OBJECT_PHYSICS, OBJECT_PHANTOM and OBJECT_TEMP_ON_REZ also Pathfining constants, 3 of which are used by llGetObjectDetails
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs75
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs17
2 files changed, 92 insertions, 0 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
index 50597b7..db5add1 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
@@ -10590,6 +10590,35 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
10590 case ScriptBaseClass.OBJECT_PHYSICS_COST: 10590 case ScriptBaseClass.OBJECT_PHYSICS_COST:
10591 ret.Add(new LSL_Float(0)); 10591 ret.Add(new LSL_Float(0));
10592 break; 10592 break;
10593 case ScriptBaseClass.OBJECT_CHARACTER_TIME: // Pathfinding
10594 ret.Add(new LSL_Float(0));
10595 break;
10596 case ScriptBaseClass.OBJECT_ROOT:
10597 SceneObjectPart p = av.ParentPart;
10598 if (p != null)
10599 {
10600 ret.Add(new LSL_String(p.ParentGroup.RootPart.UUID.ToString()));
10601 }
10602 else
10603 {
10604 ret.Add(new LSL_String(id));
10605 }
10606 break;
10607 case ScriptBaseClass.OBJECT_ATTACHED_POINT:
10608 ret.Add(new LSL_Integer(0));
10609 break;
10610 case ScriptBaseClass.OBJECT_PATHFINDING_TYPE: // Pathfinding
10611 ret.Add(new LSL_Integer(ScriptBaseClass.OPT_AVATAR));
10612 break;
10613 case ScriptBaseClass.OBJECT_PHYSICS:
10614 ret.Add(new LSL_Integer(0));
10615 break;
10616 case ScriptBaseClass.OBJECT_PHANTOM:
10617 ret.Add(new LSL_Integer(0));
10618 break;
10619 case ScriptBaseClass.OBJECT_TEMP_ON_REZ:
10620 ret.Add(new LSL_Integer(0));
10621 break;
10593 default: 10622 default:
10594 // Invalid or unhandled constant. 10623 // Invalid or unhandled constant.
10595 ret.Add(new LSL_Integer(ScriptBaseClass.OBJECT_UNKNOWN_DETAIL)); 10624 ret.Add(new LSL_Integer(ScriptBaseClass.OBJECT_UNKNOWN_DETAIL));
@@ -10685,6 +10714,52 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
10685 // The value returned in SL for normal prims looks like the prim count 10714 // The value returned in SL for normal prims looks like the prim count
10686 ret.Add(new LSL_Float(0)); 10715 ret.Add(new LSL_Float(0));
10687 break; 10716 break;
10717 case ScriptBaseClass.OBJECT_CHARACTER_TIME: // Pathfinding
10718 ret.Add(new LSL_Float(0));
10719 break;
10720 case ScriptBaseClass.OBJECT_ROOT:
10721 ret.Add(new LSL_String(obj.ParentGroup.RootPart.UUID.ToString()));
10722 break;
10723 case ScriptBaseClass.OBJECT_ATTACHED_POINT:
10724 ret.Add(new LSL_Integer(obj.ParentGroup.AttachmentPoint));
10725 break;
10726 case ScriptBaseClass.OBJECT_PATHFINDING_TYPE:
10727 byte pcode = obj.Shape.PCode;
10728 if (obj.ParentGroup.AttachmentPoint != 0
10729 || pcode == (byte)PCode.Grass
10730 || pcode == (byte)PCode.Tree
10731 || pcode == (byte)PCode.NewTree)
10732 {
10733 ret.Add(new LSL_Integer(ScriptBaseClass.OPT_OTHER));
10734 }
10735 else
10736 {
10737 ret.Add(new LSL_Integer(ScriptBaseClass.OPT_LEGACY_LINKSET));
10738 }
10739 break;
10740 case ScriptBaseClass.OBJECT_PHYSICS:
10741 if (obj.ParentGroup.AttachmentPoint != 0)
10742 {
10743 ret.Add(new LSL_Integer(0)); // Always false if attached
10744 }
10745 else
10746 {
10747 ret.Add(new LSL_Integer(obj.ParentGroup.UsesPhysics ? 1 : 0));
10748 }
10749 break;
10750 case ScriptBaseClass.OBJECT_PHANTOM:
10751 if (obj.ParentGroup.AttachmentPoint != 0)
10752 {
10753 ret.Add(new LSL_Integer(0)); // Always false if attached
10754 }
10755 else
10756 {
10757 ret.Add(new LSL_Integer(obj.ParentGroup.IsPhantom ? 1 : 0));
10758 }
10759 break;
10760 case ScriptBaseClass.OBJECT_TEMP_ON_REZ:
10761 ret.Add(new LSL_Integer(obj.ParentGroup.IsTemporary ? 1 : 0));
10762 break;
10688 default: 10763 default:
10689 // Invalid or unhandled constant. 10764 // Invalid or unhandled constant.
10690 ret.Add(new LSL_Integer(ScriptBaseClass.OBJECT_UNKNOWN_DETAIL)); 10765 ret.Add(new LSL_Integer(ScriptBaseClass.OBJECT_UNKNOWN_DETAIL));
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs
index 880841b..9bf1a64 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs
@@ -556,6 +556,23 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase
556 public const int OBJECT_SERVER_COST = 14; 556 public const int OBJECT_SERVER_COST = 14;
557 public const int OBJECT_STREAMING_COST = 15; 557 public const int OBJECT_STREAMING_COST = 15;
558 public const int OBJECT_PHYSICS_COST = 16; 558 public const int OBJECT_PHYSICS_COST = 16;
559 public const int OBJECT_CHARACTER_TIME = 17;
560 public const int OBJECT_ROOT = 18;
561 public const int OBJECT_ATTACHED_POINT = 19;
562 public const int OBJECT_PATHFINDING_TYPE = 20;
563 public const int OBJECT_PHYSICS = 21;
564 public const int OBJECT_PHANTOM = 22;
565 public const int OBJECT_TEMP_ON_REZ = 23;
566
567 // Pathfinding types
568 public const int OPT_OTHER = -1;
569 public const int OPT_LEGACY_LINKSET = 0;
570 public const int OPT_AVATAR = 1;
571 public const int OPT_CHARACTER = 2;
572 public const int OPT_WALKABLE = 3;
573 public const int OPT_STATIC_OBSTACLE = 4;
574 public const int OPT_MATERIAL_VOLUME = 5;
575 public const int OPT_EXCLUSION_VOLUME = 6;
559 576
560 // for llGetAgentList 577 // for llGetAgentList
561 public const int AGENT_LIST_PARCEL = 1; 578 public const int AGENT_LIST_PARCEL = 1;