OSDN Git Service

[Refactor] #37353 生命領域処理を cmd-spell.c から realm-life.c/h へ分離。
[hengband/hengband.git] / src / mind.c
index 2dd7f21..b5ecca8 100644 (file)
@@ -402,7 +402,7 @@ static cptr const mind_tips[5][MAX_MIND_POWERS] =
        "1体のモンスターと位置を交換する。",
        "自分のいる床の上に、モンスターが通ると爆発してダメージを与えるルーンを描く。",
        "一定時間、半物質化し壁を通り抜けられるようになる。さらに、一定時間酸への耐性を得る。装備による耐性に累積する。",
-       "自分を中心とした超巨大な毒、生命力吸収、混乱の球を発生させ、テレポートする。",
+       "自分を中心とした超巨大な毒、衰弱、混乱の球を発生させ、テレポートする。",
        "ランダムな方向に何回か炎か地獄かプラズマのビームを放つ。",
        "全ての攻撃が、1/2の確率で無効になる。",
        "",
@@ -420,7 +420,7 @@ static cptr const mind_tips[5][MAX_MIND_POWERS] =
        "Generate a ball centered on you which inflict monster with PSI damage. Or inflict all monsters with PSI damage at level 25.",
        "Removes fear and stun. Gives heroism and speed. Heals HP a little unless you already have heroism and temporal speed boost.",
        "Pulls a distant item close to you.",
-       "Fires a ball which damages monsters and absorbs monsters' mind power. Absorbing is takes more turns which from 0 to 1.5.",
+       "Fires a ball which damages, co. Absorbing is takes more turns which from 0 to 1.5.",
        "Fires a beam of pure energy which penetrate the invulnerability barrier.",
        "Stops time. Consumes all of your SP. The more consumes SP, the longer duration of spell.",
        "",
@@ -589,7 +589,7 @@ void mindcraft_info(char *p, int use_mind, int power)
                case 4:  sprintf(p, " %s%d+d20", s_dur, 20 + boost / 5); break;
                case 5:  break;
                case 6:  sprintf(p, " %s%d+d%d", s_dur, 15 + boost / 7, plev / 2); break;
-               case 7:  sprintf(p, " %s%dd8", s_dam, 8 + ((plev - 5) / 5) + boost / 12); break;
+               case 7:  sprintf(p, " %s%dd8", s_dam, 8 + ((plev - 5) / 4) + boost / 12); break;
                case 8:  sprintf(p, " %s10d6+%d", s_dam, plev * 3 / 2 + boost * 3 / 5); break;
                case 9:  break;
                case 10: sprintf(p, _(" 最大%d体", " max %d"), 1+boost/100); break;
@@ -675,9 +675,9 @@ void mindcraft_info(char *p, int use_mind, int power)
  * when you run it. It's probably easy to fix but I haven't tried,\n
  * sorry.\n
  */
-static int get_mind_power(COMMAND_CODE *sn, bool only_browse)
+static bool_hack get_mind_power(SPELL_IDX *sn, bool only_browse)
 {
-       COMMAND_CODE i;
+       SPELL_IDX i;
        int             num = 0;
        int             y = 1;
        int             x = 10;
@@ -689,7 +689,7 @@ static int get_mind_power(COMMAND_CODE *sn, bool only_browse)
        char            out_val[160];
        char            comment[80];
        cptr            p;
-
+       COMMAND_CODE code;
        mind_type       spell;
        const mind_power      *mind_ptr;
        bool            flag, redraw;
@@ -743,10 +743,13 @@ static int get_mind_power(COMMAND_CODE *sn, bool only_browse)
 #ifdef ALLOW_REPEAT /* TNB */
 
        /* Get the spell, if available */
-       if (repeat_pull(sn))
+
+       if (repeat_pull(&code))
        {
+               *sn = (SPELL_IDX)code;
                /* Hack -- If requested INVEN_FORCE(1111), pull again */
-               if (*sn == INVEN_FORCE) repeat_pull(sn);
+               if (*sn == INVEN_FORCE) repeat_pull(&code);
+               *sn = (SPELL_IDX)code;
 
                /* Verify the spell */
                if (mind_ptr->info[*sn].min_lev <= plev)
@@ -934,7 +937,7 @@ put_str(format("Lv   %s   Fail Info", ((use_mind == MIND_BERSERKER) || (use_mind
                                                else strcpy(psi_desc, "     ");
                                        }
                                        else
-                                               sprintf(psi_desc, "  %c) ",I2A(i));
+                                               sprintf(psi_desc, "  %c) ", I2A(i));
                                        /* Dump the spell --(-- */
                                        strcat(psi_desc,
                                               format("%-30s%2d %4d%s %3d%%%s",
@@ -1021,7 +1024,7 @@ put_str(format("Lv   %s   Fail Info", ((use_mind == MIND_BERSERKER) || (use_mind
 
 #ifdef ALLOW_REPEAT /* TNB */
 
-       repeat_push(*sn);
+       repeat_push((COMMAND_CODE)i);
 
 #endif /* ALLOW_REPEAT -- TNB */
 
@@ -1735,7 +1738,7 @@ static bool cast_ninja_spell(int spell)
                        }
 
                        /* Gives a multiplier of 2 at first, up to 3 at 40th */
-                       do_cmd_throw_aux(1, FALSE, slot);
+                       do_cmd_throw(1, FALSE, slot);
 
                        p_ptr->energy_use = 100;
                }
@@ -1836,7 +1839,7 @@ static bool cast_ninja_spell(int spell)
                break;
        case 17:
                fire_ball(GF_POIS, 0, 75+plev*2/3, plev/5+2);
-               fire_ball(GF_OLD_DRAIN, 0, 75+plev*2/3, plev/5+2);
+               fire_ball(GF_HYPODYNAMIA, 0, 75+plev*2/3, plev/5+2);
                fire_ball(GF_CONFUSION, 0, 75+plev*2/3, plev/5+2);
                teleport_player(30, 0L);
                break;