return result;
}
-void has_sh_fire(player_type *creature_ptr)
+BIT_FLAGS has_sh_fire(player_type *creature_ptr)
{
- object_type *o_ptr;
- BIT_FLAGS flgs[TR_FLAG_SIZE];
- creature_ptr->sh_fire = FALSE;
+ BIT_FLAGS result = 0L;
if (creature_ptr->muta3 & MUT3_FIRE_BODY) {
- creature_ptr->sh_fire = TRUE;
+ result |= FLAG_CAUSE_MUTATION;
}
if (creature_ptr->mimic_form == MIMIC_DEMON_LORD) {
- creature_ptr->sh_fire = TRUE;
- }
-
- if (creature_ptr->realm1 == REALM_HEX) {
- if (hex_spelling(creature_ptr, HEX_DEMON_AURA)) {
- creature_ptr->sh_fire = TRUE;
- }
- }
-
- if (creature_ptr->special_defense & KAMAE_SEIRYU) {
- creature_ptr->sh_fire = TRUE;
+ result |= FLAG_CAUSE_RACE;
}
- if (creature_ptr->ult_res || (creature_ptr->special_defense & KATA_MUSOU)) {
- creature_ptr->sh_fire = TRUE;
+ if (creature_ptr->special_defense & KAMAE_SEIRYU || creature_ptr->special_defense & KATA_MUSOU) {
+ result |= FLAG_CAUSE_BATTLE_FORM;
}
- if (creature_ptr->tim_sh_fire) {
- creature_ptr->sh_fire = TRUE;
+ if (hex_spelling(creature_ptr, HEX_DEMON_AURA) || creature_ptr->ult_res || creature_ptr->tim_sh_fire) {
+ result |= FLAG_CAUSE_MAGIC_TIME_EFFECT;
}
- for (inventory_slot_type i = INVEN_RARM; i < INVEN_TOTAL; i++) {
- o_ptr = &creature_ptr->inventory_list[i];
- if (!o_ptr->k_idx)
- continue;
-
- object_flags(creature_ptr, o_ptr, flgs);
- if (has_flag(flgs, TR_SH_FIRE))
- creature_ptr->sh_fire = TRUE;
- }
+ result |= check_equipment_flags(creature_ptr, TR_SH_FIRE);
+ return result;
}
BIT_FLAGS has_sh_elec(player_type *creature_ptr)
void has_warning(player_type *creature_ptr);
BIT_FLAGS has_anti_magic(player_type *creature_ptr);
BIT_FLAGS has_anti_tele(player_type *creature_ptr);
-void has_sh_fire(player_type *creature_ptr);
+BIT_FLAGS has_sh_fire(player_type *creature_ptr);
BIT_FLAGS has_sh_elec(player_type *creature_ptr);
void has_sh_cold(player_type *creature_ptr);
BIT_FLAGS has_easy_spell(player_type *creature_ptr);
has_warning(creature_ptr);
creature_ptr->anti_magic = has_anti_magic(creature_ptr);
creature_ptr->anti_tele = has_anti_tele(creature_ptr);
- has_sh_fire(creature_ptr);
+ creature_ptr->sh_fire = has_sh_fire(creature_ptr);
creature_ptr->sh_elec = has_sh_elec(creature_ptr);
has_sh_cold(creature_ptr);
creature_ptr->easy_spell = has_easy_spell(creature_ptr);
bool resist_water; /* Resist water */
BIT_FLAGS reflect; /* Reflect 'bolt' attacks */
- bool sh_fire; /* Fiery 'immolation' effect */
+ BIT_FLAGS sh_fire; /* Fiery 'immolation' effect */
BIT_FLAGS sh_elec; /* Electric 'immolation' effect */
bool sh_cold; /* Cold 'immolation' effect */