diff options
author | Justin Clarke Casey | 2008-01-06 01:56:29 +0000 |
---|---|---|
committer | Justin Clarke Casey | 2008-01-06 01:56:29 +0000 |
commit | 679923ec871d98e5aa514734b2e23f9a00c58433 (patch) | |
tree | c2591d0a336339dd7ce5ca26d39abde68d0b81be /OpenSim/Region/Environment/Scenes | |
parent | Prim inventory phase 4. Properly recover the prim folder ID from storage. S... (diff) | |
download | opensim-SC-679923ec871d98e5aa514734b2e23f9a00c58433.zip opensim-SC-679923ec871d98e5aa514734b2e23f9a00c58433.tar.gz opensim-SC-679923ec871d98e5aa514734b2e23f9a00c58433.tar.bz2 opensim-SC-679923ec871d98e5aa514734b2e23f9a00c58433.tar.xz |
Factor out TaskInventoryItem
Diffstat (limited to 'OpenSim/Region/Environment/Scenes')
-rw-r--r-- | OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs | 12 | ||||
-rw-r--r-- | OpenSim/Region/Environment/Scenes/SceneObjectPart.cs | 68 |
2 files changed, 6 insertions, 74 deletions
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs index 4bbc2ed..a9b3fe9 100644 --- a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs +++ b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs | |||
@@ -1178,15 +1178,15 @@ namespace OpenSim.Region.Environment.Scenes | |||
1178 | SceneObjectPart part = GetChildPart(localID); | 1178 | SceneObjectPart part = GetChildPart(localID); |
1179 | if (part != null) | 1179 | if (part != null) |
1180 | { | 1180 | { |
1181 | SceneObjectPart.TaskInventoryItem taskItem = new SceneObjectPart.TaskInventoryItem(); | 1181 | TaskInventoryItem taskItem = new TaskInventoryItem(); |
1182 | taskItem.item_id = item.inventoryID; | 1182 | taskItem.item_id = item.inventoryID; |
1183 | taskItem.asset_id = item.assetID; | 1183 | taskItem.asset_id = item.assetID; |
1184 | taskItem.name = item.inventoryName; | 1184 | taskItem.name = item.inventoryName; |
1185 | taskItem.desc = item.inventoryDescription; | 1185 | taskItem.desc = item.inventoryDescription; |
1186 | taskItem.owner_id = item.avatarID; | 1186 | taskItem.owner_id = item.avatarID; |
1187 | taskItem.creator_id = item.creatorsID; | 1187 | taskItem.creator_id = item.creatorsID; |
1188 | taskItem.type = SceneObjectPart.TaskInventoryItem.Types[item.assetType]; | 1188 | taskItem.type = TaskInventoryItem.Types[item.assetType]; |
1189 | taskItem.inv_type = SceneObjectPart.TaskInventoryItem.Types[item.invType]; | 1189 | taskItem.inv_type = TaskInventoryItem.Types[item.invType]; |
1190 | part.AddInventoryItem(taskItem); | 1190 | part.AddInventoryItem(taskItem); |
1191 | return true; | 1191 | return true; |
1192 | } | 1192 | } |
@@ -1200,15 +1200,15 @@ namespace OpenSim.Region.Environment.Scenes | |||
1200 | SceneObjectPart part = GetChildPart(localID); | 1200 | SceneObjectPart part = GetChildPart(localID); |
1201 | if (part != null) | 1201 | if (part != null) |
1202 | { | 1202 | { |
1203 | SceneObjectPart.TaskInventoryItem taskItem = new SceneObjectPart.TaskInventoryItem(); | 1203 | TaskInventoryItem taskItem = new TaskInventoryItem(); |
1204 | taskItem.item_id = copyItemID; | 1204 | taskItem.item_id = copyItemID; |
1205 | taskItem.asset_id = item.assetID; | 1205 | taskItem.asset_id = item.assetID; |
1206 | taskItem.name = item.inventoryName; | 1206 | taskItem.name = item.inventoryName; |
1207 | taskItem.desc = item.inventoryDescription; | 1207 | taskItem.desc = item.inventoryDescription; |
1208 | taskItem.owner_id = new LLUUID(item.avatarID.ToString()); | 1208 | taskItem.owner_id = new LLUUID(item.avatarID.ToString()); |
1209 | taskItem.creator_id = new LLUUID(item.creatorsID.ToString()); | 1209 | taskItem.creator_id = new LLUUID(item.creatorsID.ToString()); |
1210 | taskItem.type = SceneObjectPart.TaskInventoryItem.Types[item.assetType]; | 1210 | taskItem.type = TaskInventoryItem.Types[item.assetType]; |
1211 | taskItem.inv_type = SceneObjectPart.TaskInventoryItem.InvTypes[item.invType]; | 1211 | taskItem.inv_type = TaskInventoryItem.InvTypes[item.invType]; |
1212 | part.AddInventoryItem(taskItem); | 1212 | part.AddInventoryItem(taskItem); |
1213 | return true; | 1213 | return true; |
1214 | } | 1214 | } |
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs b/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs index 2ddcf7b..b07b43c 100644 --- a/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs +++ b/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs | |||
@@ -1736,73 +1736,5 @@ namespace OpenSim.Region.Environment.Scenes | |||
1736 | { | 1736 | { |
1737 | } | 1737 | } |
1738 | } | 1738 | } |
1739 | |||
1740 | public class TaskInventoryItem | ||
1741 | { | ||
1742 | /// <summary> | ||
1743 | /// Inventory types | ||
1744 | /// </summary> | ||
1745 | public static string[] InvTypes = new string[] | ||
1746 | { | ||
1747 | "texture", | ||
1748 | "sound", | ||
1749 | "", | ||
1750 | "", | ||
1751 | "", | ||
1752 | "", | ||
1753 | "", | ||
1754 | "", | ||
1755 | "", | ||
1756 | "", | ||
1757 | "lsl_text", | ||
1758 | "" | ||
1759 | }; | ||
1760 | |||
1761 | /// <summary> | ||
1762 | /// Asset types | ||
1763 | /// </summary> | ||
1764 | public static string[] Types = new string[] | ||
1765 | { | ||
1766 | "texture", | ||
1767 | "sound", | ||
1768 | "", | ||
1769 | "", | ||
1770 | "", | ||
1771 | "", | ||
1772 | "", | ||
1773 | "", | ||
1774 | "", | ||
1775 | "", | ||
1776 | "lsltext", | ||
1777 | "" | ||
1778 | }; | ||
1779 | |||
1780 | public LLUUID item_id = LLUUID.Zero; | ||
1781 | public LLUUID parent_id = LLUUID.Zero; //parent folder id | ||
1782 | |||
1783 | public uint base_mask = FULL_MASK_PERMISSIONS_GENERAL; | ||
1784 | public uint owner_mask = FULL_MASK_PERMISSIONS_GENERAL; | ||
1785 | public uint group_mask = FULL_MASK_PERMISSIONS_GENERAL; | ||
1786 | public uint everyone_mask = FULL_MASK_PERMISSIONS_GENERAL; | ||
1787 | public uint next_owner_mask = FULL_MASK_PERMISSIONS_GENERAL; | ||
1788 | public LLUUID creator_id = LLUUID.Zero; | ||
1789 | public LLUUID owner_id = LLUUID.Zero; | ||
1790 | public LLUUID last_owner_id = LLUUID.Zero; | ||
1791 | public LLUUID group_id = LLUUID.Zero; | ||
1792 | |||
1793 | public LLUUID asset_id = LLUUID.Zero; | ||
1794 | public string type = ""; | ||
1795 | public string inv_type = ""; | ||
1796 | public uint flags = 0; | ||
1797 | public string name = ""; | ||
1798 | public string desc = ""; | ||
1799 | public uint creation_date = 0; | ||
1800 | |||
1801 | public LLUUID ParentPartID = LLUUID.Zero; | ||
1802 | |||
1803 | public TaskInventoryItem() | ||
1804 | { | ||
1805 | } | ||
1806 | } | ||
1807 | } | 1739 | } |
1808 | } | 1740 | } |