diff --git a/src/crafting.cpp b/src/crafting.cpp index 73ec104e115e4..1120fb39bf6d2 100644 --- a/src/crafting.cpp +++ b/src/crafting.cpp @@ -297,9 +297,9 @@ float Character::workbench_crafting_speed_multiplier( const item &craft, float Character::crafting_speed_multiplier( const recipe &rec ) const { - const float limb_score = ( rec.has_flag( flag_NO_MANIP ) ) ? 1.0f : get_limb_score( + const float limb_score = rec.has_flag( flag_NO_MANIP ) ? 1.0f : get_limb_score( limb_score_manip ); - const float pain_multi = ( rec.has_flag( flag_AFFECTED_BY_PAIN ) ) ? std::max( 0.0f, + const float pain_multi = rec.has_flag( flag_AFFECTED_BY_PAIN ) ? std::max( 0.0f, 1.0f - ( get_perceived_pain() / 100.0f ) ) : 1.0f; float crafting_speed = morale_crafting_speed_multiplier( rec ) * @@ -333,9 +333,9 @@ float Character::crafting_speed_multiplier( const item &craft, const float morale_multi = morale_crafting_speed_multiplier( rec ); const float mut_multi = 1.0 + enchantment_cache->get_value_multiply( enchant_vals::mod::CRAFTING_SPEED_MULTIPLIER ); - const float limb_score = ( rec.has_flag( flag_NO_MANIP ) ) ? 1.0f : get_limb_score( + const float limb_score = rec.has_flag( flag_NO_MANIP ) ? 1.0f : get_limb_score( limb_score_manip ); - const float pain_multi = ( rec.has_flag( flag_AFFECTED_BY_PAIN ) ) ? std::max( 0.0f, + const float pain_multi = rec.has_flag( flag_AFFECTED_BY_PAIN ) ? std::max( 0.0f, 1.0f - ( get_perceived_pain() / 100.0f ) ) : 1.0f ; const float total_multi = light_multi * bench_multi * morale_multi * mut_multi * limb_score * diff --git a/src/crafting_gui.cpp b/src/crafting_gui.cpp index 5585b9502ada1..e86a6b14e720e 100644 --- a/src/crafting_gui.cpp +++ b/src/crafting_gui.cpp @@ -2280,9 +2280,9 @@ static void draw_can_craft_indicator( const catacurses::window &w, const recipe } else if( crafter.crafting_speed_multiplier( rec ) < 1.0f ) { int morale_modifier = crafter.morale_crafting_speed_multiplier( rec ) * 100; int lighting_modifier = crafter.lighting_craft_speed_multiplier( rec ) * 100; - int limb_modifier = ( rec.has_flag( flag_NO_MANIP ) ) ? 100 : crafter.get_limb_score( + int limb_modifier = rec.has_flag( flag_NO_MANIP ) ? 100 : crafter.get_limb_score( limb_score_manip ) * 100; - int pain_multi = ( rec.has_flag( flag_AFFECTED_BY_PAIN ) ) ? 100 * std::max( 0.0f, + int pain_multi = rec.has_flag( flag_AFFECTED_BY_PAIN ) ? 100 * std::max( 0.0f, 1.0f - ( crafter.get_perceived_pain() / 100.0f ) ) : 100; std::stringstream modifiers_list;