29 using System.Collections.Generic;
32 using System.Reflection;
34 using System.Threading;
36 using OpenSim.Framework;
37 using OpenSim.Framework.Capabilities;
38 using OpenSim.Framework.Client;
39 using OpenSim.Region.Framework.Interfaces;
40 using OpenSim.Region.Framework.Scenes;
41 using OpenSim.Region.Framework.Scenes.Serialization;
42 using OpenSim.Services.Interfaces;
52 namespace OpenSim.
Region.CoreModules.Framework.InventoryAccess
54 [Extension(Path =
"/OpenSim/RegionModules", NodeName =
"RegionModule", Id =
"BasicInventoryAccessModule")]
57 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
59 protected bool m_Enabled =
false;
66 if (m_UserManagement == null)
68 return m_UserManagement;
72 public bool CoalesceMultipleObjectsToInventory {
get; set; }
74 #region INonSharedRegionModule
76 public Type ReplaceableInterface
81 public virtual string Name
83 get {
return "BasicInventoryAccessModule"; }
88 IConfig moduleConfig = source.Configs[
"Modules"];
89 if (moduleConfig != null)
91 string name = moduleConfig.GetString(
"InventoryAccessModule",
"");
96 InitialiseCommon(source);
98 m_log.InfoFormat(
"[INVENTORY ACCESS MODULE]: {0} enabled.", Name);
109 IConfig inventoryConfig = source.Configs[
"Inventory"];
111 if (inventoryConfig != null)
112 CoalesceMultipleObjectsToInventory
113 = inventoryConfig.GetBoolean(
"CoalesceMultipleObjectsToInventory",
true);
115 CoalesceMultipleObjectsToInventory =
true;
130 scene.EventManager.OnNewClient += OnNewClient;
160 #region Inventory Access
177 uint callbackID,
string description,
string name, sbyte invType,
179 byte wearableType, uint nextOwnerMask,
int creationDate)
181 m_log.DebugFormat(
"[INVENTORY ACCESS MODULE]: Received request to create inventory item {0} in folder {1}, transactionID {2}", name,
182 folderID, transactionID);
184 if (!m_Scene.Permissions.CanCreateUserInventory(invType, remoteClient.
AgentId))
190 if (folder == null || folder.
Owner != remoteClient.
AgentId)
193 if (transactionID !=
UUID.Zero)
196 if (agentTransactions != null)
199 remoteClient, transactionID, folderID, callbackID, description,
200 name, invType, assetType, wearableType, nextOwnerMask))
206 if (m_Scene.TryGetScenePresence(remoteClient.
AgentId, out presence))
210 if (invType == (sbyte)InventoryType.Landmark && presence != null)
212 string suffix = string.Empty, prefix = string.Empty;
213 string strdata = GenerateLandmark(presence, out prefix, out suffix);
214 data = Encoding.ASCII.GetBytes(strdata);
215 name = prefix + name;
216 description += suffix;
219 AssetBase asset = m_Scene.CreateAsset(name, description, assetType, data, remoteClient.AgentId);
220 m_Scene.AssetService.Store(asset);
221 m_Scene.CreateNewInventoryItem(
222 remoteClient, remoteClient.AgentId.ToString(),
string.Empty, folderID,
223 name, description, 0, callbackID, asset.
FullID, asset.
Type, invType, nextOwnerMask, creationDate);
228 "[INVENTORY ACCESS MODULE]: ScenePresence for agent uuid {0} unexpectedly not found in CreateNewInventoryItem",
229 remoteClient.AgentId);
235 prefix = string.Empty;
236 suffix = string.Empty;
237 Vector3 pos = presence.AbsolutePosition;
238 return String.Format(
"Landmark version 2\nregion_id {0}\nlocal_pos {1} {2} {3}\nregion_handle {4}\n",
239 presence.Scene.RegionInfo.RegionID,
241 presence.RegionHandle);
254 item = m_Scene.InventoryService.GetItem(item);
261 if ((InventoryType)item.InvType == InventoryType.Notecard)
263 if (!m_Scene.Permissions.CanEditNotecard(itemID,
UUID.Zero, remoteClient.
AgentId))
265 remoteClient.SendAgentAlertMessage(
"Insufficient permissions to edit notecard",
false);
269 remoteClient.SendAlertMessage(
"Notecard saved");
271 else if ((InventoryType)item.InvType == InventoryType.LSL)
273 if (!m_Scene.Permissions.CanEditScript(itemID,
UUID.Zero, remoteClient.
AgentId))
275 remoteClient.SendAgentAlertMessage(
"Insufficient permissions to edit script",
false);
279 remoteClient.SendAlertMessage(
"Script saved");
285 int perms = m_Scene.InventoryService.GetAssetPermissions(remoteClient.
AgentId, x);
287 if ((perms & required) != required)
292 data = animSet.ToBytes();
298 item.AssetID = asset.FullID;
299 m_Scene.AssetService.Store(asset);
301 m_Scene.InventoryService.UpdateItem(item);
309 "[INVENTORY ACCESS MODULE]: Could not find item {0} for caps inventory update",
318 if (item != null && item.
Owner == ownerID && asset != null)
324 item.AssetID = asset.FullID;
325 item.Description = asset.Description;
326 item.Name = asset.Name;
327 item.AssetType = asset.Type;
328 item.InvType = (int)InventoryType.Object;
330 m_Scene.AssetService.Store(asset);
331 m_Scene.InventoryService.UpdateItem(item);
337 m_log.ErrorFormat(
"[INVENTORY ACCESS MODULE]: Given invalid item for inventory update: {0}",
338 (item == null || asset == null?
"null item or asset" :
"wrong owner"));
345 List<SceneObjectGroup> objectGroups,
IClientAPI remoteClient,
bool asAttachment)
347 List<InventoryItemBase> copiedItems =
new List<InventoryItemBase>();
349 Dictionary<UUID, List<SceneObjectGroup>> bundlesToCopy =
new Dictionary<UUID, List<SceneObjectGroup>>();
351 if (CoalesceMultipleObjectsToInventory)
358 if (!bundlesToCopy.ContainsKey(g.
OwnerID))
359 bundlesToCopy[g.
OwnerID] =
new List<SceneObjectGroup>();
361 bundlesToCopy[g.OwnerID].Add(g);
369 List<SceneObjectGroup> bundle =
new List<SceneObjectGroup>();
371 bundlesToCopy[g.UUID] = bundle;
381 foreach (List<SceneObjectGroup> bundle
in bundlesToCopy.Values)
382 copiedItems.Add(CopyBundleToInventory(action, folderID, bundle, remoteClient, asAttachment));
403 Dictionary<UUID, Vector3> originalPositions =
new Dictionary<UUID, Vector3>();
404 Dictionary<UUID, Quaternion> originalRotations =
new Dictionary<UUID, Quaternion>();
406 Dictionary<UUID, KeyframeMotion> originalKeyframes =
new Dictionary<UUID, KeyframeMotion>();
412 objectGroup.RootPart.KeyframeMotion.Suspend();
414 objectGroup.RootPart.SetForce(Vector3.Zero);
415 objectGroup.RootPart.SetAngularImpulse(Vector3.Zero,
false);
417 originalKeyframes[objectGroup.UUID] = objectGroup.RootPart.KeyframeMotion;
418 objectGroup.RootPart.KeyframeMotion = null;
420 Vector3 inventoryStoredPosition = objectGroup.AbsolutePosition;
421 originalPositions[objectGroup.UUID] = inventoryStoredPosition;
422 Quaternion inventoryStoredRotation = objectGroup.GroupRotation;
423 originalRotations[objectGroup.UUID] = inventoryStoredRotation;
428 inventoryStoredPosition = objectGroup.RootPart.AttachedPos;
429 inventoryStoredRotation = objectGroup.RootPart.AttachRotation;
435 objectGroup.RootPart.Shape.PCode != (byte) PCode.NewTree)
437 objectGroup.RootPart.Shape.State = objectGroup.RootPart.AttachPoint;
439 objectGroup.RootPart.Shape.LastAttachPoint = objectGroup.RootPart.AttachPoint;
442 objectGroup.AbsolutePosition = inventoryStoredPosition;
443 objectGroup.RootPart.RotationOffset = inventoryStoredRotation;
449 objectGroup.RootPart.NextOwnerMask &=
451 (uint)PermissionMask.Transfer |
453 (uint)PermissionMask.Export);
454 objectGroup.RootPart.NextOwnerMask |=
457 coa.Add(objectGroup);
466 if (objlist.Count > 1)
467 itemXml = CoalescedSceneObjectsSerializer.ToXml(coa, !asAttachment);
469 itemXml = SceneObjectSerializer.ToOriginalXmlFormat(objlist[0], !asAttachment);
474 objectGroup.AbsolutePosition = originalPositions[objectGroup.UUID];
475 objectGroup.RootPart.RotationOffset = originalRotations[objectGroup.UUID];
476 objectGroup.RootPart.KeyframeMotion = originalKeyframes[objectGroup.UUID];
478 objectGroup.RootPart.KeyframeMotion.Resume();
481 InventoryItemBase item = CreateItemForObject(action, remoteClient, objlist[0], folderID);
490 item.CreatorId = objlist[0].RootPart.CreatorID.ToString();
491 item.CreatorData = objlist[0].RootPart.CreatorData;
493 if (objlist.Count > 1)
495 item.Flags = (uint)InventoryItemFlags.ObjectHasMultipleItems;
503 item.CreatorId = UUID.Zero.ToString();
504 item.CreatorData = string.Empty;
511 item.SaleType = objlist[0].RootPart.ObjectSaleType;
512 item.SalePrice = objlist[0].RootPart.SalePrice;
516 objlist[0].GetPartName(objlist[0].RootPart.LocalId),
517 objlist[0].GetPartDescription(objlist[0].RootPart.LocalId),
518 (sbyte)AssetType.Object,
519 Utils.StringToBytes(itemXml),
520 objlist[0].OwnerID.ToString());
521 m_Scene.AssetService.Store(asset);
523 item.AssetID = asset.FullID;
525 if (
DeRezAction.SaveToExistingUserInventoryItem == action)
527 m_Scene.InventoryService.UpdateItem(item);
531 item.CreationDate = Util.UnixTimeSinceEpoch();
532 item.Description = asset.Description;
533 item.Name = asset.Name;
534 item.AssetType = asset.Type;
538 AddPermissions(item, objlist[0], objlist, null);
540 AddPermissions(item, objlist[0], objlist, remoteClient);
542 m_Scene.AddInventoryItem(item);
544 if (remoteClient != null && item.
Owner == remoteClient.AgentId)
546 remoteClient.SendInventoryItemCreateUpdate(item, 0);
550 ScenePresence notifyUser = m_Scene.GetScenePresence(item.Owner);
551 if (notifyUser != null)
553 notifyUser.ControllingClient.SendInventoryItemCreateUpdate(item, 0);
559 if (remoteClient != null)
560 ExportAsset(remoteClient.AgentId, asset.
FullID);
583 uint allObjectsNextOwnerPerms = 0x7fffffff;
590 uint groupPerms = grp.GetEffectivePermissions(
true);
594 effectivePerms &= groupPerms;
600 if (remoteClient != null && (remoteClient.AgentId != so.RootPart.OwnerID) && m_Scene.Permissions.PropagatePermissions())
605 uint perms = effectivePerms;
606 PermissionsUtil.ApplyFoldedPermissions(effectivePerms, ref perms);
608 item.BasePermissions = perms & so.RootPart.NextOwnerMask;
609 item.CurrentPermissions = item.BasePermissions;
610 item.NextPermissions = perms & so.RootPart.NextOwnerMask;
611 item.EveryOnePermissions = so.RootPart.EveryoneMask & so.RootPart.NextOwnerMask;
612 item.GroupPermissions = so.RootPart.GroupMask & so.RootPart.NextOwnerMask;
615 item.CurrentPermissions |= SceneObjectGroup.SLAM;
624 PermissionsUtil.ApplyFoldedPermissions(effectivePerms, ref allObjectsNextOwnerPerms);
626 item.BasePermissions = effectivePerms;
627 item.CurrentPermissions = effectivePerms;
628 item.NextPermissions = so.RootPart.NextOwnerMask & effectivePerms;
629 item.EveryOnePermissions = so.RootPart.EveryoneMask & effectivePerms;
630 item.GroupPermissions = so.RootPart.GroupMask & effectivePerms;
632 item.CurrentPermissions &=
634 (uint)PermissionMask.Transfer |
636 (uint)PermissionMask.Move |
663 UUID userID = UUID.Zero;
666 action ==
DeRezAction.SaveToExistingUserInventoryItem)
671 if (remoteClient == null)
674 userID = remoteClient.AgentId;
683 userID = so.RootPart.LastOwnerID;
689 userID = so.RootPart.OwnerID;
696 if (userID ==
UUID.Zero)
710 if (
DeRezAction.SaveToExistingUserInventoryItem == action)
713 item = m_Scene.InventoryService.GetItem(item);
721 "[INVENTORY ACCESS MODULE]: Object {0} {1} scheduled for save to inventory has already been deleted.",
735 if (remoteClient == null ||
738 folder = m_Scene.InventoryService.GetFolderForType(userID, FolderType.LostAndFound);
742 folder = m_Scene.InventoryService.GetFolderForType(userID, FolderType.Trash);
749 folder = m_Scene.InventoryService.GetFolderForType(userID, FolderType.LostAndFound);
752 if (folderID ==
UUID.Zero && folder == null)
758 folder = m_Scene.InventoryService.GetFolderForType(userID, FolderType.Trash);
766 folder = m_Scene.InventoryService.GetFolderForType(userID, FolderType.Object);
767 so.FromFolderID = UUID.Zero;
773 folder = m_Scene.InventoryService.GetFolderForType(userID, FolderType.LostAndFound);
787 folder = m_Scene.InventoryService.GetFolder(f);
789 if(folder.
Type == 14 || folder.
Type == 16)
792 folder = m_Scene.InventoryService.GetFolderForType(userID, FolderType.Object);
808 item.ID = UUID.Random();
809 item.InvType = (int)InventoryType.Object;
818 IClientAPI remoteClient, UUID itemID, Vector3 RayEnd, Vector3 RayStart,
819 UUID RayTargetID, byte BypassRayCast,
bool RayEndIsIntersection,
820 bool RezSelected,
bool RemoveItem, UUID fromTaskID,
bool attachment)
824 item = m_Scene.InventoryService.GetItem(item);
831 item.Owner = remoteClient.AgentId;
834 remoteClient, item, item.
AssetID,
835 RayEnd, RayStart, RayTargetID, BypassRayCast, RayEndIsIntersection,
836 RezSelected, RemoveItem, fromTaskID, attachment);
841 UUID RayTargetID, byte BypassRayCast,
bool RayEndIsIntersection,
842 bool RezSelected,
bool RemoveItem, UUID fromTaskID,
bool attachment)
844 AssetBase rezAsset = m_Scene.AssetService.Get(assetID.ToString());
846 if (rezAsset == null)
851 "[InventoryAccessModule]: Could not find asset {0} for item {1} {2} for {3} in RezObject()",
852 assetID, item.Name, item.ID, remoteClient.Name);
853 remoteClient.SendAgentAlertMessage(string.Format(
"Unable to rez: could not find asset {0} for item {1}.", assetID, item.Name),
false);
858 "[INVENTORY ACCESS MODULE]: Could not find asset {0} for {1} in RezObject()",
859 assetID, remoteClient.Name);
860 remoteClient.SendAgentAlertMessage(string.Format(
"Unable to rez: could not find asset {0}.", assetID),
false);
868 List<SceneObjectGroup> objlist;
869 List<Vector3> veclist;
872 byte bRayEndIsIntersection = (byte)(RayEndIsIntersection ? 1 : 0);
876 = m_Scene.GetObjectsToRez(
877 rezAsset.Data, attachment, out objlist, out veclist, out bbox, out offsetHeight);
881 pos = m_Scene.GetNewRezLocation(
882 RayStart, RayEnd, RayTargetID, Quaternion.Identity,
883 BypassRayCast, bRayEndIsIntersection,
true, bbox,
false);
884 pos.Z += offsetHeight;
888 pos = m_Scene.GetNewRezLocation(RayStart, RayEnd,
889 RayTargetID, Quaternion.Identity,
890 BypassRayCast, bRayEndIsIntersection,
true,
897 primcount += g.PrimCount;
899 if (!m_Scene.Permissions.CanRezObject(
900 primcount, remoteClient.AgentId, pos)
910 if (((item.CurrentPermissions & (uint)
PermissionMask.Copy) == 0) && (!attachment))
911 remoteClient.SendBulkUpdateInventory(item);
917 if (item != null && !DoPreRezWhenFromItem(remoteClient, item, objlist, pos, veclist, attachment))
920 for (
int i = 0; i < objlist.Count; i++)
932 if (group.UUID ==
UUID.Zero)
934 m_log.Debug(
"[INVENTORY ACCESS MODULE]: Object has UUID.Zero! Position 3");
939 if (group.IsAttachment ==
false && group.RootPart.Shape.State != 0)
941 group.RootPart.AttachedPos = group.AbsolutePosition;
942 group.RootPart.Shape.LastAttachPoint = (byte)group.AttachmentPoint;
951 part.LastOwnerID = part.OwnerID;
952 part.OwnerID = remoteClient.AgentId;
965 part.CreateSelected =
true;
969 group.ClearPartAttachmentData();
973 group.IsAttachment =
true;
982 m_Scene.AddNewSceneObject(group,
true,
false);
985 group.AbsolutePosition = pos + veclist[i];
987 group.SetGroup(remoteClient.ActiveGroupId, remoteClient);
992 group.CreateScriptInstances(0,
true, m_Scene.DefaultScriptEngine, 1);
993 rootPart.ParentGroup.ResumeScripts();
995 group.ScheduleGroupForFullUpdate();
1008 DoPostRezWhenFromItem(item, attachment);
1026 private bool DoPreRezWhenFromItem(
1028 Vector3 pos, List<Vector3> veclist,
bool isAttachment)
1030 UUID fromUserInventoryItemId = UUID.Zero;
1034 if (!m_Scene.Permissions.BypassPermissions())
1037 == (uint)
PermissionMask.Copy && (item.
Flags & (uint)InventoryItemFlags.ObjectHasMultipleItems) == 0)
1039 fromUserInventoryItemId = item.ID;
1044 if ((item.
Flags & (uint)InventoryItemFlags.ObjectHasMultipleItems) == 0)
1047 fromUserInventoryItemId = item.ID;
1051 for (
int i = 0; i < objlist.Count; i++)
1055 if (!m_Scene.Permissions.CanRezObject(
1065 remoteClient.SendBulkUpdateInventory(item);
1067 ILandObject land = m_Scene.LandChannel.GetLandObject(pos.X, pos.Y);
1068 remoteClient.SendAlertMessage(string.Format(
1069 "Can't rez object '{0}' at <{1:F3}, {2:F3}, {3:F3}> on parcel '{4}' in region {5}.",
1070 item.Name, pos.X, pos.Y, pos.Z, land != null ? land.LandData.Name :
"Unknown", m_Scene.Name));
1076 for (
int i = 0; i < objlist.Count; i++)
1089 if (objlist.Count == 1)
1091 rootPart.Name = item.Name;
1092 rootPart.Description = item.Description;
1095 if ((item.
Flags & (uint)InventoryItemFlags.ObjectSlamSale) != 0)
1097 rootPart.ObjectSaleType = item.SaleType;
1098 rootPart.SalePrice = item.SalePrice;
1101 so.FromFolderID = item.Folder;
1109 (item.
Flags & (uint)InventoryItemFlags.ObjectSlamPerm) != 0)
1112 rootPart.ObjectSaleType = 0;
1113 rootPart.SalePrice = 10;
1115 if (m_Scene.Permissions.PropagatePermissions())
1121 part.LastOwnerID = part.OwnerID;
1122 part.OwnerID = item.Owner;
1123 part.Inventory.ChangeInventoryOwner(item.Owner);
1126 so.ApplyNextOwnerPermissions();
1133 if ((item.
Flags & (uint)InventoryItemFlags.ObjectHasMultipleItems) == 0)
1135 if ((item.
Flags & (uint)InventoryItemFlags.ObjectOverwriteEveryone) != 0)
1136 part.EveryoneMask = item.EveryOnePermissions & part.BaseMask;
1137 if ((item.
Flags & (uint)InventoryItemFlags.ObjectOverwriteNextOwner) != 0)
1138 part.NextOwnerMask = item.NextPermissions & part.BaseMask;
1147 part.FromUserInventoryItemID = fromUserInventoryItemId;
1149 if ((item.
Flags & (uint)InventoryItemFlags.ObjectOverwriteEveryone) != 0)
1150 part.EveryoneMask = item.EveryOnePermissions;
1151 if ((item.
Flags & (uint)InventoryItemFlags.ObjectOverwriteNextOwner) != 0)
1152 part.NextOwnerMask = item.NextPermissions;
1153 if ((item.
Flags & (uint)InventoryItemFlags.ObjectOverwriteGroup) != 0)
1154 part.GroupMask = item.GroupPermissions;
1158 rootPart.TrimPermissions();
1161 so.FromItemID = item.ID;
1174 if (!m_Scene.Permissions.BypassPermissions())
1183 List<UUID> uuids =
new List<UUID>();
1185 m_Scene.InventoryService.DeleteItems(item.Owner, uuids);
1193 UserManagementModule.AddUser(sog.RootPart.CreatorID, sog.RootPart.CreatorData);
1195 UserManagementModule.AddUser(sop.CreatorID, sop.CreatorData);
1206 if (assetRequestItem == null)
1211 assetRequestItem = lib.LibraryRootFolder.FindItem(itemID);
1213 if (assetRequestItem == null)
1221 if (assetRequestItem.
AssetType == (
int)AssetType.LSLText)
1223 if (!m_Scene.Permissions.CanViewScript(itemID,
UUID.Zero, remoteClient.
AgentId))
1225 remoteClient.SendAgentAlertMessage(
"Insufficient permissions to view script",
false);
1229 else if (assetRequestItem.
AssetType == (
int)AssetType.Notecard)
1231 if (!m_Scene.Permissions.CanViewNotecard(itemID,
UUID.Zero, remoteClient.
AgentId))
1233 remoteClient.SendAgentAlertMessage(
"Insufficient permissions to view notecard",
false);
1238 if (assetRequestItem.
AssetID != requestID)
1241 "[INVENTORY ACCESS MODULE]: {0} requested asset {1} from item {2} but this does not match item's asset {3}",
1242 Name, requestID, itemID, assetRequestItem.AssetID);
1253 assetServerURL = string.Empty;
1270 private AssetBase CreateAsset(
string name,
string description, sbyte assetType, byte[] data,
string creatorID)
1273 asset.Description = description;
1274 asset.Data = (data == null) ?
new byte[1] : data;
1283 item = invService.GetItem(item);
1285 if (item != null && item.CreatorData != null && item.CreatorData !=
string.Empty)
1286 UserManagementModule.AddUser(item.CreatorIdAsUuid, item.CreatorData);
InventoryItemBase CreateItemForObject(DeRezAction action, IClientAPI remoteClient, SceneObjectGroup so, UUID folderID)
Create an item using details for the given scene object.
virtual InventoryItemBase GetItem(UUID agentID, UUID itemID)
virtual void OnNewClient(IClientAPI client)
OpenSim.Server.Handlers.Simulation.Utils Utils
virtual string GenerateLandmark(ScenePresence presence, out string prefix, out string suffix)
delegate void RezObject(IClientAPI remoteClient, UUID itemID, Vector3 RayEnd, Vector3 RayStart, UUID RayTargetID, byte BypassRayCast, bool RayEndIsIntersection, bool RezSelected, bool RemoveItem, UUID fromTaskID)
UUID FromFolderID
The folder ID that this object was rezzed from, if applicable.
A scene object group is conceptually an object in the scene. The object is constituted of SceneObject...
virtual bool IsForeignUser(UUID userID, out string assetServerURL)
sbyte Type
(sbyte) AssetType enum
virtual void Close()
This is the inverse to Initialise. After a Close(), this instance won't be usable anymore...
virtual SceneObjectGroup RezObject(IClientAPI remoteClient, InventoryItemBase item, UUID assetID, Vector3 RayEnd, Vector3 RayStart, UUID RayTargetID, byte BypassRayCast, bool RayEndIsIntersection, bool RezSelected, bool RemoveItem, UUID fromTaskID, bool attachment)
Rez an object into the scene from the user's inventory
virtual void RegionLoaded(Scene scene)
This will be called once for every scene loaded. In a shared module this will be multiple times in on...
virtual void InitialiseCommon(IConfigSource source)
Common module config for both this and descendant classes.
virtual void RemoveRegion(Scene scene)
This is called whenever a Scene is removed. For shared modules, this can happen several times...
void CreateNewInventoryItem(IClientAPI remoteClient, UUID transactionID, UUID folderID, uint callbackID, string description, string name, sbyte invType, sbyte assetType, byte wearableType, uint nextOwnerMask, int creationDate)
Create a new inventory item. Called when the client creates a new item directly within their inventor...
virtual UUID Owner
The agent who's inventory this is contained by
OpenSim.Services.Interfaces.GridRegion GridRegion
Asset class. All Assets are reference by this class or a class derived from this class ...
int PrimCount
Number of prims in this group
virtual void AddRegion(Scene scene)
This is called whenever a Scene is added. For shared modules, this can happen several times...
string CreatorData
Data about the creator in the form home_url;name
virtual void Initialise(IConfigSource source)
This is called to initialize the region module. For shared modules, this is called exactly once...
Inventory Item - contains all the properties associated with an individual inventory piece...
virtual void PostInitialise()
virtual bool UpdateInventoryItemAsset(UUID ownerID, InventoryItemBase item, AssetBase asset)
bool Validate(AnimationSetValidator val)
bool HandleItemCreationFromTransaction(IClientAPI remoteClient, UUID transactionID, UUID folderID, uint callbackID, string description, string name, sbyte invType, sbyte type, byte wearableType, uint nextOwnerMask)
IUserManagement m_UserManagement
void AddUserData(SceneObjectGroup sog)
UUID ID
A UUID containing the ID for the inventory node itself
virtual List< InventoryItemBase > CopyToInventory(DeRezAction action, UUID folderID, List< SceneObjectGroup > objectGroups, IClientAPI remoteClient, bool asAttachment)
Copy objects to a user's inventory.
InventoryItemBase AddPermissions(InventoryItemBase item, SceneObjectGroup so, List< SceneObjectGroup > objsForEffectivePermissions, IClientAPI remoteClient)
Add relevant permissions for an object to the item.
virtual string Name
The name of the node (64 characters or less)
InventoryItemBase CopyBundleToInventory(DeRezAction action, UUID folderID, List< SceneObjectGroup > objlist, IClientAPI remoteClient, bool asAttachment)
Copy a bundle of objects to inventory. If there is only one object, then this will create an object i...
KeyframeMotion KeyframeMotion
This maintains the relationship between a UUID and a user name.
virtual UUID CapsUpdateInventoryItemAsset(IClientAPI remoteClient, UUID itemID, byte[] data)
Capability originating call to update the asset of an item in an agent's inventory ...
virtual bool CanGetAgentInventoryItem(IClientAPI remoteClient, UUID itemID, UUID requestID)
Does the client have sufficient permissions to retrieve the inventory item?
UUID FromUserInventoryItemID
OpenSim.Region.Framework.Scenes.Animation.AnimationSet AnimationSet
virtual SceneObjectGroup RezObject(IClientAPI remoteClient, UUID itemID, Vector3 RayEnd, Vector3 RayStart, UUID RayTargetID, byte BypassRayCast, bool RayEndIsIntersection, bool RezSelected, bool RemoveItem, UUID fromTaskID, bool attachment)
Rez an object into the scene from the user's inventory
Represents a coalescene of scene objects. A coalescence occurs when objects that are not in the same ...
OpenSim.Framework.PermissionMask PermissionMask
virtual void TransferInventoryAssets(InventoryItemBase item, UUID sender, UUID receiver)
delegate void CreateNewInventoryItem(IClientAPI remoteClient, UUID transActionID, UUID folderID, uint callbackID, string description, string name, sbyte invType, sbyte type, byte wearableType, uint nextOwnerMask, int creationDate)
virtual void ExportAsset(UUID agentID, UUID assetID)