From af3f2717fd1b92a0f5f6003a8ce03939b8c57b47 Mon Sep 17 00:00:00 2001
From: Mandarinka Tasty
Date: Sun, 27 Nov 2016 22:50:11 +0100
Subject: The implementation of new flags = paramters for llGetObjectDetails -
 Part I Constant: integer OBJECT_CLICK_ACTION = 28; Constant: integer
 OBJECT_OMEGA = 29; Constant: integer OBJECT_PRIM_COUNT = 30;

Signed-off-by: Mandarinka Tasty <mandarinka.tasty@gmail.com>
Signed-off-by: UbitUmarov <ajlduarte@sapo.pt>
---
 .../Shared/Api/Implementation/LSL_Api.cs           | 23 ++++++++++++++++++++++
 .../Shared/Api/Runtime/LSL_Constants.cs            |  3 +++
 2 files changed, 26 insertions(+)

(limited to 'OpenSim/Region/ScriptEngine')

diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
index 849d02d..cc36ad1 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
@@ -13758,6 +13758,20 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
                             case ScriptBaseClass.OBJECT_LAST_OWNER_ID:
                                 ret.Add(new LSL_Key(ScriptBaseClass.NULL_KEY));
                                 break;
+                            case ScriptBaseClass.OBJECT_CLICK_ACTION:
+                                ret.Add(new LSL_Integer(0));
+                                break;
+                            case ScriptBaseClass.OBJECT_OMEGA:
+                                ret.Add(new LSL_Vector(Vector3.Zero));
+                                break;
+                            case ScriptBaseClass.OBJECT_PRIM_COUNT:
+                                LSL_List AttachmentsPrimList = new LSL_List();
+                                List<SceneObjectGroup> Attachments;
+                                Attachments = av.GetAttachments();
+                                foreach (SceneObjectGroup Attachment in Attachments)
+                                    AttachmentsPrimList.Add(new LSL_Integer(Attachment.PrimCount));
+                                ret.Add(new LSL_Integer(AttachmentsPrimList.Sum()));
+                                break;
                             default:
                                 // Invalid or unhandled constant.
                                 ret.Add(new LSL_Integer(ScriptBaseClass.OBJECT_UNKNOWN_DETAIL));
@@ -13930,6 +13944,15 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
                             case ScriptBaseClass.OBJECT_LAST_OWNER_ID:
                                 ret.Add(new LSL_Key(obj.ParentGroup.LastOwnerID.ToString()));
                                 break;
+                            case ScriptBaseClass.OBJECT_CLICK_ACTION:
+                                ret.Add(new LSL_Integer(obj.ClickAction));
+                                break;
+                            case ScriptBaseClass.OBJECT_OMEGA:
+                                ret.Add(new LSL_Vector(obj.AngularVelocity));
+                                break;
+                            case ScriptBaseClass.OBJECT_PRIM_COUNT:
+                                ret.Add(new LSL_Integer(obj.ParentGroup.PrimCount));
+                                break;
                             default:
                                 // Invalid or unhandled constant.
                                 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 cee66b2..a177310 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs
@@ -636,6 +636,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase
         public const int OBJECT_HOVER_HEIGHT = 25;
         public const int OBJECT_BODY_SHAPE_TYPE = 26;
         public const int OBJECT_LAST_OWNER_ID = 27;
+        public const int OBJECT_CLICK_ACTION = 28;
+        public const int OBJECT_OMEGA = 29;
+        public const int OBJECT_PRIM_COUNT = 30;
 
         // Pathfinding types
         public const int OPT_OTHER = -1;
-- 
cgit v1.1