aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--ChangeLog.txt8
-rw-r--r--linden/indra/newview/llnetmap.cpp20
-rw-r--r--linden/indra/newview/llworldmapview.cpp20
-rw-r--r--linden/indra/newview/skins/default/colors_base.xml1
-rw-r--r--linden/indra/newview/skins/silver/colors_base.xml1
5 files changed, 46 insertions, 4 deletions
diff --git a/ChangeLog.txt b/ChangeLog.txt
index 387d390..5155acb 100644
--- a/ChangeLog.txt
+++ b/ChangeLog.txt
@@ -25,6 +25,14 @@
25 modified: linden/indra/newview/llnetmap.cpp 25 modified: linden/indra/newview/llnetmap.cpp
26 modified: linden/indra/newview/skins/default/xui/en-us/panel_mini_map.xml 26 modified: linden/indra/newview/skins/default/xui/en-us/panel_mini_map.xml
27 27
28
29 * Show muted avatars as grey in the mini-map.
30
31 modified: linden/indra/newview/llnetmap.cpp
32 modified: linden/indra/newview/llworldmapview.cpp
33 modified: linden/indra/newview/skins/default/colors_base.xml
34 modified: linden/indra/newview/skins/silver/colors_base.xml
35
28 36
292009-06-12 McCabe Maxsted <hakushakukun@gmail.com> 372009-06-12 McCabe Maxsted <hakushakukun@gmail.com>
30 38
diff --git a/linden/indra/newview/llnetmap.cpp b/linden/indra/newview/llnetmap.cpp
index 999a2fe..35982c8 100644
--- a/linden/indra/newview/llnetmap.cpp
+++ b/linden/indra/newview/llnetmap.cpp
@@ -47,6 +47,7 @@
47#include "llfloateravatarinfo.h" 47#include "llfloateravatarinfo.h"
48#include "llfloaterworldmap.h" 48#include "llfloaterworldmap.h"
49#include "llframetimer.h" 49#include "llframetimer.h"
50#include "llmutelist.h"
50#include "lltracker.h" 51#include "lltracker.h"
51#include "llmenugl.h" 52#include "llmenugl.h"
52#include "llsurface.h" 53#include "llsurface.h"
@@ -327,6 +328,9 @@ void LLNetMap::draw()
327 // Draw avatars 328 // Draw avatars
328 LLColor4 avatar_color = gColors.getColor( "MapAvatar" ); 329 LLColor4 avatar_color = gColors.getColor( "MapAvatar" );
329 LLColor4 friend_color = gColors.getColor( "MapFriend" ); 330 LLColor4 friend_color = gColors.getColor( "MapFriend" );
331 LLColor4 muted_color = gColors.getColor( "MapMuted" );
332 LLColor4 glyph_color;
333
330 std::vector<LLUUID> avatar_ids; 334 std::vector<LLUUID> avatar_ids;
331 std::vector<LLVector3d> positions; 335 std::vector<LLVector3d> positions;
332 LLWorld::getInstance()->getAvatars(&avatar_ids, &positions); 336 LLWorld::getInstance()->getAvatars(&avatar_ids, &positions);
@@ -336,9 +340,23 @@ void LLNetMap::draw()
336 // just be careful to sort the avatar IDs along with the positions. -MG 340 // just be careful to sort the avatar IDs along with the positions. -MG
337 pos_map = globalPosToView(positions[i], rotate_map); 341 pos_map = globalPosToView(positions[i], rotate_map);
338 342
343 // Show them muted even if they're friends
344 if (LLMuteList::getInstance()->isMuted(avatar_ids[i]))
345 {
346 glyph_color = muted_color;
347 }
348 else if (is_agent_friend(avatar_ids[i]))
349 {
350 glyph_color = friend_color;
351 }
352 else
353 {
354 glyph_color = avatar_color;
355 }
356
339 LLWorldMapView::drawAvatar( 357 LLWorldMapView::drawAvatar(
340 pos_map.mV[VX], pos_map.mV[VY], 358 pos_map.mV[VX], pos_map.mV[VY],
341 is_agent_friend(avatar_ids[i]) ? friend_color : avatar_color, 359 glyph_color,
342 pos_map.mV[VZ]); 360 pos_map.mV[VZ]);
343 361
344 F32 dist_to_cursor = dist_vec(LLVector2(pos_map.mV[VX], pos_map.mV[VY]), LLVector2(local_mouse_x,local_mouse_y)); 362 F32 dist_to_cursor = dist_vec(LLVector2(pos_map.mV[VX], pos_map.mV[VY]), LLVector2(local_mouse_x,local_mouse_y));
diff --git a/linden/indra/newview/llworldmapview.cpp b/linden/indra/newview/llworldmapview.cpp
index 73c2d8b..b6f75bc 100644
--- a/linden/indra/newview/llworldmapview.cpp
+++ b/linden/indra/newview/llworldmapview.cpp
@@ -49,6 +49,7 @@
49#include "llfloatermap.h" 49#include "llfloatermap.h"
50#include "llfloaterworldmap.h" 50#include "llfloaterworldmap.h"
51#include "llfocusmgr.h" 51#include "llfocusmgr.h"
52//#include "llmutelist.h" info not being sent
52#include "lltextbox.h" 53#include "lltextbox.h"
53#include "lltextureview.h" 54#include "lltextureview.h"
54#include "lltracker.h" 55#include "lltracker.h"
@@ -866,7 +867,9 @@ void LLWorldMapView::drawAgents()
866 F32 agents_scale = (gMapScale * 0.9f) / 256.f; 867 F32 agents_scale = (gMapScale * 0.9f) / 256.f;
867 868
868 LLColor4 avatar_color = gColors.getColor( "MapAvatar" ); 869 LLColor4 avatar_color = gColors.getColor( "MapAvatar" );
869 LLColor4 friend_color = gColors.getColor( "MapFriend" ); 870 /*LLColor4 friend_color = gColors.getColor( "MapFriend" );
871 LLColor4 muted_color = gColors.getColor( "MapMuted" );
872 LLColor4 glyph_color;*/
870 873
871 for (handle_list_t::iterator iter = mVisibleRegions.begin(); iter != mVisibleRegions.end(); ++iter) 874 for (handle_list_t::iterator iter = mVisibleRegions.begin(); iter != mVisibleRegions.end(); ++iter)
872 { 875 {
@@ -889,7 +892,18 @@ void LLWorldMapView::drawAgents()
889 S32 agent_count = info.mExtra; 892 S32 agent_count = info.mExtra;
890 sim_agent_count += info.mExtra; 893 sim_agent_count += info.mExtra;
891 // Here's how we'd choose the color if info.mID were available but it's not being sent: 894 // Here's how we'd choose the color if info.mID were available but it's not being sent:
892 //LLColor4 color = (agent_count == 1 && is_agent_friend(info.mID)) ? friend_color : avatar_color; 895 /*if (agent_count == 1 && LLMuteList::getInstance()->isMuted(info.mID))
896 {
897 glyph_color = muted_color;
898 }
899 else if (agent_count == 1 && is_agent_friend(info.mID))
900 {
901 glyph_color = friend_color;
902 }
903 else
904 {
905 glyph_color = avatar_color;
906 }*/
893 drawImageStack(info.mPosGlobal, sAvatarSmallImage, agent_count, 3.f, avatar_color); 907 drawImageStack(info.mPosGlobal, sAvatarSmallImage, agent_count, 3.f, avatar_color);
894 } 908 }
895 LLWorldMap::getInstance()->mNumAgents[handle] = sim_agent_count; // override mNumAgents for this sim 909 LLWorldMap::getInstance()->mNumAgents[handle] = sim_agent_count; // override mNumAgents for this sim
@@ -905,7 +919,7 @@ void LLWorldMapView::drawAgents()
905 region_center[VY] += REGION_WIDTH_METERS / 2; 919 region_center[VY] += REGION_WIDTH_METERS / 2;
906 // Reduce the stack size as you zoom out - always display at lease one agent where there is one or more 920 // Reduce the stack size as you zoom out - always display at lease one agent where there is one or more
907 S32 agent_count = (S32)(((num_agents-1) * agents_scale + (num_agents-1) * 0.1f)+.1f) + 1; 921 S32 agent_count = (S32)(((num_agents-1) * agents_scale + (num_agents-1) * 0.1f)+.1f) + 1;
908 drawImageStack(region_center, sAvatarSmallImage, agent_count, 3.f, glyph_color_avatar); 922 drawImageStack(region_center, sAvatarSmallImage, agent_count, 3.f, avatar_color);
909 } 923 }
910 } 924 }
911 } 925 }
diff --git a/linden/indra/newview/skins/default/colors_base.xml b/linden/indra/newview/skins/default/colors_base.xml
index 1f97a2e..42cb0ac 100644
--- a/linden/indra/newview/skins/default/colors_base.xml
+++ b/linden/indra/newview/skins/default/colors_base.xml
@@ -159,6 +159,7 @@
159<!-- MAP --> 159<!-- MAP -->
160<MapAvatar value="0, 255, 0, 255" /> <!-- Your avatar's glyph color --> 160<MapAvatar value="0, 255, 0, 255" /> <!-- Your avatar's glyph color -->
161<MapFriend value="255, 255, 0, 255" /> <!-- Your friends' glyph color --> 161<MapFriend value="255, 255, 0, 255" /> <!-- Your friends' glyph color -->
162<MapMuted value="128, 128, 128, 255" /> <!-- Muted avatars' glyph color -->
162 163
163 <!-- MINI-MAP --> 164 <!-- MINI-MAP -->
164<NetMapBackgroundColor value="0, 0, 0, 77" /> <!-- Mini-map floater background --> 165<NetMapBackgroundColor value="0, 0, 0, 77" /> <!-- Mini-map floater background -->
diff --git a/linden/indra/newview/skins/silver/colors_base.xml b/linden/indra/newview/skins/silver/colors_base.xml
index 9ec721c..a69f43f 100644
--- a/linden/indra/newview/skins/silver/colors_base.xml
+++ b/linden/indra/newview/skins/silver/colors_base.xml
@@ -159,6 +159,7 @@
159<!-- MAP --> 159<!-- MAP -->
160<MapAvatar value="0, 255, 0, 255" /> <!-- Your avatar's glyph color --> 160<MapAvatar value="0, 255, 0, 255" /> <!-- Your avatar's glyph color -->
161<MapFriend value="255, 255, 0, 255" /> <!-- Your friends' glyph color --> 161<MapFriend value="255, 255, 0, 255" /> <!-- Your friends' glyph color -->
162<MapMuted value="128, 128, 128, 255" /> <!-- Muted avatars' glyph color -->
162 163
163<!-- MINI-MAP --> 164<!-- MINI-MAP -->
164<NetMapBackgroundColor value="0, 0, 0, 77" /> <!-- Mini-map floater background --> 165<NetMapBackgroundColor value="0, 0, 0, 77" /> <!-- Mini-map floater background -->