return has_melee_weapon(creature_ptr, INVEN_LARM);
}
-void have_two_handed_weapons(player_type *creature_ptr)
+bool have_two_handed_weapons(player_type *creature_ptr)
{
- creature_ptr->two_handed_weapon = FALSE;
if (can_two_hands_wielding(creature_ptr)) {
if (creature_ptr->right_hand_weapon && (empty_hands(creature_ptr, FALSE) == EMPTY_HAND_LARM)
&& object_allow_two_hands_wielding(&creature_ptr->inventory_list[INVEN_RARM])) {
- creature_ptr->two_handed_weapon = TRUE;
+ return TRUE;
} else if (creature_ptr->left_hand_weapon && (empty_hands(creature_ptr, FALSE) == EMPTY_HAND_RARM)
&& object_allow_two_hands_wielding(&creature_ptr->inventory_list[INVEN_LARM])) {
- creature_ptr->two_handed_weapon = TRUE;
+ return TRUE;
}
}
+ return FALSE;
}
void have_lite(player_type *creature_ptr)
void have_immune_cold(player_type *creature_ptr);
bool have_right_hand_weapon(player_type *creature_ptr);
bool have_left_hand_weapon(player_type *creature_ptr);
-void have_two_handed_weapons(player_type *creature_ptr);
+bool have_two_handed_weapons(player_type *creature_ptr);
void have_lite(player_type *creature_ptr);
bool is_disable_two_handed_bonus(player_type *creature_ptr, int i);
bool is_not_ninja_weapon(player_type *creature_ptr, int i);
creature_ptr->right_hand_weapon = have_right_hand_weapon(creature_ptr);
creature_ptr->left_hand_weapon = have_left_hand_weapon(creature_ptr);
- have_two_handed_weapons(creature_ptr);
+ creature_ptr->two_handed_weapon = have_two_handed_weapons(creature_ptr);
creature_ptr->hold = calc_weapon_weight_limit(creature_ptr);
creature_ptr->pass_wall = have_pass_wall(creature_ptr);