From d6697da62b9cd881b23f3942b26bdf294b9f3515 Mon Sep 17 00:00:00 2001 From: Johanna Ploog Date: Wed, 6 Jan 2010 23:43:29 +0100 Subject: New minimap colour option for peaceful monsters, by default same as friendly. --- crawl-ref/docs/options_guide.txt | 6 ++++-- crawl-ref/settings/tiles_options.txt | 41 ++++++++++++++++++------------------ crawl-ref/source/enum.h | 15 +++++++------ crawl-ref/source/initfile.cc | 1 + crawl-ref/source/options.h | 1 + crawl-ref/source/tilereg.cc | 3 ++- crawl-ref/source/tilesdl.cc | 2 ++ 7 files changed, 39 insertions(+), 30 deletions(-) diff --git a/crawl-ref/docs/options_guide.txt b/crawl-ref/docs/options_guide.txt index d71c797c87..9e016d982a 100644 --- a/crawl-ref/docs/options_guide.txt +++ b/crawl-ref/docs/options_guide.txt @@ -89,8 +89,8 @@ The contents of this text are: 4-o Tiles Options. tile_show_items, tile_title_screen, tile_menu_icons, tile_player_col, tile_monster_col, tile_neutral_col, - tile_friendly_col, tile_plant_col, tile_item_col, - tile_unseen_col, tile_floor_col, tile_wall_col, + tile_peaceful_col, tile_friendly_col, tile_plant_col, + tile_item_col, tile_unseen_col, tile_floor_col, tile_wall_col, tile_mapped_wall_col, tile_door_col, tile_downstairs_col, tile_upstairs_col, tile_feature_col, tile_trap_col, tile_water_col, tile_lava_col, tile_excluded_col, @@ -1653,6 +1653,7 @@ tile_menu_icons = true tile_player_col = white tile_monster_col = red tile_neutral_col = red +tile_peaceful_col = lightred tile_friendly_col = lightred tile_plant_col = darkgreen tile_item_col = green @@ -1677,6 +1678,7 @@ the dungeon level. map centre during level map mode ('X') tile_monster_col - colour of hostile monsters tile_neutral_col - colour of neutral monsters + tile_peaceful_col - colour of peaceful monsters tile_friendly_col - colour of friendly monsters tile_plant_col - colour of zero xp monsters (plant and fungus) tile_item_col - colour of known or detected items diff --git a/crawl-ref/settings/tiles_options.txt b/crawl-ref/settings/tiles_options.txt index b9439a3049..2062cc41eb 100644 --- a/crawl-ref/settings/tiles_options.txt +++ b/crawl-ref/settings/tiles_options.txt @@ -9,26 +9,27 @@ ### The following lines define the colours of various objects within the ### tiles minimap. See options_guide.txt for more details. -# tile_player_col = white -# tile_monster_col = red -# tile_neutral_col = red -# tile_friendly_col = lightred -# tile_plant_col = darkgreen -# tile_item_col = green -# tile_unseen_col = black -# tile_floor_col = lightgrey -# tile_wall_col = darkgrey -# tile_mapped_wall_col = blue -# tile_door_col = brown -# tile_downstairs_col = magenta -# tile_upstairs_col = blue -# tile_feature_col = cyan -# tile_trap_col = yellow -# tile_water_col = grey -# tile_lava_col = grey -# tile_excluded_col = darkcyan -# tile_excl_centre = darkblue -# tile_window_col = yellow +# tile_player_col = white +# tile_monster_col = red +# tile_neutral_col = red +# tile_peaceful_col = lightred +# tile_friendly_col = lightred +# tile_plant_col = darkgreen +# tile_item_col = green +# tile_unseen_col = black +# tile_floor_col = lightgrey +# tile_wall_col = darkgrey +# tile_mapped_wall_col = blue +# tile_door_col = brown +# tile_downstairs_col = magenta +# tile_upstairs_col = blue +# tile_feature_col = cyan +# tile_trap_col = yellow +# tile_water_col = grey +# tile_lava_col = grey +# tile_excluded_col = darkcyan +# tile_excl_centre = darkblue +# tile_window_col = yellow # If Crawl's response rate is too slow, try increasing the update rate. # tile_update_rate = 1000 diff --git a/crawl-ref/source/enum.h b/crawl-ref/source/enum.h index e29eb1d3e1..20afad48f0 100644 --- a/crawl-ref/source/enum.h +++ b/crawl-ref/source/enum.h @@ -1555,23 +1555,24 @@ enum map_feature MF_MAP_WALL, MF_DOOR, // 5 MF_ITEM, - MF_MONS_HOSTILE, MF_MONS_FRIENDLY, + MF_MONS_PEACEFUL, MF_MONS_NEUTRAL, - MF_MONS_NO_EXP, // 10 + MF_MONS_HOSTILE, // 10 + MF_MONS_NO_EXP, MF_STAIR_UP, MF_STAIR_DOWN, MF_STAIR_BRANCH, - MF_FEATURE, - MF_WATER, // 15 + MF_FEATURE, // 15 + MF_WATER, MF_LAVA, MF_TRAP, MF_EXCL_ROOT, - MF_EXCL, - MF_PLAYER, // 20 + MF_EXCL, // 20 + MF_PLAYER, MF_MAX, - MF_SKIP // 22 + MF_SKIP // 23 }; enum menu_type diff --git a/crawl-ref/source/initfile.cc b/crawl-ref/source/initfile.cc index 506e49c56e..c3208c425b 100644 --- a/crawl-ref/source/initfile.cc +++ b/crawl-ref/source/initfile.cc @@ -858,6 +858,7 @@ void game_options::reset_options() tile_player_col = MAP_WHITE; tile_monster_col = MAP_RED; tile_neutral_col = MAP_RED; + tile_peaceful_col = MAP_LTRED; tile_friendly_col = MAP_LTRED; tile_plant_col = MAP_DKGREEN; tile_item_col = MAP_GREEN; diff --git a/crawl-ref/source/options.h b/crawl-ref/source/options.h index b8d331c0cf..2480c78a24 100644 --- a/crawl-ref/source/options.h +++ b/crawl-ref/source/options.h @@ -330,6 +330,7 @@ public: char tile_player_col; char tile_monster_col; char tile_neutral_col; + char tile_peaceful_col; char tile_friendly_col; char tile_plant_col; char tile_item_col; diff --git a/crawl-ref/source/tilereg.cc b/crawl-ref/source/tilereg.cc index 87d9e20508..14161323e3 100644 --- a/crawl-ref/source/tilereg.cc +++ b/crawl-ref/source/tilereg.cc @@ -2947,9 +2947,10 @@ void MapRegion::init_colours() m_colours[MF_MAP_WALL] = (map_colour)Options.tile_mapped_wall_col; m_colours[MF_DOOR] = (map_colour)Options.tile_door_col; m_colours[MF_ITEM] = (map_colour)Options.tile_item_col; - m_colours[MF_MONS_HOSTILE] = (map_colour)Options.tile_monster_col; m_colours[MF_MONS_FRIENDLY] = (map_colour)Options.tile_friendly_col; + m_colours[MF_MONS_PEACEFUL] = (map_colour)Options.tile_peaceful_col; m_colours[MF_MONS_NEUTRAL] = (map_colour)Options.tile_neutral_col; + m_colours[MF_MONS_HOSTILE] = (map_colour)Options.tile_monster_col; m_colours[MF_MONS_NO_EXP] = (map_colour)Options.tile_plant_col; m_colours[MF_STAIR_UP] = (map_colour)Options.tile_upstairs_col; m_colours[MF_STAIR_DOWN] = (map_colour)Options.tile_downstairs_col; diff --git a/crawl-ref/source/tilesdl.cc b/crawl-ref/source/tilesdl.cc index 002a19e86e..45bd2d161d 100644 --- a/crawl-ref/source/tilesdl.cc +++ b/crawl-ref/source/tilesdl.cc @@ -1348,6 +1348,8 @@ void TilesFramework::update_minimap(int gx, int gy, map_feature f) const monsters *mon = monster_at(gc); if (mon->friendly()) f = MF_MONS_FRIENDLY; + else if (mon->good_neutral()) + f = MF_MONS_PEACEFUL; else if (mon->neutral()) f = MF_MONS_NEUTRAL; else if (mons_class_flag(mon->type, M_NO_EXP_GAIN)) -- cgit v1.2.3-54-g00ecf