OSDN Git Service

refactor a_m_aux2
[hengband/hengband.git] / src / do-spell.c
index 44945e6..aa07aa3 100644 (file)
@@ -11136,17 +11136,17 @@ static cptr do_hissatsu_spell(int spell, int mode)
                if (cast)
                {
                        const int mana_cost_per_monster = 8;
-                       bool new = TRUE;
+                       bool is_new = TRUE;
                        bool mdeath;
 
                        do
                        {
                                if (!rush_attack(&mdeath)) break;
-                               if (new)
+                               if (is_new)
                                {
                                        /* Reserve needed mana point */
                                        p_ptr->csp -= technic_info[REALM_HISSATSU - MIN_TECHNIC][26].smana;
-                                       new = FALSE;
+                                       is_new = FALSE;
                                }
                                else
                                        p_ptr->csp -= mana_cost_per_monster;
@@ -11159,7 +11159,7 @@ static cptr do_hissatsu_spell(int spell, int mode)
                        }
                        while (p_ptr->csp > mana_cost_per_monster);
 
-                       if (new) return NULL;
+                       if (is_new) return NULL;
        
                        /* Restore reserved mana */
                        p_ptr->csp += technic_info[REALM_HISSATSU - MIN_TECHNIC][26].smana;
@@ -11427,7 +11427,6 @@ static cptr do_hex_spell(int spell, int mode)
        bool desc = (mode == SPELL_DESC) ? TRUE : FALSE;
        bool info = (mode == SPELL_INFO) ? TRUE : FALSE;
        bool cast = (mode == SPELL_CAST) ? TRUE : FALSE;
-       bool fail = (mode == SPELL_FAIL) ? TRUE : FALSE;
        bool cont = (mode == SPELL_CONT) ? TRUE : FALSE;
        bool stop = (mode == SPELL_STOP) ? TRUE : FALSE;
 
@@ -11566,7 +11565,7 @@ static cptr do_hex_spell(int spell, int mode)
                if (cast)
                {
                        int item;
-                       char *q, *s;
+                       cptr q, s;
                        char o_name[MAX_NLEN];
                        object_type *o_ptr;
                        u32b f[TR_FLAG_SIZE];
@@ -12032,7 +12031,7 @@ static cptr do_hex_spell(int spell, int mode)
                if (cast)
                {
                        int item;
-                       char *q, *s;
+                       cptr q, s;
                        char o_name[MAX_NLEN];
                        object_type *o_ptr;
                        u32b f[TR_FLAG_SIZE];
@@ -12329,7 +12328,7 @@ static cptr do_hex_spell(int spell, int mode)
                if (cast)
                {
                        int item;
-                       char *s, *q;
+                       cptr s, q;
                        u32b f[TR_FLAG_SIZE];
                        object_type *o_ptr;