aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorMW2007-07-25 19:18:34 +0000
committerMW2007-07-25 19:18:34 +0000
commit74654dc7351baf092ecae12c90a236ec43c86c98 (patch)
treebfff64c22423a0949bb298f676685c84a8257732
parentStart of the OpenSim library , for now only contains a few textures. (diff)
downloadopensim-SC_OLD-74654dc7351baf092ecae12c90a236ec43c86c98.zip
opensim-SC_OLD-74654dc7351baf092ecae12c90a236ec43c86c98.tar.gz
opensim-SC_OLD-74654dc7351baf092ecae12c90a236ec43c86c98.tar.bz2
opensim-SC_OLD-74654dc7351baf092ecae12c90a236ec43c86c98.tar.xz
Added the default shape to the OpenSim library. Now need to get the new ruth into asset format and add that.
-rw-r--r--OpenSim/Framework/Communications/Cache/LibraryRootFolder.cs50
-rw-r--r--OpenSim/Framework/Data/InventoryData.cs8
-rw-r--r--OpenSim/Framework/General/Types/AgentWearable.cs2
-rw-r--r--OpenSim/Region/ClientStack/ClientView.API.cs30
-rw-r--r--bin/assets/base_shape.dat16
5 files changed, 71 insertions, 35 deletions
diff --git a/OpenSim/Framework/Communications/Cache/LibraryRootFolder.cs b/OpenSim/Framework/Communications/Cache/LibraryRootFolder.cs
index 2608145..18803c0 100644
--- a/OpenSim/Framework/Communications/Cache/LibraryRootFolder.cs
+++ b/OpenSim/Framework/Communications/Cache/LibraryRootFolder.cs
@@ -19,6 +19,11 @@ namespace OpenSim.Framework.Communications.Caches
19 this.type = (short)-1; 19 this.type = (short)-1;
20 this.version = (ushort) 1; 20 this.version = (ushort) 1;
21 21
22 this.CreateLibraryItems();
23 }
24
25 private void CreateLibraryItems()
26 {
22 InventoryItemBase item = new InventoryItemBase(); 27 InventoryItemBase item = new InventoryItemBase();
23 item.avatarID = libOwner; 28 item.avatarID = libOwner;
24 item.creatorsID = libOwner; 29 item.creatorsID = libOwner;
@@ -26,10 +31,12 @@ namespace OpenSim.Framework.Communications.Caches
26 item.assetID = new LLUUID("00000000-0000-0000-9999-000000000002"); 31 item.assetID = new LLUUID("00000000-0000-0000-9999-000000000002");
27 item.inventoryDescription = "Plywood texture"; 32 item.inventoryDescription = "Plywood texture";
28 item.inventoryName = "Plywood"; 33 item.inventoryName = "Plywood";
29 item.type =0; 34 item.type = 0;
30 item.parentFolderID = this.folderID; 35 item.parentFolderID = this.folderID;
31 item.inventoryCurrentPermissions = 2147483647; 36 item.inventoryBasePermissions = 0x7FFFFFFF;
32 item.inventoryNextPermissions = 2147483647; 37 item.inventoryEveryOnePermissions = 0x7FFFFFFF;
38 item.inventoryCurrentPermissions = 0x7FFFFFFF;
39 item.inventoryNextPermissions = 0x7FFFFFFF;
33 this.Items.Add(item.inventoryID, item); 40 this.Items.Add(item.inventoryID, item);
34 41
35 item = new InventoryItemBase(); 42 item = new InventoryItemBase();
@@ -41,8 +48,10 @@ namespace OpenSim.Framework.Communications.Caches
41 item.inventoryName = "Rocks"; 48 item.inventoryName = "Rocks";
42 item.type = 0; 49 item.type = 0;
43 item.parentFolderID = this.folderID; 50 item.parentFolderID = this.folderID;
44 item.inventoryCurrentPermissions = 2147483647; 51 item.inventoryBasePermissions = 0x7FFFFFFF;
45 item.inventoryNextPermissions = 2147483647; 52 item.inventoryEveryOnePermissions = 0x7FFFFFFF;
53 item.inventoryCurrentPermissions = 0x7FFFFFFF;
54 item.inventoryNextPermissions = 0x7FFFFFFF;
46 this.Items.Add(item.inventoryID, item); 55 this.Items.Add(item.inventoryID, item);
47 56
48 item = new InventoryItemBase(); 57 item = new InventoryItemBase();
@@ -54,8 +63,10 @@ namespace OpenSim.Framework.Communications.Caches
54 item.inventoryName = "Bricks"; 63 item.inventoryName = "Bricks";
55 item.type = 0; 64 item.type = 0;
56 item.parentFolderID = this.folderID; 65 item.parentFolderID = this.folderID;
57 item.inventoryCurrentPermissions = 2147483647; 66 item.inventoryBasePermissions = 0x7FFFFFFF;
58 item.inventoryNextPermissions = 2147483647; 67 item.inventoryEveryOnePermissions = 0x7FFFFFFF;
68 item.inventoryCurrentPermissions = 0x7FFFFFFF;
69 item.inventoryNextPermissions = 0x7FFFFFFF;
59 this.Items.Add(item.inventoryID, item); 70 this.Items.Add(item.inventoryID, item);
60 71
61 item = new InventoryItemBase(); 72 item = new InventoryItemBase();
@@ -67,8 +78,10 @@ namespace OpenSim.Framework.Communications.Caches
67 item.inventoryName = "Granite"; 78 item.inventoryName = "Granite";
68 item.type = 0; 79 item.type = 0;
69 item.parentFolderID = this.folderID; 80 item.parentFolderID = this.folderID;
70 item.inventoryCurrentPermissions = 2147483647; 81 item.inventoryBasePermissions = 0x7FFFFFFF;
71 item.inventoryNextPermissions = 2147483647; 82 item.inventoryEveryOnePermissions = 0x7FFFFFFF;
83 item.inventoryCurrentPermissions = 0x7FFFFFFF;
84 item.inventoryNextPermissions = 0x7FFFFFFF;
72 this.Items.Add(item.inventoryID, item); 85 this.Items.Add(item.inventoryID, item);
73 86
74 item = new InventoryItemBase(); 87 item = new InventoryItemBase();
@@ -80,8 +93,23 @@ namespace OpenSim.Framework.Communications.Caches
80 item.inventoryName = "Hardwood"; 93 item.inventoryName = "Hardwood";
81 item.type = 0; 94 item.type = 0;
82 item.parentFolderID = this.folderID; 95 item.parentFolderID = this.folderID;
83 item.inventoryCurrentPermissions = 2147483647; 96 item.inventoryBasePermissions = 0x7FFFFFFF;
84 item.inventoryNextPermissions = 2147483647; 97 item.inventoryEveryOnePermissions = 0x7FFFFFFF;
98 item.inventoryCurrentPermissions = 0x7FFFFFFF;
99 item.inventoryNextPermissions = 0x7FFFFFFF;
100 this.Items.Add(item.inventoryID, item);
101
102 item = new InventoryItemBase();
103 item.avatarID = libOwner;
104 item.creatorsID = libOwner;
105 item.inventoryID = new LLUUID("66c41e39-38f9-f75a-024e-585989bfaba9");
106 item.assetID = new LLUUID("66c41e39-38f9-f75a-024e-585989bfab73");
107 item.inventoryDescription = "Default Shape";
108 item.inventoryName = "Default Shape";
109 item.type = 13;
110 item.parentFolderID = this.folderID;
111 item.inventoryCurrentPermissions = 0;
112 item.inventoryNextPermissions = 0;
85 this.Items.Add(item.inventoryID, item); 113 this.Items.Add(item.inventoryID, item);
86 } 114 }
87 115
diff --git a/OpenSim/Framework/Data/InventoryData.cs b/OpenSim/Framework/Data/InventoryData.cs
index d7130f4..c43ff1a 100644
--- a/OpenSim/Framework/Data/InventoryData.cs
+++ b/OpenSim/Framework/Data/InventoryData.cs
@@ -75,6 +75,14 @@ namespace OpenSim.Framework.Data
75 /// A mask containing permissions for the current owner (cannot be enforced) 75 /// A mask containing permissions for the current owner (cannot be enforced)
76 /// </summary> 76 /// </summary>
77 public uint inventoryCurrentPermissions; 77 public uint inventoryCurrentPermissions;
78 /// <summary>
79 ///
80 /// </summary>
81 public uint inventoryBasePermissions;
82 /// <summary>
83 ///
84 /// </summary>
85 public uint inventoryEveryOnePermissions;
78 } 86 }
79 87
80 /// <summary> 88 /// <summary>
diff --git a/OpenSim/Framework/General/Types/AgentWearable.cs b/OpenSim/Framework/General/Types/AgentWearable.cs
index 404df0d..9de25b5 100644
--- a/OpenSim/Framework/General/Types/AgentWearable.cs
+++ b/OpenSim/Framework/General/Types/AgentWearable.cs
@@ -49,7 +49,7 @@ namespace OpenSim.Framework.Types
49 defaultWearables[i] = new AvatarWearable(); 49 defaultWearables[i] = new AvatarWearable();
50 } 50 }
51 defaultWearables[0].AssetID = new LLUUID("66c41e39-38f9-f75a-024e-585989bfab73"); 51 defaultWearables[0].AssetID = new LLUUID("66c41e39-38f9-f75a-024e-585989bfab73");
52 defaultWearables[0].ItemID = LLUUID.Random(); 52 defaultWearables[0].ItemID = new LLUUID("66c41e39-38f9-f75a-024e-585989bfaba9");
53 return defaultWearables; 53 return defaultWearables;
54 } 54 }
55 } 55 }
diff --git a/OpenSim/Region/ClientStack/ClientView.API.cs b/OpenSim/Region/ClientStack/ClientView.API.cs
index 2f5c5c3..0da89a1 100644
--- a/OpenSim/Region/ClientStack/ClientView.API.cs
+++ b/OpenSim/Region/ClientStack/ClientView.API.cs
@@ -526,19 +526,19 @@ namespace OpenSim.Region.ClientStack
526 descend.ItemData[i].ItemID = item.inventoryID; 526 descend.ItemData[i].ItemID = item.inventoryID;
527 descend.ItemData[i].AssetID = item.assetID; 527 descend.ItemData[i].AssetID = item.assetID;
528 descend.ItemData[i].CreatorID = item.creatorsID; 528 descend.ItemData[i].CreatorID = item.creatorsID;
529 descend.ItemData[i].BaseMask = FULL_MASK_PERMISSIONS; 529 descend.ItemData[i].BaseMask = item.inventoryBasePermissions;
530 descend.ItemData[i].CreationDate = 1000; 530 descend.ItemData[i].CreationDate = 1000;
531 descend.ItemData[i].Description = enc.GetBytes(item.inventoryDescription+ "\0"); 531 descend.ItemData[i].Description = enc.GetBytes(item.inventoryDescription+ "\0");
532 descend.ItemData[i].EveryoneMask = FULL_MASK_PERMISSIONS; 532 descend.ItemData[i].EveryoneMask = item.inventoryEveryOnePermissions;
533 descend.ItemData[i].Flags = 1; 533 descend.ItemData[i].Flags = 1;
534 descend.ItemData[i].FolderID = item.parentFolderID; 534 descend.ItemData[i].FolderID = item.parentFolderID;
535 descend.ItemData[i].GroupID = new LLUUID("00000000-0000-0000-0000-000000000000"); 535 descend.ItemData[i].GroupID = new LLUUID("00000000-0000-0000-0000-000000000000");
536 descend.ItemData[i].GroupMask = FULL_MASK_PERMISSIONS; 536 descend.ItemData[i].GroupMask = 0;
537 descend.ItemData[i].InvType = (sbyte)item.type; 537 descend.ItemData[i].InvType = (sbyte)item.type;
538 descend.ItemData[i].Name = enc.GetBytes(item.inventoryName+ "\0"); 538 descend.ItemData[i].Name = enc.GetBytes(item.inventoryName+ "\0");
539 descend.ItemData[i].NextOwnerMask = FULL_MASK_PERMISSIONS; 539 descend.ItemData[i].NextOwnerMask = item.inventoryNextPermissions;
540 descend.ItemData[i].OwnerID = item.avatarID; 540 descend.ItemData[i].OwnerID = item.avatarID;
541 descend.ItemData[i].OwnerMask = FULL_MASK_PERMISSIONS; 541 descend.ItemData[i].OwnerMask = item.inventoryCurrentPermissions;
542 descend.ItemData[i].SalePrice = 0; 542 descend.ItemData[i].SalePrice = 0;
543 descend.ItemData[i].SaleType = 0; 543 descend.ItemData[i].SaleType = 0;
544 descend.ItemData[i].Type = (sbyte)item.type; 544 descend.ItemData[i].Type = (sbyte)item.type;
@@ -562,19 +562,19 @@ namespace OpenSim.Region.ClientStack
562 inventoryReply.InventoryData[0].ItemID = item.inventoryID; 562 inventoryReply.InventoryData[0].ItemID = item.inventoryID;
563 inventoryReply.InventoryData[0].AssetID = item.assetID; 563 inventoryReply.InventoryData[0].AssetID = item.assetID;
564 inventoryReply.InventoryData[0].CreatorID = item.creatorsID; 564 inventoryReply.InventoryData[0].CreatorID = item.creatorsID;
565 inventoryReply.InventoryData[0].BaseMask = FULL_MASK_PERMISSIONS; 565 inventoryReply.InventoryData[0].BaseMask = item.inventoryBasePermissions;
566 inventoryReply.InventoryData[0].CreationDate = (int)(DateTime.UtcNow - new DateTime(1970, 1, 1)).TotalSeconds; 566 inventoryReply.InventoryData[0].CreationDate = (int)(DateTime.UtcNow - new DateTime(1970, 1, 1)).TotalSeconds;
567 inventoryReply.InventoryData[0].Description = enc.GetBytes(item.inventoryDescription + "\0"); 567 inventoryReply.InventoryData[0].Description = enc.GetBytes(item.inventoryDescription + "\0");
568 inventoryReply.InventoryData[0].EveryoneMask = FULL_MASK_PERMISSIONS; 568 inventoryReply.InventoryData[0].EveryoneMask = item.inventoryEveryOnePermissions;
569 inventoryReply.InventoryData[0].Flags = 0; 569 inventoryReply.InventoryData[0].Flags = 0;
570 inventoryReply.InventoryData[0].FolderID = item.parentFolderID; 570 inventoryReply.InventoryData[0].FolderID = item.parentFolderID;
571 inventoryReply.InventoryData[0].GroupID = new LLUUID("00000000-0000-0000-0000-000000000000"); 571 inventoryReply.InventoryData[0].GroupID = new LLUUID("00000000-0000-0000-0000-000000000000");
572 inventoryReply.InventoryData[0].GroupMask = FULL_MASK_PERMISSIONS; 572 inventoryReply.InventoryData[0].GroupMask = 0;
573 inventoryReply.InventoryData[0].InvType = (sbyte)item.type; 573 inventoryReply.InventoryData[0].InvType = (sbyte)item.type;
574 inventoryReply.InventoryData[0].Name = enc.GetBytes(item.inventoryName + "\0"); 574 inventoryReply.InventoryData[0].Name = enc.GetBytes(item.inventoryName + "\0");
575 inventoryReply.InventoryData[0].NextOwnerMask = FULL_MASK_PERMISSIONS; 575 inventoryReply.InventoryData[0].NextOwnerMask = item.inventoryNextPermissions;
576 inventoryReply.InventoryData[0].OwnerID = item.avatarID; 576 inventoryReply.InventoryData[0].OwnerID = item.avatarID;
577 inventoryReply.InventoryData[0].OwnerMask = FULL_MASK_PERMISSIONS; 577 inventoryReply.InventoryData[0].OwnerMask = item.inventoryCurrentPermissions;
578 inventoryReply.InventoryData[0].SalePrice = 0; 578 inventoryReply.InventoryData[0].SalePrice = 0;
579 inventoryReply.InventoryData[0].SaleType = 0; 579 inventoryReply.InventoryData[0].SaleType = 0;
580 inventoryReply.InventoryData[0].Type = (sbyte)item.type; 580 inventoryReply.InventoryData[0].Type = (sbyte)item.type;
@@ -595,19 +595,19 @@ namespace OpenSim.Region.ClientStack
595 InventoryReply.InventoryData[0].ItemID = Item.inventoryID; 595 InventoryReply.InventoryData[0].ItemID = Item.inventoryID;
596 InventoryReply.InventoryData[0].AssetID = Item.assetID; 596 InventoryReply.InventoryData[0].AssetID = Item.assetID;
597 InventoryReply.InventoryData[0].CreatorID = Item.creatorsID; 597 InventoryReply.InventoryData[0].CreatorID = Item.creatorsID;
598 InventoryReply.InventoryData[0].BaseMask = FULL_MASK_PERMISSIONS; 598 InventoryReply.InventoryData[0].BaseMask = Item.inventoryBasePermissions;
599 InventoryReply.InventoryData[0].CreationDate = 1000; 599 InventoryReply.InventoryData[0].CreationDate = 1000;
600 InventoryReply.InventoryData[0].Description = enc.GetBytes(Item.inventoryDescription + "\0"); 600 InventoryReply.InventoryData[0].Description = enc.GetBytes(Item.inventoryDescription + "\0");
601 InventoryReply.InventoryData[0].EveryoneMask = FULL_MASK_PERMISSIONS; 601 InventoryReply.InventoryData[0].EveryoneMask = Item.inventoryEveryOnePermissions;
602 InventoryReply.InventoryData[0].Flags = 0; 602 InventoryReply.InventoryData[0].Flags = 0;
603 InventoryReply.InventoryData[0].FolderID = Item.parentFolderID; 603 InventoryReply.InventoryData[0].FolderID = Item.parentFolderID;
604 InventoryReply.InventoryData[0].GroupID = new LLUUID("00000000-0000-0000-0000-000000000000"); 604 InventoryReply.InventoryData[0].GroupID = new LLUUID("00000000-0000-0000-0000-000000000000");
605 InventoryReply.InventoryData[0].GroupMask = FULL_MASK_PERMISSIONS; 605 InventoryReply.InventoryData[0].GroupMask = 0;
606 InventoryReply.InventoryData[0].InvType =(sbyte) Item.type; 606 InventoryReply.InventoryData[0].InvType =(sbyte) Item.type;
607 InventoryReply.InventoryData[0].Name = enc.GetBytes(Item.inventoryName + "\0"); 607 InventoryReply.InventoryData[0].Name = enc.GetBytes(Item.inventoryName + "\0");
608 InventoryReply.InventoryData[0].NextOwnerMask = FULL_MASK_PERMISSIONS; 608 InventoryReply.InventoryData[0].NextOwnerMask = Item.inventoryNextPermissions;
609 InventoryReply.InventoryData[0].OwnerID = Item.avatarID; 609 InventoryReply.InventoryData[0].OwnerID = Item.avatarID;
610 InventoryReply.InventoryData[0].OwnerMask = FULL_MASK_PERMISSIONS; 610 InventoryReply.InventoryData[0].OwnerMask = Item.inventoryCurrentPermissions;
611 InventoryReply.InventoryData[0].SalePrice = 100; 611 InventoryReply.InventoryData[0].SalePrice = 100;
612 InventoryReply.InventoryData[0].SaleType = 0; 612 InventoryReply.InventoryData[0].SaleType = 0;
613 InventoryReply.InventoryData[0].Type =(sbyte) Item.type; 613 InventoryReply.InventoryData[0].Type =(sbyte) Item.type;
diff --git a/bin/assets/base_shape.dat b/bin/assets/base_shape.dat
index 920c775..d9a361f 100644
--- a/bin/assets/base_shape.dat
+++ b/bin/assets/base_shape.dat
@@ -3,14 +3,14 @@ Female Shape and Outfit 3 Shape
3Created by system from avatar's appearance. 3Created by system from avatar's appearance.
4 permissions 0 4 permissions 0
5 { 5 {
6 base_mask 00082000 6 base_mask 00000000
7 owner_mask 00082000 7 owner_mask 00000000
8 group_mask 00082000 8 group_mask 00000000
9 everyone_mask 00082000 9 everyone_mask 00000000
10 next_owner_mask 00082000 10 next_owner_mask 00000000
11 creator_id 3d924400-038e-6ad9-920b-cfbb9b40585c 11 creator_id 11111111-1111-0000-0000-000100bba000
12 owner_id 542ffb8e-8932-49b9-8664-58f53e442797 12 owner_id 11111111-1111-0000-0000-000100bba000
13 last_owner_id 3d924400-038e-6ad9-920b-cfbb9b40585c 13 last_owner_id 11111111-1111-0000-0000-000100bba000
14 group_id 00000000-0000-0000-0000-000000000000 14 group_id 00000000-0000-0000-0000-000000000000
15 } 15 }
16 sale_info 0 16 sale_info 0