diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index cc36ad1d9f..d90d5ddeca 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs @@ -13772,6 +13772,20 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api AttachmentsPrimList.Add(new LSL_Integer(Attachment.PrimCount)); ret.Add(new LSL_Integer(AttachmentsPrimList.Sum())); break; + case ScriptBaseClass.OBJECT_TOTAL_INVENTORY_COUNT: + LSL_List AttachmentsPrimsInventoryList = new LSL_List(); + foreach (SceneObjectGroup Attachment in av.GetAttachments()) + { + Attachment.ForEachPart(delegate(SceneObjectPart part) + { + AttachmentsPrimsInventoryList.Add(new LSL_Integer(part.Inventory.Count)); + }); + } + ret.Add(new LSL_Integer(AttachmentsPrimsInventoryList.Sum())); + break; + case ScriptBaseClass.OBJECT_GROUP_TAG: + ret.Add(new LSL_String(av.Grouptitle)); + break; default: // Invalid or unhandled constant. ret.Add(new LSL_Integer(ScriptBaseClass.OBJECT_UNKNOWN_DETAIL)); @@ -13953,6 +13967,17 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api case ScriptBaseClass.OBJECT_PRIM_COUNT: ret.Add(new LSL_Integer(obj.ParentGroup.PrimCount)); break; + case ScriptBaseClass.OBJECT_TOTAL_INVENTORY_COUNT: + LSL_List ObjectPrimsInventoryList = new LSL_List(); + obj.ParentGroup.ForEachPart(delegate(SceneObjectPart part) + { + ObjectPrimsInventoryList.Add(new LSL_Integer(part.Inventory.Count)); + }); + ret.Add(ObjectPrimsInventoryList.Sum()); + break; + case ScriptBaseClass.OBJECT_GROUP_TAG: + ret.Add(new LSL_String(String.Empty)); + 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 a177310b1d..17173a2444 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs @@ -639,6 +639,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase public const int OBJECT_CLICK_ACTION = 28; public const int OBJECT_OMEGA = 29; public const int OBJECT_PRIM_COUNT = 30; + public const int OBJECT_TOTAL_INVENTORY_COUNT = 31; + public const int OBJECT_GROUP_TAG = 33; // Pathfinding types public const int OPT_OTHER = -1;