Lines Matching refs:current_effect

494     for( const weather_effect &current_effect : w->effects ) {  in handle_weather_effects()  local
495 if( current_effect.must_be_outside && !is_creature_outside( player_character ) ) { in handle_weather_effects()
498 if( current_effect.time_between > 0_seconds && in handle_weather_effects()
499 !calendar::once_every( current_effect.time_between ) ) { in handle_weather_effects()
502 if( !one_in( current_effect.one_in_chance ) ) { in handle_weather_effects()
505 if( current_effect.lightning && here.get_abs_sub().z >= 0 ) { in handle_weather_effects()
508 if( current_effect.rain_proof ) { in handle_weather_effects()
532 if( player_character.get_pain() >= current_effect.pain_max ) { in handle_weather_effects()
536 bool spawned = current_effect.spawns.empty(); in handle_weather_effects()
537 for( const spawn_type &spawn : current_effect.spawns ) { in handle_weather_effects()
575 for( const weather_field &field : current_effect.fields ) { in handle_weather_effects()
582 if( current_effect.effect_id.is_valid() ) { in handle_weather_effects()
583 if( current_effect.target_part.is_valid() ) { in handle_weather_effects()
584 … player_character.add_effect( current_effect.effect_id, current_effect.effect_duration, in handle_weather_effects()
585 current_effect.target_part ); in handle_weather_effects()
587 … player_character.add_effect( current_effect.effect_id, current_effect.effect_duration ); in handle_weather_effects()
590 if( current_effect.trait_id_to_add.is_valid() ) { in handle_weather_effects()
591 player_character.set_mutation( current_effect.trait_id_to_add ); in handle_weather_effects()
593 if( current_effect.trait_id_to_remove.is_valid() ) { in handle_weather_effects()
594 player_character.unset_mutation( current_effect.trait_id_to_remove ); in handle_weather_effects()
596 if( current_effect.damage.has_value() ) { in handle_weather_effects()
597 if( current_effect.target_part.is_valid() ) { in handle_weather_effects()
598 …player_character.deal_damage( nullptr, current_effect.target_part, current_effect.damage.value() ); in handle_weather_effects()
601 player_character.deal_damage( nullptr, bp, current_effect.damage.value() ); in handle_weather_effects()
605 player_character.mod_healthy( current_effect.healthy ); in handle_weather_effects()
606 player_character.mod_rad( current_effect.radiation ); in handle_weather_effects()
607 wet( player_character, current_effect.wet ); in handle_weather_effects()
608 player_character.mod_pain( current_effect.pain ); in handle_weather_effects()
609 weather_sound( current_effect.sound_message, current_effect.sound_effect ); in handle_weather_effects()
610 player_character.add_msg_if_player( current_effect.message ); in handle_weather_effects()