OSDN Git Service

[Refactor] #37353 コメント整理。 / Refactor comments.
[hengband/hengband.git] / src / cmd-item.c
index e30b8d3..56b4bf4 100644 (file)
@@ -23,6 +23,7 @@
 
 #include "object-hook.h"
 #include "sort.h"
+#include "quest.h"
 
 
 /*!
@@ -1259,17 +1260,14 @@ void do_cmd_look(void)
  */
 void do_cmd_locate(void)
 {
-       int             dir, y1, x1, y2, x2;
-
-       char    tmp_val[80];
-
-       char    out_val[160];
-
-       int wid, hgt;
+       DIRECTION dir;
+       POSITION y1, x1, y2, x2;
+       GAME_TEXT tmp_val[80];
+       GAME_TEXT out_val[160];
+       TERM_LEN wid, hgt;
 
        get_screen_size(&wid, &hgt);
 
-
        /* Start at current panel */
        y2 = y1 = panel_row_min;
        x2 = x1 = panel_col_min;
@@ -1302,8 +1300,8 @@ void do_cmd_locate(void)
                }
 
                /* Prepare to ask which way to look */
-               sprintf(out_val, _("マップ位置 [%d(%02d),%d(%02d)] (プレイヤーの%s)  方向?", 
-                                              "Map sector [%d(%02d),%d(%02d)], which is%s your sector.  Direction?"),
+               sprintf(out_val, _("マップ位置 [%ld(%02ld),%ld(%02ld)] (プレイヤーの%s)  方向?", 
+                                              "Map sector [%ld(%02ld),%ld(%02ld)], which is%s your sector.  Direction?"),
                        y2 / (hgt / 2), y2 % (hgt / 2),
                        x2 / (wid / 2), x2 % (wid / 2), tmp_val);
 
@@ -1341,9 +1339,7 @@ void do_cmd_locate(void)
        verify_panel();
 
        p_ptr->update |= (PU_MONSTERS);
-
        p_ptr->redraw |= (PR_MAP);
-
        p_ptr->window |= (PW_OVERHEAD | PW_DUNGEON);
        handle_stuff();
 }
@@ -1364,7 +1360,6 @@ void do_cmd_locate(void)
 bool ang_sort_comp_hook(vptr u, vptr v, int a, int b)
 {
        u16b *who = (u16b*)(u);
-
        u16b *why = (u16b*)(v);
 
        int w1 = who[a];
@@ -1546,7 +1541,7 @@ void do_cmd_query_symbol(void)
        prt(buf, 0, 0);
 
        /* Allocate the "who" array */
-       C_MAKE(who, max_r_idx, IDX);
+       C_MAKE(who, max_r_idx, MONRACE_IDX);
 
        /* Collect matching monsters */
        for (n = 0, i = 1; i < max_r_idx; i++)
@@ -1844,7 +1839,7 @@ void do_cmd_use(void)
                case TV_ARROW:
                case TV_BOLT:
                {
-                       do_cmd_fire_aux(item, &inventory[INVEN_BOW]);
+                       exe_fire(item, &inventory[INVEN_BOW]);
                        break;
                }