Skip to content

Commit

Permalink
Merge pull request CleverRaven#74739 from PeterJacobson337/fix_npc_cr…
Browse files Browse the repository at this point in the history
…aft_text

Fix NPC crafting message
  • Loading branch information
Maleclypse authored Jun 24, 2024
2 parents d10245b + 217b3fe commit 3b97827
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions src/crafting.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1523,9 +1523,17 @@ void Character::complete_craft( item &craft, const std::optional<tripoint> &loc
if( !making.is_practice() && ( !newits.empty() || !making.result_eocs.empty() ) ) {
// TODO: reconsider recipe memorization
if( knows_recipe( &making ) ) {
add_msg( _( "You craft %s from memory." ), making.result_name() );
if( is_avatar() ) {
add_msg( _( "You craft %s from memory." ), making.result_name() );
} else {
add_msg( _( "%1s crafts %2s from memory." ), get_name(), making.result_name() );
}
} else {
add_msg( _( "You craft %s using a reference." ), making.result_name() );
if( is_avatar() ) {
add_msg( _( "You craft %s using a reference." ), making.result_name() );
} else {
add_msg( _( "%1s crafts %2s using a reference." ), get_name(), making.result_name() );
}
// If we made it, but we don't know it, we're using a book, device or NPC
// as a reference and have a chance to learn it.
// Base expected time to learn is 1000*(difficulty^4)/skill/int moves.
Expand Down

0 comments on commit 3b97827

Please sign in to comment.