do_cmd_rerate(FALSE);
get_max_stats();
p_ptr->update |= PU_BONUS;
- if (p_ptr->muta1 || p_ptr->muta2 || p_ptr->muta3)
- {
- chg_virtue(V_CHANCE, -5);
- msg_print(_("全ての突然変異が治った。", "You are cured of all mutations."));
- p_ptr->muta1 = p_ptr->muta2 = p_ptr->muta3 = 0;
- p_ptr->update |= PU_BONUS;
- handle_stuff();
- mutant_regenerate_mod = calc_mutant_regenerate_mod();
- }
+ lose_all_mutations();
ident = TRUE;
break;
case SV_POTION_POLYMORPH:
if ((p_ptr->muta1 || p_ptr->muta2 || p_ptr->muta3) && one_in_(23))
{
- chg_virtue(V_CHANCE, -5);
- msg_print(_("全ての突然変異が治った。", "You are cured of all mutations."));
- p_ptr->muta1 = p_ptr->muta2 = p_ptr->muta3 = 0;
- p_ptr->update |= PU_BONUS;
- handle_stuff();
+ lose_all_mutations();
}
else
{
{
msg_print(_("《審判》だ。", "It's the Judgement."));
do_cmd_rerate(FALSE);
- if (p_ptr->muta1 || p_ptr->muta2 || p_ptr->muta3)
- {
- msg_print(_("全ての突然変異が治った。", "You are cured of all mutations."));
- p_ptr->muta1 = p_ptr->muta2 = p_ptr->muta3 = 0;
- p_ptr->update |= PU_BONUS;
- handle_stuff();
- }
+ lose_all_mutations();
}
else if (die < 120)
{
extern int count_bits(BIT_FLAGS x);
extern bool gain_random_mutation(int choose_mut);
extern bool lose_mutation(int choose_mut);
+extern void lose_all_mutations(void);
extern void dump_mutations(FILE *OutFile);
extern void do_cmd_knowledge_mutations(void);
extern int calc_mutant_regenerate_mod(void);
}
}
+void lose_all_mutations(void)
+{
+ if (p_ptr->muta1 || p_ptr->muta2 || p_ptr->muta3)
+ {
+ chg_virtue(V_CHANCE, -5);
+ msg_print(_("全ての突然変異が治った。", "You are cured of all mutations."));
+ p_ptr->muta1 = p_ptr->muta2 = p_ptr->muta3 = 0;
+ p_ptr->update |= PU_BONUS;
+ handle_stuff();
+ mutant_regenerate_mod = calc_mutant_regenerate_mod();
+ }
+}
+
/*!
* @brief ファイルポインタを通じて突然変異の一覧を出力する
* @param OutFile 出力先ファイルポインタ