From 73c115702777b62233737cf0de4e8ec4f3878f19 Mon Sep 17 00:00:00 2001 From: Justin Clarke Casey Date: Thu, 5 Jun 2008 00:29:02 +0000 Subject: * exprimental: Export and reimport all items within a prim except Objects * Not yet ready for public use --- .../Environment/Modules/World/Archiver/AssetsDearchiver.cs | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'OpenSim/Region/Environment/Modules/World/Archiver/AssetsDearchiver.cs') diff --git a/OpenSim/Region/Environment/Modules/World/Archiver/AssetsDearchiver.cs b/OpenSim/Region/Environment/Modules/World/Archiver/AssetsDearchiver.cs index 9e63ccf..0c56ae3 100644 --- a/OpenSim/Region/Environment/Modules/World/Archiver/AssetsDearchiver.cs +++ b/OpenSim/Region/Environment/Modules/World/Archiver/AssetsDearchiver.cs @@ -97,7 +97,6 @@ namespace OpenSim.Region.Environment.Modules.World.Archiver reader.ReadStartElement("assets"); reader.Read(); - m_log.DebugFormat("next node {0}", reader.Name); while (reader.Name.Equals("asset")) { reader.Read(); @@ -150,11 +149,16 @@ namespace OpenSim.Region.Environment.Modules.World.Archiver { AssetMetadata metadata = m_metadata[filename]; - string rawId = filename.Remove(filename.Length - ArchiveConstants.TEXTURE_EXTENSION.Length); + string extension = String.Empty; + + if ((sbyte)AssetType.Texture == metadata.AssetType) + { + filename = filename.Remove(filename.Length - ArchiveConstants.TEXTURE_EXTENSION.Length); + } - m_log.DebugFormat("[ARCHIVER]: Importing asset {0}", rawId); + m_log.DebugFormat("[ARCHIVER]: Importing asset {0}", filename); - AssetBase asset = new AssetBase(new LLUUID(rawId), metadata.Name); + AssetBase asset = new AssetBase(new LLUUID(filename), metadata.Name); asset.Description = metadata.Description; asset.Type = metadata.AssetType; asset.InvType = metadata.InventoryType; -- cgit v1.1