Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
Standing-Storm authored Dec 4, 2024
1 parent 04cb3d9 commit 9969366
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions src/mutation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -562,6 +562,13 @@ void Character::mutation_effect( const trait_id &mut, const bool worn_destroyed_
}

remove_worn_items_with( [&]( item & armor ) {
// Check for exceptions first
if( armor.has_flag( STATIC( flag_id( "OVERSIZE" ) ) ) ) {
return false;
}
if( armor.has_flag( STATIC( flag_id( "INTEGRATED" ) ) ) ) {
return false;
}
// initial check for rigid items to pull off, doesn't matter what else the item has you can only wear one rigid item
if( branch.conflicts_with_item_rigid( armor ) ) {
add_msg_player_or_npc( m_bad,
Expand All @@ -571,12 +578,6 @@ void Character::mutation_effect( const trait_id &mut, const bool worn_destroyed_
get_map().add_item_or_charges( pos_bub(), armor );
return true;
}
if( armor.has_flag( STATIC( flag_id( "OVERSIZE" ) ) ) ) {
return false;
}
if( armor.has_flag( STATIC( flag_id( "INTEGRATED" ) ) ) ) {
return false;
}
if( !branch.conflicts_with_item( armor ) ) {
return false;
}
Expand Down

0 comments on commit 9969366

Please sign in to comment.