Integrate some effects to true_healing().
case ACT_CURING:
{
msg_format(_("%sの優しさに癒される...", "the %s cures you affectionately ..."), name);
- (void)set_poisoned(0);
- (void)set_confused(0);
- (void)set_blind(0);
- (void)set_stun(0);
- (void)set_cut(0);
- (void)set_image(0);
-
+ true_healing(0);
break;
}
break;\r
\r
case SV_POTION_CURING:\r
- if (hp_player(50)) ident = TRUE;\r
- if (set_blind(0)) ident = TRUE;\r
- if (set_poisoned(0)) ident = TRUE;\r
- if (set_confused(0)) ident = TRUE;\r
- if (set_stun(0)) ident = TRUE;\r
- if (set_cut(0)) ident = TRUE;\r
- if (set_image(0)) ident = TRUE;\r
+ if (true_healing(50)) ident = TRUE;\r
break;\r
\r
case SV_POTION_INVULNERABILITY:\r
\r
case SV_STAFF_CURING:\r
{\r
- if (set_blind(0)) ident = TRUE;\r
- if (set_poisoned(0)) ident = TRUE;\r
- if (set_confused(0)) ident = TRUE;\r
- if (set_stun(0)) ident = TRUE;\r
- if (set_cut(0)) ident = TRUE;\r
- if (set_image(0)) ident = TRUE;\r
+ ident = true_healing(0);\r
if (set_shero(0, TRUE)) ident = TRUE;\r
break;\r
}\r
\r
case SV_STAFF_HEALING:\r
{\r
- if (hp_player(powerful ? 500 : 300)) ident = TRUE;\r
- if (set_stun(0)) ident = TRUE;\r
- if (set_cut(0)) ident = TRUE;\r
- if (set_shero(0, TRUE)) ident = TRUE;\r
+ if (cure_critical_wounds(powerful ? 500 : 300)) ident = TRUE;\r
break;\r
}\r
\r
case SV_ROD_CURING:
{
- if (set_blind(0)) ident = TRUE;
- if (set_poisoned(0)) ident = TRUE;
- if (set_confused(0)) ident = TRUE;
- if (set_stun(0)) ident = TRUE;
- if (set_cut(0)) ident = TRUE;
- if (set_image(0)) ident = TRUE;
+ if (true_healing(0)) ident = TRUE;
if (set_shero(0, TRUE)) ident = TRUE;
break;
}
{
int vir;
vir = virtue_number(V_VITALITY);
- if (vir)
+
+ if(num <= 0) return (FALSE);
+
+ if(vir)
{
num = num * (p_ptr->virtues[vir - 1] + 1250) / 1250;
}
extern bool_hack cure_light_wounds(int dice, int sides);
extern bool_hack cure_serious_wounds(int dice, int sides);
extern bool_hack cure_critical_wounds(HIT_POINT pow);
+extern bool_hack true_healing(HIT_POINT pow);
extern bool_hack restore_mana(bool_hack magic_eater);
extern bool restore_all_status(void);
{
msg_print(_("あなたは「パターン」を心に描いてその上を歩いた...", "You picture the Pattern in your mind and walk it..."));
- (void)set_poisoned(0);
- (void)set_image(0);
- (void)set_stun(0);
- (void)set_cut(0);
- (void)set_blind(0);
- (void)set_afraid(0);
+ (void)true_healing(0);
(void)restore_all_status();
(void)restore_level();
}
{\r
if (cast)\r
{\r
- set_poisoned(0);\r
- set_stun(0);\r
- set_cut(0);\r
- set_image(0);\r
+ (void)true_healing(0);\r
}\r
}\r
break;\r
return ident;
}
+bool_hack true_healing(HIT_POINT pow)
+{
+ bool_hack ident = FALSE;
+ if (hp_player(pow)) ident = TRUE;
+ if (set_blind(0)) ident = TRUE;
+ if (set_confused(0)) ident = TRUE;
+ if (set_poisoned(0)) ident = TRUE;
+ if (set_stun(0)) ident = TRUE;
+ if (set_cut(0)) ident = TRUE;
+ if (set_image(0)) ident = TRUE;
+ return ident;
+}
+
bool_hack restore_mana(bool_hack magic_eater)
{
bool_hack ident = FALSE;
*/
static void do_cmd_wiz_cure_all(void)
{
- /* Restore stats */
- (void)res_stat(A_STR);
- (void)res_stat(A_INT);
- (void)res_stat(A_WIS);
- (void)res_stat(A_CON);
- (void)res_stat(A_DEX);
- (void)res_stat(A_CHR);
-
- /* Restore the level */
- (void)restore_level();
-
- /* Heal the player */
- if (p_ptr->chp < p_ptr->mhp)
- {
- p_ptr->chp = p_ptr->mhp;
- p_ptr->chp_frac = 0;
-
- /* Redraw */
- p_ptr->redraw |= (PR_HP);
-
- /* Window stuff */
- p_ptr->window |= (PW_PLAYER);
- }
-
- /* Restore mana */
- if (p_ptr->csp < p_ptr->msp)
- {
- p_ptr->csp = p_ptr->msp;
- p_ptr->csp_frac = 0;
-
- p_ptr->redraw |= (PR_MANA);
- p_ptr->window |= (PW_PLAYER);
- p_ptr->window |= (PW_SPELL);
- }
-
- /* Cure stuff */
- (void)set_blind(0);
- (void)set_confused(0);
- (void)set_poisoned(0);
- (void)set_afraid(0);
- (void)set_paralyzed(0);
- (void)set_image(0);
- (void)set_stun(0);
- (void)set_cut(0);
- (void)set_slow(0, TRUE);
-
- /* No longer hungry */
+ (void)life_stream(FALSE, FALSE);
(void)set_food(PY_FOOD_MAX - 1);
}
case REW_HEAL_FUL:
msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[p_ptr->chaos_patron]);
- restore_level();
- (void)set_poisoned(0);
- (void)set_blind(0);
- (void)set_confused(0);
- (void)set_image(0);
- (void)set_stun(0);
- (void)set_cut(0);
- hp_player(5000);
- for (dummy = 0; dummy < 6; dummy++)
- {
- (void)do_res_stat(dummy);
- }
+ (void)restore_level();
+ (void)restore_all_status();
+ (void)true_healing(5000);
reward = _("体力が回復した。", "healing");
break;