aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs73
1 files changed, 40 insertions, 33 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
index 34a2797..7f25f78 100644
--- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
+++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
@@ -6535,7 +6535,10 @@ namespace OpenSim.Region.ClientStack.LindenUDP
6535 6535
6536 WearableCacheItem[] cacheitems = new WearableCacheItem[appear.WearableData.Length]; 6536 WearableCacheItem[] cacheitems = new WearableCacheItem[appear.WearableData.Length];
6537 for (int i=0; i<appear.WearableData.Length;i++) 6537 for (int i=0; i<appear.WearableData.Length;i++)
6538 cacheitems[i] = new WearableCacheItem(){CacheId = appear.WearableData[i].CacheID,TextureIndex=Convert.ToUInt32(appear.WearableData[i].TextureIndex)}; 6538 cacheitems[i] = new WearableCacheItem(){
6539 CacheId = appear.WearableData[i].CacheID,
6540 TextureIndex=Convert.ToUInt32(appear.WearableData[i].TextureIndex)
6541 };
6539 6542
6540 6543
6541 6544
@@ -12025,47 +12028,55 @@ namespace OpenSim.Region.ClientStack.LindenUDP
12025 if (maxWearablesLoop > AvatarWearable.MAX_WEARABLES) 12028 if (maxWearablesLoop > AvatarWearable.MAX_WEARABLES)
12026 maxWearablesLoop = AvatarWearable.MAX_WEARABLES; 12029 maxWearablesLoop = AvatarWearable.MAX_WEARABLES;
12027 12030
12028 if (bakedTextureModule != null && cache != null) 12031// if (bakedTextureModule != null && cache != null)
12032 if (cache != null)
12029 { 12033 {
12030 // We need to make sure the asset stored in the bake is available on this server also by it's assetid before we map it to a Cacheid 12034 // We need to make sure the asset stored in the bake is available on this server also by it's assetid before we map it to a Cacheid
12031 12035
12032 WearableCacheItem[] cacheItems = null; 12036 WearableCacheItem[] cacheItems = null;
12033 ScenePresence p = m_scene.GetScenePresence(AgentId); 12037 ScenePresence p = m_scene.GetScenePresence(AgentId);
12034 if (p.Appearance != null) 12038 if (p.Appearance != null)
12035 if (p.Appearance.WearableCacheItems == null || p.Appearance.WearableCacheItemsDirty) 12039 {
12040 if (p.Appearance.WearableCacheItems == null)
12036 { 12041 {
12037 try 12042 if (bakedTextureModule != null)
12038 { 12043 {
12039 cacheItems = bakedTextureModule.Get(AgentId); 12044 try
12040 p.Appearance.WearableCacheItems = cacheItems; 12045 {
12041 p.Appearance.WearableCacheItemsDirty = false; 12046 if (p.Appearance.WearableCacheItemsDirty)
12042 } 12047 {
12048 cacheItems = bakedTextureModule.Get(AgentId);
12049 p.Appearance.WearableCacheItems = cacheItems;
12050 p.Appearance.WearableCacheItemsDirty = false;
12051 }
12052 }
12043 12053
12044 /* 12054 /*
12045 * The following Catch types DO NOT WORK, it jumps to the General Packet Exception Handler if you don't catch Exception! 12055 * The following Catch types DO NOT WORK, it jumps to the General Packet Exception Handler if you don't catch Exception!
12046 * 12056 *
12047 catch (System.Net.Sockets.SocketException) 12057 catch (System.Net.Sockets.SocketException)
12048 { 12058 {
12049 cacheItems = null; 12059 cacheItems = null;
12050 } 12060 }
12051 catch (WebException) 12061 catch (WebException)
12052 { 12062 {
12053 cacheItems = null; 12063 cacheItems = null;
12054 } 12064 }
12055 catch (InvalidOperationException) 12065 catch (InvalidOperationException)
12056 { 12066 {
12057 cacheItems = null; 12067 cacheItems = null;
12058 } */ 12068 } */
12059 catch (Exception) 12069 catch (Exception)
12060 { 12070 {
12061 cacheItems = null; 12071 cacheItems = null;
12072 }
12062 } 12073 }
12063
12064 } 12074 }
12065 else if (p.Appearance.WearableCacheItems != null) 12075 else if (p.Appearance.WearableCacheItems != null)
12066 { 12076 {
12067 cacheItems = p.Appearance.WearableCacheItems; 12077 cacheItems = p.Appearance.WearableCacheItems;
12068 } 12078 }
12079 }
12069 12080
12070 if (cache != null && cacheItems != null) 12081 if (cache != null && cacheItems != null)
12071 { 12082 {
@@ -12077,8 +12088,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP
12077 item.TextureAsset.Temporary = true; 12088 item.TextureAsset.Temporary = true;
12078 cache.Store(item.TextureAsset); 12089 cache.Store(item.TextureAsset);
12079 } 12090 }
12080
12081
12082 } 12091 }
12083 } 12092 }
12084 12093
@@ -12136,13 +12145,11 @@ namespace OpenSim.Region.ClientStack.LindenUDP
12136 cachedresp.WearableData[i] = new AgentCachedTextureResponsePacket.WearableDataBlock(); 12145 cachedresp.WearableData[i] = new AgentCachedTextureResponsePacket.WearableDataBlock();
12137 cachedresp.WearableData[i].TextureIndex = cachedtex.WearableData[i].TextureIndex; 12146 cachedresp.WearableData[i].TextureIndex = cachedtex.WearableData[i].TextureIndex;
12138 12147
12139
12140
12141 if (cache.GetCached(cachedresp.WearableData[i].TextureID.ToString()) == null) 12148 if (cache.GetCached(cachedresp.WearableData[i].TextureID.ToString()) == null)
12142 cachedresp.WearableData[i].TextureID = UUID.Zero; 12149 cachedresp.WearableData[i].TextureID = UUID.Zero;
12143 //UUID.Parse("8334fb6e-c2f5-46ee-807d-a435f61a8d46"); 12150 //UUID.Parse("8334fb6e-c2f5-46ee-807d-a435f61a8d46");
12144 else 12151// else
12145 cachedresp.WearableData[i].TextureID = UUID.Zero; 12152// cachedresp.WearableData[i].TextureID = UUID.Zero;
12146 // UUID.Parse("8334fb6e-c2f5-46ee-807d-a435f61a8d46"); 12153 // UUID.Parse("8334fb6e-c2f5-46ee-807d-a435f61a8d46");
12147 cachedresp.WearableData[i].HostName = new byte[0]; 12154 cachedresp.WearableData[i].HostName = new byte[0];
12148 } 12155 }