From 93bede4e6aa0838e14f39f5e641b028267d2683c Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Fri, 7 Dec 2012 21:26:58 +0000 Subject: revert the use of avatar skeleton and use avatar size provided by viewers, since at least for now seems good enought --- OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs') diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs index 8e0b72f..2efaa79 100644 --- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs @@ -6248,6 +6248,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP // Temporarily protect ourselves from the mantis #951 failure. // However, we could do this for several other handlers where a failure isn't terminal // for the client session anyway, in order to protect ourselves against bad code in plugins + Vector3 avSize = appear.AgentData.Size; try { byte[] visualparams = new byte[appear.VisualParam.Length]; @@ -6258,7 +6259,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP if (appear.ObjectData.TextureEntry.Length > 1) te = new Primitive.TextureEntry(appear.ObjectData.TextureEntry, 0, appear.ObjectData.TextureEntry.Length); - handlerSetAppearance(sender, te, visualparams); + handlerSetAppearance(sender, te, visualparams,avSize); } catch (Exception e) { -- cgit v1.1 From ecdd0e225f088ad1311a26f5934cd9e08aa697bd Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Sun, 9 Dec 2012 00:55:09 +0000 Subject: add velocityinterpolator packets handling but actually do nothing, since they don't do what i was looking for. --- .../Region/ClientStack/Linden/UDP/LLClientView.cs | 28 +++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) (limited to 'OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs') diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs index 2efaa79..4ed9a0a 100644 --- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs @@ -331,6 +331,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP private Prioritizer m_prioritizer; private bool m_disableFacelights = false; + private bool m_VelocityInterpolate = false; private const uint MaxTransferBytesPerPacket = 600; @@ -5309,8 +5310,10 @@ namespace OpenSim.Region.ClientStack.LindenUDP // If AgentUpdate is ever handled asynchronously, then we will also need to construct a new AgentUpdateArgs // for each AgentUpdate packet. AddLocalPacketHandler(PacketType.AgentUpdate, HandleAgentUpdate, false); - + AddLocalPacketHandler(PacketType.ViewerEffect, HandleViewerEffect, false); + AddLocalPacketHandler(PacketType.VelocityInterpolateOff, HandleVelocityInterpolateOff, false); + AddLocalPacketHandler(PacketType.VelocityInterpolateOn, HandleVelocityInterpolateOn, false); AddLocalPacketHandler(PacketType.AgentCachedTexture, HandleAgentTextureCached, false); AddLocalPacketHandler(PacketType.MultipleObjectUpdate, HandleMultipleObjUpdate, false); AddLocalPacketHandler(PacketType.MoneyTransferRequest, HandleMoneyTransferRequest, false); @@ -5828,6 +5831,29 @@ namespace OpenSim.Region.ClientStack.LindenUDP return true; } + private bool HandleVelocityInterpolateOff(IClientAPI sender, Packet Pack) + { + VelocityInterpolateOffPacket p = (VelocityInterpolateOffPacket)Pack; + if (p.AgentData.SessionID != SessionId || + p.AgentData.AgentID != AgentId) + return true; + + m_VelocityInterpolate = false; + return true; + } + + private bool HandleVelocityInterpolateOn(IClientAPI sender, Packet Pack) + { + VelocityInterpolateOffPacket p = (VelocityInterpolateOffPacket)Pack; + if (p.AgentData.SessionID != SessionId || + p.AgentData.AgentID != AgentId) + return true; + + m_VelocityInterpolate = true; + return true; + } + + private bool HandleAvatarPropertiesRequest(IClientAPI sender, Packet Pack) { AvatarPropertiesRequestPacket avatarProperties = (AvatarPropertiesRequestPacket)Pack; -- cgit v1.1 From c6430b14dbc9d39b9c9b79ead1c1ebaaff833745 Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Mon, 10 Dec 2012 11:25:30 +0000 Subject: typo fix --- OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs') diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs index 4ed9a0a..ea3c6a4 100644 --- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs @@ -3992,6 +3992,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP const float TIME_DILATION = 1.0f; ushort timeDilation = Utils.FloatToUInt16(avgTimeDilation, 0.0f, 1.0f); + if (terseAgentUpdateBlocks.IsValueCreated) { @@ -4972,7 +4973,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP // in that direction, even though we don't model this on the server. Implementing this in the future // may improve movement smoothness. // acceleration = new Vector3(1, 0, 0); - + angularVelocity = Vector3.Zero; if (sendTexture) @@ -5844,7 +5845,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP private bool HandleVelocityInterpolateOn(IClientAPI sender, Packet Pack) { - VelocityInterpolateOffPacket p = (VelocityInterpolateOffPacket)Pack; + VelocityInterpolateOnPacket p = (VelocityInterpolateOnPacket)Pack; if (p.AgentData.SessionID != SessionId || p.AgentData.AgentID != AgentId) return true; -- cgit v1.1 From 20773dcfccc04d8af14e27f87746711bfaba07b1 Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Thu, 13 Dec 2012 02:55:36 +0000 Subject: add a Check method to flotsamAssetCache, so to check if a asset is in cache without actually loading it. Make use limited use of it in avatarfactory textures check. Also on llclientview HandleAgentTextureCached that now should work. Other asset cache modules for now will return false, so are broken. baked textures logic still unchanged. *UNTESTED* --- .../Region/ClientStack/Linden/UDP/LLClientView.cs | 29 ++++++++++++++++------ 1 file changed, 22 insertions(+), 7 deletions(-) (limited to 'OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs') diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs index ea3c6a4..edb1a9d 100644 --- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs @@ -3992,7 +3992,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP const float TIME_DILATION = 1.0f; ushort timeDilation = Utils.FloatToUInt16(avgTimeDilation, 0.0f, 1.0f); - if (terseAgentUpdateBlocks.IsValueCreated) { @@ -11695,14 +11694,30 @@ namespace OpenSim.Region.ClientStack.LindenUDP cachedresp.WearableData = new AgentCachedTextureResponsePacket.WearableDataBlock[cachedtex.WearableData.Length]; - for (int i = 0; i < cachedtex.WearableData.Length; i++) + IImprovedAssetCache cache = m_scene.RequestModuleInterface(); + if (cache == null) { - cachedresp.WearableData[i] = new AgentCachedTextureResponsePacket.WearableDataBlock(); - cachedresp.WearableData[i].TextureIndex = cachedtex.WearableData[i].TextureIndex; - cachedresp.WearableData[i].TextureID = UUID.Zero; - cachedresp.WearableData[i].HostName = new byte[0]; + for (int i = 0; i < cachedtex.WearableData.Length; i++) + { + cachedresp.WearableData[i] = new AgentCachedTextureResponsePacket.WearableDataBlock(); + cachedresp.WearableData[i].TextureIndex = cachedtex.WearableData[i].TextureIndex; + cachedresp.WearableData[i].TextureID = UUID.Zero; + cachedresp.WearableData[i].HostName = new byte[0]; + } + } + else + { + for (int i = 0; i < cachedtex.WearableData.Length; i++) + { + cachedresp.WearableData[i] = new AgentCachedTextureResponsePacket.WearableDataBlock(); + cachedresp.WearableData[i].TextureIndex = cachedtex.WearableData[i].TextureIndex; + if(cache.Check(cachedtex.WearableData[i].ID.ToString())) + cachedresp.WearableData[i].TextureID = UUID.Zero; + else + cachedresp.WearableData[i].TextureID = UUID.Zero; + cachedresp.WearableData[i].HostName = new byte[0]; + } } - cachedresp.Header.Zerocoded = true; OutPacket(cachedresp, ThrottleOutPacketType.Task); -- cgit v1.1 From b3a77c16bd2ad83076ddf19275b2f104210bba07 Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Thu, 13 Dec 2012 07:34:27 +0000 Subject: FIX small avatars movement on terrain. (avatar appearance getting even more messy) --- OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs') diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs index edb1a9d..4860da0 100644 --- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs @@ -5122,7 +5122,9 @@ namespace OpenSim.Region.ClientStack.LindenUDP update.PCode = (byte)PCode.Avatar; update.ProfileCurve = 1; update.PSBlock = Utils.EmptyBytes; - update.Scale = new Vector3(0.45f, 0.6f, 1.9f); + update.Scale = data.Appearance.AvatarSize; +// update.Scale.Z -= 0.2f; + update.Text = Utils.EmptyBytes; update.TextColor = new byte[4]; -- cgit v1.1