diff options
-rw-r--r-- | crawl-ref/docs/crawl_options.txt | 8 | ||||
-rw-r--r-- | crawl-ref/init.txt | 1 | ||||
-rw-r--r-- | crawl-ref/source/direct.cc | 2 | ||||
-rw-r--r-- | crawl-ref/source/externs.h | 1 | ||||
-rw-r--r-- | crawl-ref/source/initfile.cc | 5 | ||||
-rw-r--r-- | crawl-ref/source/invent.cc | 8 | ||||
-rw-r--r-- | crawl-ref/source/religion.cc | 5 | ||||
-rw-r--r-- | crawl-ref/source/view.cc | 2 |
8 files changed, 24 insertions, 8 deletions
diff --git a/crawl-ref/docs/crawl_options.txt b/crawl-ref/docs/crawl_options.txt index 3a99b7559d..24bafe145b 100644 --- a/crawl-ref/docs/crawl_options.txt +++ b/crawl-ref/docs/crawl_options.txt @@ -56,7 +56,7 @@ The contents of this text are: hp_warning, mp_warning, hp_colour, mp_colour, always_greet, terse_hand, delay_message_clear, menu_colour, message_colour, increasing_skill_progress, show_inventory_weights, - show_turns, item_stack_summary_minimum + show_turns, show_beam, item_stack_summary_minimum 4-k Missiles. fire_items_start, fire_order 4-l Message Channels. @@ -966,6 +966,12 @@ show_turns = false This option controls whether the turn counter (of turns elapsed) is displayed in the main view. +show_beam = false + When performing actions such as throwing or zapping, you can toggle + whether to show the beam path or not. This option controls the + initial status of this toggle. When set to true, the path will be + shown. + item_stack_summary_minimum = 5 If you step over a stack with this number or more of items in it, the first description line will contain a summary of all the diff --git a/crawl-ref/init.txt b/crawl-ref/init.txt index 3921212d7b..c1664cde39 100644 --- a/crawl-ref/init.txt +++ b/crawl-ref/init.txt @@ -174,6 +174,7 @@ stab_brand = hi:blue # increasing_skill_progress = false # show_inventory_weights = true # show_turns = true +# show_beam = true # item_stack_summary_minimum = 500 # Colouring for the inventory diff --git a/crawl-ref/source/direct.cc b/crawl-ref/source/direct.cc index ac30c963af..ae23bd7c8e 100644 --- a/crawl-ref/source/direct.cc +++ b/crawl-ref/source/direct.cc @@ -271,7 +271,7 @@ void direction(dist& moves, targeting_type restricts, cursor_control con(!Options.use_fake_cursor); int dir = 0; - bool show_beam = false; + bool show_beam = Options.show_beam; ray_def ray; FixedVector < char, 2 > objfind_pos; diff --git a/crawl-ref/source/externs.h b/crawl-ref/source/externs.h index b93b613304..33b92cd3c1 100644 --- a/crawl-ref/source/externs.h +++ b/crawl-ref/source/externs.h @@ -1656,6 +1656,7 @@ public: bool show_more_prompt; bool show_turns; // Show turns used in HUD. + bool show_beam; // Show targeting beam by default. long autopickups; // items to autopickup bool show_inventory_weights; // show weights in inventory listings diff --git a/crawl-ref/source/initfile.cc b/crawl-ref/source/initfile.cc index bed5a7e9ea..7aee2eaa4c 100644 --- a/crawl-ref/source/initfile.cc +++ b/crawl-ref/source/initfile.cc @@ -560,6 +560,7 @@ void game_options::reset_options() show_more_prompt = true; show_turns = false; + show_beam = false; prev_race = 0; prev_cls = 0; @@ -1886,6 +1887,10 @@ void game_options::read_option_line(const std::string &str, bool runscript) { show_turns = read_bool( field, show_turns ); } + else if (key == "show_beam") + { + show_beam = read_bool( field, show_beam ); + } #ifndef SAVE_DIR_PATH else if (key == "morgue_dir") { diff --git a/crawl-ref/source/invent.cc b/crawl-ref/source/invent.cc index c835984358..74a2a74bab 100644 --- a/crawl-ref/source/invent.cc +++ b/crawl-ref/source/invent.cc @@ -1024,11 +1024,15 @@ static bool check_old_item_warning( const item_def& item, } else if (oper == OPER_WEAR) // can we safely take off old item? { + if (item.base_type != OBJ_ARMOUR) + return (true); + equipment_type eq_slot = get_armour_slot(item); - if (item.base_type != OBJ_ARMOUR || you.equip[eq_slot] == -1) + if (you.equip[eq_slot] == -1) return (true); - + old_item = you.inv[you.equip[eq_slot]]; + if (!has_warning_inscription(old_item, OPER_TAKEOFF)) return (true); diff --git a/crawl-ref/source/religion.cc b/crawl-ref/source/religion.cc index 0e35447c6e..00de2c7425 100644 --- a/crawl-ref/source/religion.cc +++ b/crawl-ref/source/religion.cc @@ -756,8 +756,7 @@ void pray() const god_type altar_god = grid_altar_god(grd[you.x_pos][you.y_pos]); if (altar_god != GOD_NO_GOD) { - if (player_is_levitating() - && !wearing_amulet(AMU_CONTROLLED_FLIGHT)) + if (you.flies() == FL_LEVITATE) { mpr("You are floating high above the altar."); return; @@ -2881,7 +2880,7 @@ void god_pitch(god_type which_god) snprintf( info, INFO_SIZE, "Do you wish to %sjoin this religion?", (you.worshipped[which_god]) ? "re" : "" ); - if (!yesno( info ) || !yesno("Are you sure?")) + if (!yesno( info, false, 'n' ) || !yesno("Are you sure?", false, 'n')) { redraw_screen(); return; diff --git a/crawl-ref/source/view.cc b/crawl-ref/source/view.cc index 6a22de3464..62d5fea95f 100644 --- a/crawl-ref/source/view.cc +++ b/crawl-ref/source/view.cc @@ -1044,6 +1044,7 @@ void fire_monster_alerts() || mons_was_seen_this_turn(monster)) && !mons_is_submerged( monster )) { + learn_visible_mon_eq_egos(monster); if (!mons_is_safe( static_cast<const monsters*>(monster) ) && !mons_class_flag( monster->type, M_NO_EXP_GAIN ) && !mons_is_mimic( monster->type )) @@ -1051,7 +1052,6 @@ void fire_monster_alerts() interrupt_activity( AI_SEE_MONSTER, monster ); } seen_monster( monster ); - learn_visible_mon_eq_egos(monster); // Monster was viewed this turn monster->flags |= MF_WAS_IN_VIEW; |