diff options
author | Melanie | 2011-05-09 18:37:35 +0100 |
---|---|---|
committer | Melanie | 2011-05-09 18:37:35 +0100 |
commit | 1bd949614a927f32b7194ecefaeb74fdd46cab4f (patch) | |
tree | 8974bd63062468b776c2a8de31d3de5a8ff3ea69 /OpenSim | |
parent | Merge branch 'master' into careminster-presence-refactor (diff) | |
parent | Fixes gray tiles on map search for viewers 1. (diff) | |
download | opensim-SC-1bd949614a927f32b7194ecefaeb74fdd46cab4f.zip opensim-SC-1bd949614a927f32b7194ecefaeb74fdd46cab4f.tar.gz opensim-SC-1bd949614a927f32b7194ecefaeb74fdd46cab4f.tar.bz2 opensim-SC-1bd949614a927f32b7194ecefaeb74fdd46cab4f.tar.xz |
Merge branch 'master' into careminster-presence-refactor
Diffstat (limited to 'OpenSim')
4 files changed, 14 insertions, 10 deletions
diff --git a/OpenSim/Framework/IClientAPI.cs b/OpenSim/Framework/IClientAPI.cs index f187468..3cf5f32 100644 --- a/OpenSim/Framework/IClientAPI.cs +++ b/OpenSim/Framework/IClientAPI.cs | |||
@@ -77,7 +77,7 @@ namespace OpenSim.Framework | |||
77 | 77 | ||
78 | public delegate void RequestMapBlocks(IClientAPI remoteClient, int minX, int minY, int maxX, int maxY, uint flag); | 78 | public delegate void RequestMapBlocks(IClientAPI remoteClient, int minX, int minY, int maxX, int maxY, uint flag); |
79 | 79 | ||
80 | public delegate void RequestMapName(IClientAPI remoteClient, string mapName); | 80 | public delegate void RequestMapName(IClientAPI remoteClient, string mapName, uint flags); |
81 | 81 | ||
82 | public delegate void TeleportLocationRequest( | 82 | public delegate void TeleportLocationRequest( |
83 | IClientAPI remoteClient, ulong regionHandle, Vector3 position, Vector3 lookAt, uint flags); | 83 | IClientAPI remoteClient, ulong regionHandle, Vector3 position, Vector3 lookAt, uint flags); |
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs index 0eafc69..de40abd 100644 --- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs | |||
@@ -1370,7 +1370,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
1370 | 1370 | ||
1371 | public void SendMapBlock(List<MapBlockData> mapBlocks, uint flag) | 1371 | public void SendMapBlock(List<MapBlockData> mapBlocks, uint flag) |
1372 | { | 1372 | { |
1373 | |||
1374 | MapBlockData[] mapBlocks2 = mapBlocks.ToArray(); | 1373 | MapBlockData[] mapBlocks2 = mapBlocks.ToArray(); |
1375 | 1374 | ||
1376 | int maxsend = 10; | 1375 | int maxsend = 10; |
@@ -8320,13 +8319,12 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
8320 | return true; | 8319 | return true; |
8321 | } | 8320 | } |
8322 | #endregion | 8321 | #endregion |
8323 | |||
8324 | string mapName = Util.UTF8.GetString(map.NameData.Name, 0, | 8322 | string mapName = Util.UTF8.GetString(map.NameData.Name, 0, |
8325 | map.NameData.Name.Length - 1); | 8323 | map.NameData.Name.Length - 1); |
8326 | RequestMapName handlerMapNameRequest = OnMapNameRequest; | 8324 | RequestMapName handlerMapNameRequest = OnMapNameRequest; |
8327 | if (handlerMapNameRequest != null) | 8325 | if (handlerMapNameRequest != null) |
8328 | { | 8326 | { |
8329 | handlerMapNameRequest(this, mapName); | 8327 | handlerMapNameRequest(this, mapName, map.AgentData.Flags); |
8330 | } | 8328 | } |
8331 | return true; | 8329 | return true; |
8332 | } | 8330 | } |
diff --git a/OpenSim/Region/CoreModules/World/WorldMap/MapSearchModule.cs b/OpenSim/Region/CoreModules/World/WorldMap/MapSearchModule.cs index d0aa53e..56c59bd 100644 --- a/OpenSim/Region/CoreModules/World/WorldMap/MapSearchModule.cs +++ b/OpenSim/Region/CoreModules/World/WorldMap/MapSearchModule.cs | |||
@@ -84,7 +84,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
84 | client.OnMapNameRequest += OnMapNameRequest; | 84 | client.OnMapNameRequest += OnMapNameRequest; |
85 | } | 85 | } |
86 | 86 | ||
87 | private void OnMapNameRequest(IClientAPI remoteClient, string mapName) | 87 | private void OnMapNameRequest(IClientAPI remoteClient, string mapName, uint flags) |
88 | { | 88 | { |
89 | if (mapName.Length < 2) | 89 | if (mapName.Length < 2) |
90 | { | 90 | { |
@@ -117,7 +117,10 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
117 | data = new MapBlockData(); | 117 | data = new MapBlockData(); |
118 | data.Agents = 0; | 118 | data.Agents = 0; |
119 | data.Access = info.Access; | 119 | data.Access = info.Access; |
120 | data.MapImageId = UUID.Zero; // could use info.TerrainImage but it seems to break viewer2 | 120 | if (flags == 2) // V2 sends this |
121 | data.MapImageId = UUID.Zero; | ||
122 | else | ||
123 | data.MapImageId = info.TerrainImage; | ||
121 | data.Name = info.RegionName; | 124 | data.Name = info.RegionName; |
122 | data.RegionFlags = 0; // TODO not used? | 125 | data.RegionFlags = 0; // TODO not used? |
123 | data.WaterHeight = 0; // not used | 126 | data.WaterHeight = 0; // not used |
@@ -139,7 +142,9 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
139 | data.Y = 0; | 142 | data.Y = 0; |
140 | blocks.Add(data); | 143 | blocks.Add(data); |
141 | 144 | ||
142 | remoteClient.SendMapBlock(blocks, 2); | 145 | // flags are agent flags sent from the viewer. |
146 | // they have different values depending on different viewers, apparently | ||
147 | remoteClient.SendMapBlock(blocks, flags); | ||
143 | } | 148 | } |
144 | 149 | ||
145 | // private Scene GetClientScene(IClientAPI client) | 150 | // private Scene GetClientScene(IClientAPI client) |
diff --git a/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs b/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs index b05aef8..fe919b7 100644 --- a/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs +++ b/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs | |||
@@ -205,8 +205,8 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
205 | { | 205 | { |
206 | //try | 206 | //try |
207 | //{ | 207 | //{ |
208 | //m_log.DebugFormat("[MAPLAYER]: request: {0}, path: {1}, param: {2}, agent:{3}", | 208 | //m_log.DebugFormat("[MAPLAYER]: path: {0}, param: {1}, agent:{2}", |
209 | //request, path, param,agentID.ToString()); | 209 | // path, param, agentID.ToString()); |
210 | 210 | ||
211 | // this is here because CAPS map requests work even beyond the 10,000 limit. | 211 | // this is here because CAPS map requests work even beyond the 10,000 limit. |
212 | ScenePresence avatarPresence = null; | 212 | ScenePresence avatarPresence = null; |
@@ -784,7 +784,8 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
784 | /// <param name="maxY"></param> | 784 | /// <param name="maxY"></param> |
785 | public virtual void RequestMapBlocks(IClientAPI remoteClient, int minX, int minY, int maxX, int maxY, uint flag) | 785 | public virtual void RequestMapBlocks(IClientAPI remoteClient, int minX, int minY, int maxX, int maxY, uint flag) |
786 | { | 786 | { |
787 | if ((flag & 0x10000) != 0) // user clicked on the map a tile that isn't visible | 787 | //m_log.ErrorFormat("[YYY] RequestMapBlocks {0}={1}={2}={3} {4}", minX, minY, maxX, maxY, flag); |
788 | if ((flag & 0x10000) != 0) // user clicked on qthe map a tile that isn't visible | ||
788 | { | 789 | { |
789 | List<MapBlockData> response = new List<MapBlockData>(); | 790 | List<MapBlockData> response = new List<MapBlockData>(); |
790 | 791 | ||