aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ClientStack/ClientView.API.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/ClientStack/ClientView.API.cs')
-rw-r--r--OpenSim/Region/ClientStack/ClientView.API.cs46
1 files changed, 46 insertions, 0 deletions
diff --git a/OpenSim/Region/ClientStack/ClientView.API.cs b/OpenSim/Region/ClientStack/ClientView.API.cs
index 8a5e631..084f7e0 100644
--- a/OpenSim/Region/ClientStack/ClientView.API.cs
+++ b/OpenSim/Region/ClientStack/ClientView.API.cs
@@ -81,6 +81,10 @@ namespace OpenSim.Region.ClientStack
81 public event RequestMapBlocks OnRequestMapBlocks; 81 public event RequestMapBlocks OnRequestMapBlocks;
82 public event TeleportLocationRequest OnTeleportLocationRequest; 82 public event TeleportLocationRequest OnTeleportLocationRequest;
83 83
84 public event CreateInventoryFolder OnCreateNewInventoryFolder;
85 public event FetchInventoryDescendents OnFetchInventoryDescendents;
86 public event RequestTaskInventory OnRequestTaskInventory;
87
84 public event UUIDNameRequest OnNameFromUUIDRequest; 88 public event UUIDNameRequest OnNameFromUUIDRequest;
85 89
86 public event ParcelPropertiesRequest OnParcelPropertiesRequest; 90 public event ParcelPropertiesRequest OnParcelPropertiesRequest;
@@ -577,6 +581,48 @@ namespace OpenSim.Region.ClientStack
577 this.OutPacket(inventoryReply); 581 this.OutPacket(inventoryReply);
578 } 582 }
579 583
584 public void SendInventoryItemUpdate(InventoryItemBase Item)
585 {
586 Encoding enc = Encoding.ASCII;
587 uint FULL_MASK_PERMISSIONS = 2147483647;
588 UpdateCreateInventoryItemPacket InventoryReply = new UpdateCreateInventoryItemPacket();
589 InventoryReply.AgentData.AgentID = this.AgentID;
590 InventoryReply.AgentData.SimApproved = true;
591 InventoryReply.InventoryData = new UpdateCreateInventoryItemPacket.InventoryDataBlock[1];
592 InventoryReply.InventoryData[0] = new UpdateCreateInventoryItemPacket.InventoryDataBlock();
593 InventoryReply.InventoryData[0].ItemID = Item.inventoryID;
594 InventoryReply.InventoryData[0].AssetID = Item.assetID;
595 InventoryReply.InventoryData[0].CreatorID = Item.creatorsID;
596 InventoryReply.InventoryData[0].BaseMask = FULL_MASK_PERMISSIONS;
597 InventoryReply.InventoryData[0].CreationDate = 1000;
598 InventoryReply.InventoryData[0].Description = enc.GetBytes(Item.inventoryDescription + "\0");
599 InventoryReply.InventoryData[0].EveryoneMask = FULL_MASK_PERMISSIONS;
600 InventoryReply.InventoryData[0].Flags = 0;
601 InventoryReply.InventoryData[0].FolderID = Item.parentFolderID;
602 InventoryReply.InventoryData[0].GroupID = new LLUUID("00000000-0000-0000-0000-000000000000");
603 InventoryReply.InventoryData[0].GroupMask = FULL_MASK_PERMISSIONS;
604 InventoryReply.InventoryData[0].InvType =(sbyte) Item.type;
605 InventoryReply.InventoryData[0].Name = enc.GetBytes(Item.inventoryName + "\0");
606 InventoryReply.InventoryData[0].NextOwnerMask = FULL_MASK_PERMISSIONS;
607 InventoryReply.InventoryData[0].OwnerID = Item.avatarID;
608 InventoryReply.InventoryData[0].OwnerMask = FULL_MASK_PERMISSIONS;
609 InventoryReply.InventoryData[0].SalePrice = 100;
610 InventoryReply.InventoryData[0].SaleType = 0;
611 InventoryReply.InventoryData[0].Type =(sbyte) Item.type;
612 InventoryReply.InventoryData[0].CRC = Helpers.InventoryCRC(1000, 0, InventoryReply.InventoryData[0].InvType, InventoryReply.InventoryData[0].Type, InventoryReply.InventoryData[0].AssetID, InventoryReply.InventoryData[0].GroupID, 100, InventoryReply.InventoryData[0].OwnerID, InventoryReply.InventoryData[0].CreatorID, InventoryReply.InventoryData[0].ItemID, InventoryReply.InventoryData[0].FolderID, FULL_MASK_PERMISSIONS, 1, FULL_MASK_PERMISSIONS, FULL_MASK_PERMISSIONS, FULL_MASK_PERMISSIONS);
613
614 OutPacket(InventoryReply);
615 }
616
617 public void SendTaskInventory(LLUUID taskID, short serial, byte[] fileName)
618 {
619 ReplyTaskInventoryPacket replytask = new ReplyTaskInventoryPacket();
620 replytask.InventoryData.TaskID = taskID;
621 replytask.InventoryData.Serial = serial;
622 replytask.InventoryData.Filename = fileName;
623 OutPacket(replytask);
624 }
625
580 /// <summary> 626 /// <summary>
581 /// 627 ///
582 /// </summary> 628 /// </summary>