diff options
-rw-r--r-- | OpenSim/Region/Framework/Scenes/ScenePresence.cs | 78 |
1 files changed, 50 insertions, 28 deletions
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index 4d5f747..19fd542 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs | |||
@@ -4845,17 +4845,24 @@ namespace OpenSim.Region.Framework.Scenes | |||
4845 | 4845 | ||
4846 | int nparts = j; | 4846 | int nparts = j; |
4847 | 4847 | ||
4848 | bool priv = sog.HasPrivateAttachmentPoint; | 4848 | ControllingClient.SendEntityUpdate(rootpart, rootflag); |
4849 | |||
4850 | for (int i = 0; i < nparts; i++) | ||
4851 | { | ||
4852 | ControllingClient.SendEntityUpdate(parts[i], flags[i]); | ||
4853 | } | ||
4854 | |||
4855 | if (sog.HasPrivateAttachmentPoint) | ||
4856 | return; | ||
4849 | 4857 | ||
4850 | List<ScenePresence> allPresences = m_scene.GetScenePresences(); | 4858 | List<ScenePresence> allPresences = m_scene.GetScenePresences(); |
4851 | foreach (ScenePresence p in allPresences) | 4859 | foreach (ScenePresence p in allPresences) |
4852 | { | 4860 | { |
4853 | if (p != this) | 4861 | if (p == this) |
4854 | { | 4862 | continue; |
4855 | if (priv || | 4863 | |
4856 | (ParcelHideThisAvatar && currentParcelUUID != p.currentParcelUUID && p.GodLevel < 200)) | 4864 | if (ParcelHideThisAvatar && currentParcelUUID != p.currentParcelUUID && p.GodLevel < 200) |
4857 | continue; | 4865 | continue; |
4858 | } | ||
4859 | 4866 | ||
4860 | p.ControllingClient.SendEntityUpdate(rootpart, rootflag); | 4867 | p.ControllingClient.SendEntityUpdate(rootpart, rootflag); |
4861 | 4868 | ||
@@ -4892,17 +4899,29 @@ namespace OpenSim.Region.Framework.Scenes | |||
4892 | 4899 | ||
4893 | rootpart.UpdateFlag = 0; | 4900 | rootpart.UpdateFlag = 0; |
4894 | 4901 | ||
4895 | bool priv = sog.HasPrivateAttachmentPoint; | 4902 | ControllingClient.SendEntityUpdate(rootpart, flag); |
4903 | |||
4904 | for (int i = 0; i < parts.Length; i++) | ||
4905 | { | ||
4906 | SceneObjectPart part = parts[i]; | ||
4907 | if (part == rootpart) | ||
4908 | continue; | ||
4909 | ControllingClient.SendEntityUpdate(part, flag); | ||
4910 | part.UpdateFlag = 0; | ||
4911 | } | ||
4912 | |||
4913 | if (sog.HasPrivateAttachmentPoint) | ||
4914 | return; | ||
4915 | |||
4896 | 4916 | ||
4897 | List<ScenePresence> allPresences = m_scene.GetScenePresences(); | 4917 | List<ScenePresence> allPresences = m_scene.GetScenePresences(); |
4898 | foreach (ScenePresence p in allPresences) | 4918 | foreach (ScenePresence p in allPresences) |
4899 | { | 4919 | { |
4900 | if (p != this) | 4920 | if (p == this) |
4901 | { | 4921 | continue; |
4902 | if (priv || | 4922 | |
4903 | (ParcelHideThisAvatar && currentParcelUUID != p.currentParcelUUID && p.GodLevel < 200)) | 4923 | if (ParcelHideThisAvatar && currentParcelUUID != p.currentParcelUUID && p.GodLevel < 200) |
4904 | continue; | 4924 | continue; |
4905 | } | ||
4906 | 4925 | ||
4907 | p.ControllingClient.SendEntityUpdate(rootpart, flag); | 4926 | p.ControllingClient.SendEntityUpdate(rootpart, flag); |
4908 | 4927 | ||
@@ -4941,23 +4960,25 @@ namespace OpenSim.Region.Framework.Scenes | |||
4941 | 4960 | ||
4942 | part.UpdateFlag = 0; | 4961 | part.UpdateFlag = 0; |
4943 | 4962 | ||
4944 | bool priv = part.ParentGroup.HasPrivateAttachmentPoint; | 4963 | ControllingClient.SendEntityUpdate(part, flag); |
4964 | |||
4965 | if (part.ParentGroup.HasPrivateAttachmentPoint) | ||
4966 | return; | ||
4945 | 4967 | ||
4946 | List<ScenePresence> allPresences = m_scene.GetScenePresences(); | 4968 | List<ScenePresence> allPresences = m_scene.GetScenePresences(); |
4947 | foreach (ScenePresence p in allPresences) | 4969 | foreach (ScenePresence p in allPresences) |
4948 | { | 4970 | { |
4949 | if (p != this) | 4971 | if (p == this) |
4950 | { | 4972 | continue; |
4951 | 4973 | ||
4952 | if (priv || | 4974 | if (ParcelHideThisAvatar && currentParcelUUID != p.currentParcelUUID && p.GodLevel < 200) |
4953 | (ParcelHideThisAvatar && currentParcelUUID != p.currentParcelUUID && p.GodLevel < 200)) | 4975 | continue; |
4954 | continue; | ||
4955 | } | ||
4956 | 4976 | ||
4957 | p.ControllingClient.SendEntityUpdate(part, flag); | 4977 | p.ControllingClient.SendEntityUpdate(part, flag); |
4958 | } | 4978 | } |
4959 | } | 4979 | } |
4960 | 4980 | ||
4981 | |||
4961 | public void SendAttachmentUpdate(SceneObjectPart part, UpdateRequired UpdateFlag) | 4982 | public void SendAttachmentUpdate(SceneObjectPart part, UpdateRequired UpdateFlag) |
4962 | { | 4983 | { |
4963 | if (IsChildAgent || IsInTransit) | 4984 | if (IsChildAgent || IsInTransit) |
@@ -4981,17 +5002,18 @@ namespace OpenSim.Region.Framework.Scenes | |||
4981 | 5002 | ||
4982 | part.UpdateFlag = 0; | 5003 | part.UpdateFlag = 0; |
4983 | 5004 | ||
4984 | bool priv = part.ParentGroup.HasPrivateAttachmentPoint; | 5005 | ControllingClient.SendEntityUpdate(part, flag); |
5006 | |||
5007 | if (part.ParentGroup.HasPrivateAttachmentPoint) | ||
5008 | return; | ||
4985 | 5009 | ||
4986 | List<ScenePresence> allPresences = m_scene.GetScenePresences(); | 5010 | List<ScenePresence> allPresences = m_scene.GetScenePresences(); |
4987 | foreach (ScenePresence p in allPresences) | 5011 | foreach (ScenePresence p in allPresences) |
4988 | { | 5012 | { |
4989 | if (p != this) | 5013 | if (p == this) |
4990 | { | 5014 | continue; |
4991 | if ( priv || | 5015 | if (ParcelHideThisAvatar && currentParcelUUID != p.currentParcelUUID && p.GodLevel < 200) |
4992 | (ParcelHideThisAvatar && currentParcelUUID != p.currentParcelUUID && p.GodLevel < 200)) | 5016 | continue; |
4993 | continue; | ||
4994 | } | ||
4995 | 5017 | ||
4996 | p.ControllingClient.SendEntityUpdate(part, flag); | 5018 | p.ControllingClient.SendEntityUpdate(part, flag); |
4997 | } | 5019 | } |