diff options
-rw-r--r-- | crawl-ref/source/item_use.cc | 2 | ||||
-rw-r--r-- | crawl-ref/source/player.cc | 6 | ||||
-rw-r--r-- | crawl-ref/source/player.h | 1 | ||||
-rw-r--r-- | crawl-ref/source/spl-cast.cc | 2 |
4 files changed, 2 insertions, 9 deletions
diff --git a/crawl-ref/source/item_use.cc b/crawl-ref/source/item_use.cc index 8b9b0ec052..7868fc939f 100644 --- a/crawl-ref/source/item_use.cc +++ b/crawl-ref/source/item_use.cc @@ -429,7 +429,7 @@ void warn_shield_penalties() return; // Warnings are limited to rods, bows, and quarterstaves at the moment. - const item_def *weapon = player_weapon(); + const item_def *weapon = you.weapon(); if (!weapon) return; diff --git a/crawl-ref/source/player.cc b/crawl-ref/source/player.cc index cf5193c2b0..53fb6991db 100644 --- a/crawl-ref/source/player.cc +++ b/crawl-ref/source/player.cc @@ -732,12 +732,6 @@ bool you_tran_can_wear(int eq, bool check_mutation) return (true); } -// Returns the item in the player's weapon slot. -item_def *player_weapon() -{ - return (you.weapon()); -} - bool player_weapon_wielded() { const int wpn = you.equip[EQ_WEAPON]; diff --git a/crawl-ref/source/player.h b/crawl-ref/source/player.h index 6b8068fb0e..5b9a321a4a 100644 --- a/crawl-ref/source/player.h +++ b/crawl-ref/source/player.h @@ -742,7 +742,6 @@ bool disease_player(int amount); void dec_disease_player(); bool player_weapon_wielded(); -item_def *player_weapon(); // Determines if the given grid is dangerous for the player to enter. bool is_feat_dangerous(dungeon_feature_type feat); diff --git a/crawl-ref/source/spl-cast.cc b/crawl-ref/source/spl-cast.cc index 262026415e..b67846757c 100644 --- a/crawl-ref/source/spl-cast.cc +++ b/crawl-ref/source/spl-cast.cc @@ -70,7 +70,7 @@ static bool _surge_identify_boosters(spell_type spell) // Must not be wielding an unIDed staff. // Note that robes of the Archmagi identify on wearing, // so that's less of an issue. - const item_def* wpn = player_weapon(); + const item_def* wpn = you.weapon(); if (wpn == NULL || wpn->base_type != OBJ_STAVES || item_ident(*wpn, ISFLAG_KNOW_PROPERTIES)) |