diff options
Diffstat (limited to 'OpenSim')
6 files changed, 12 insertions, 28 deletions
diff --git a/OpenSim/Framework/IClientAPI.cs b/OpenSim/Framework/IClientAPI.cs index f39eb0c..98358e5 100644 --- a/OpenSim/Framework/IClientAPI.cs +++ b/OpenSim/Framework/IClientAPI.cs | |||
@@ -1476,7 +1476,7 @@ namespace OpenSim.Framework | |||
1476 | void SendChangeUserRights(UUID agentID, UUID friendID, int rights); | 1476 | void SendChangeUserRights(UUID agentID, UUID friendID, int rights); |
1477 | void SendTextBoxRequest(string message, int chatChannel, string objectname, UUID ownerID, string ownerFirstName, string ownerLastName, UUID objectId); | 1477 | void SendTextBoxRequest(string message, int chatChannel, string objectname, UUID ownerID, string ownerFirstName, string ownerLastName, UUID objectId); |
1478 | 1478 | ||
1479 | void StopFlying(ISceneEntity presence); | 1479 | void SendAgentTerseUpdate(ISceneEntity presence); |
1480 | 1480 | ||
1481 | void SendPlacesReply(UUID queryID, UUID transactionID, PlacesReplyData[] data); | 1481 | void SendPlacesReply(UUID queryID, UUID transactionID, PlacesReplyData[] data); |
1482 | } | 1482 | } |
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs index 2907580..a8759ab 100644 --- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs | |||
@@ -5016,7 +5016,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
5016 | { | 5016 | { |
5017 | ScenePresence presence = (ScenePresence)entity; | 5017 | ScenePresence presence = (ScenePresence)entity; |
5018 | 5018 | ||
5019 | attachPoint = 0; | 5019 | attachPoint = presence.State; |
5020 | collisionPlane = presence.CollisionPlane; | 5020 | collisionPlane = presence.CollisionPlane; |
5021 | position = presence.OffsetPosition; | 5021 | position = presence.OffsetPosition; |
5022 | velocity = presence.Velocity; | 5022 | velocity = presence.Velocity; |
@@ -5040,7 +5040,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
5040 | SceneObjectPart part = (SceneObjectPart)entity; | 5040 | SceneObjectPart part = (SceneObjectPart)entity; |
5041 | 5041 | ||
5042 | attachPoint = part.ParentGroup.AttachmentPoint; | 5042 | attachPoint = part.ParentGroup.AttachmentPoint; |
5043 | 5043 | attachPoint = ((attachPoint % 16) * 16 + (attachPoint / 16)); | |
5044 | // m_log.DebugFormat( | 5044 | // m_log.DebugFormat( |
5045 | // "[LLCLIENTVIEW]: Sending attachPoint {0} for {1} {2} to {3}", | 5045 | // "[LLCLIENTVIEW]: Sending attachPoint {0} for {1} {2} to {3}", |
5046 | // attachPoint, part.Name, part.LocalId, Name); | 5046 | // attachPoint, part.Name, part.LocalId, Name); |
@@ -5068,7 +5068,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
5068 | pos += 4; | 5068 | pos += 4; |
5069 | 5069 | ||
5070 | // Avatar/CollisionPlane | 5070 | // Avatar/CollisionPlane |
5071 | data[pos++] = (byte)((attachPoint % 16) * 16 + (attachPoint / 16)); ; | 5071 | data[pos++] = (byte) attachPoint; |
5072 | if (avatar) | 5072 | if (avatar) |
5073 | { | 5073 | { |
5074 | data[pos++] = 1; | 5074 | data[pos++] = 1; |
@@ -12550,7 +12550,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
12550 | OutPacket(dialog, ThrottleOutPacketType.Task); | 12550 | OutPacket(dialog, ThrottleOutPacketType.Task); |
12551 | } | 12551 | } |
12552 | 12552 | ||
12553 | public void StopFlying(ISceneEntity p) | 12553 | public void SendAgentTerseUpdate(ISceneEntity p) |
12554 | { | 12554 | { |
12555 | if (p is ScenePresence) | 12555 | if (p is ScenePresence) |
12556 | { | 12556 | { |
@@ -12564,25 +12564,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
12564 | 12564 | ||
12565 | Vector3 pos = presence.AbsolutePosition; | 12565 | Vector3 pos = presence.AbsolutePosition; |
12566 | 12566 | ||
12567 | if (presence.Appearance.AvatarHeight != 127.0f) | ||
12568 | pos += new Vector3(0f, 0f, (presence.Appearance.AvatarHeight/6f)); | ||
12569 | else | ||
12570 | pos += new Vector3(0f, 0f, (1.56f/6f)); | ||
12571 | |||
12572 | presence.AbsolutePosition = pos; | ||
12573 | |||
12574 | // attach a suitable collision plane regardless of the actual situation to force the LLClient to land. | ||
12575 | // Collision plane below the avatar's position a 6th of the avatar's height is suitable. | ||
12576 | // Mind you, that this method doesn't get called if the avatar's velocity magnitude is greater then a | ||
12577 | // certain amount.. because the LLClient wouldn't land in that situation anyway. | ||
12578 | |||
12579 | // why are we still testing for this really old height value default??? | ||
12580 | if (presence.Appearance.AvatarHeight != 127.0f) | ||
12581 | presence.CollisionPlane = new Vector4(0, 0, 0, pos.Z - presence.Appearance.AvatarHeight/6f); | ||
12582 | else | ||
12583 | presence.CollisionPlane = new Vector4(0, 0, 0, pos.Z - (1.56f/6f)); | ||
12584 | |||
12585 | |||
12586 | ImprovedTerseObjectUpdatePacket.ObjectDataBlock block = | 12567 | ImprovedTerseObjectUpdatePacket.ObjectDataBlock block = |
12587 | CreateImprovedTerseBlock(p, false); | 12568 | CreateImprovedTerseBlock(p, false); |
12588 | 12569 | ||
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index 2359f55..e06cec8 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs | |||
@@ -1125,7 +1125,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
1125 | 1125 | ||
1126 | public void StopFlying() | 1126 | public void StopFlying() |
1127 | { | 1127 | { |
1128 | ControllingClient.StopFlying(this); | 1128 | ControllingClient.SendAgentTerseUpdate(this); |
1129 | } | 1129 | } |
1130 | 1130 | ||
1131 | /// <summary> | 1131 | /// <summary> |
@@ -1728,6 +1728,9 @@ namespace OpenSim.Region.Framework.Scenes | |||
1728 | SendControlsToScripts(flagsForScripts); | 1728 | SendControlsToScripts(flagsForScripts); |
1729 | } | 1729 | } |
1730 | 1730 | ||
1731 | if ((State & 0x10) != 0) | ||
1732 | ControllingClient.SendAgentTerseUpdate(this); | ||
1733 | |||
1731 | m_scene.EventManager.TriggerOnClientMovement(this); | 1734 | m_scene.EventManager.TriggerOnClientMovement(this); |
1732 | } | 1735 | } |
1733 | 1736 | ||
diff --git a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs index 9b69da3..23a435d 100644 --- a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs +++ b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs | |||
@@ -1673,7 +1673,7 @@ namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server | |||
1673 | { | 1673 | { |
1674 | } | 1674 | } |
1675 | 1675 | ||
1676 | public void StopFlying(ISceneEntity presence) | 1676 | public void SendAgentTerseUpdate(ISceneEntity presence) |
1677 | { | 1677 | { |
1678 | } | 1678 | } |
1679 | 1679 | ||
diff --git a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs index 6c38b65..9a61702 100644 --- a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs +++ b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs | |||
@@ -1229,7 +1229,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC | |||
1229 | { | 1229 | { |
1230 | } | 1230 | } |
1231 | 1231 | ||
1232 | public void StopFlying(ISceneEntity presence) | 1232 | public void SendAgentTerseUpdate(ISceneEntity presence) |
1233 | { | 1233 | { |
1234 | } | 1234 | } |
1235 | 1235 | ||
diff --git a/OpenSim/Tests/Common/Mock/TestClient.cs b/OpenSim/Tests/Common/Mock/TestClient.cs index 5d7349a..f7220d7 100644 --- a/OpenSim/Tests/Common/Mock/TestClient.cs +++ b/OpenSim/Tests/Common/Mock/TestClient.cs | |||
@@ -1256,7 +1256,7 @@ namespace OpenSim.Tests.Common.Mock | |||
1256 | { | 1256 | { |
1257 | } | 1257 | } |
1258 | 1258 | ||
1259 | public void StopFlying(ISceneEntity presence) | 1259 | public void SendAgentTerseUpdate(ISceneEntity presence) |
1260 | { | 1260 | { |
1261 | } | 1261 | } |
1262 | 1262 | ||