OSDN Git Service

[Refactor] #37353 コメント整理 / Refactor comments.
[hengband/hengband.git] / src / object1.c
index 7c5bf90..d697108 100644 (file)
@@ -1237,7 +1237,6 @@ bool screen_object(object_type *o_ptr, BIT_FLAGS mode)
        /* Save the screen */
        screen_save();
 
-       /* Get size */
        Term_get_size(&wid, &hgt);
 
        /* Display Item name */
@@ -1662,7 +1661,6 @@ void display_inven(void)
        char            o_name[MAX_NLEN];
        int             wid, hgt;
 
-       /* Get size */
        Term_get_size(&wid, &hgt);
 
        /* Find the "final" slot */
@@ -1758,7 +1756,6 @@ void display_equip(void)
        char            o_name[MAX_NLEN];
        int             wid, hgt;
 
-       /* Get size */
        Term_get_size(&wid, &hgt);
 
        /* Display the equipment */
@@ -2159,7 +2156,6 @@ COMMAND_CODE show_inven(int target_item)
        /* Starting column */
        col = command_gap;
 
-       /* Get size */
        Term_get_size(&wid, &hgt);
 
        /* Default "max-length" */
@@ -2326,7 +2322,6 @@ COMMAND_CODE show_equip(int target_item)
        /* Starting column */
        col = command_gap;
 
-       /* Get size */
        Term_get_size(&wid, &hgt);
 
        /* Maximal length */
@@ -2749,26 +2744,16 @@ bool get_item(OBJECT_IDX *cp, cptr pmt, cptr str, BIT_FLAGS mode)
        int max_inven = 0;
        int max_equip = 0;
 
-#ifdef ALLOW_REPEAT
-
        static char prev_tag = '\0';
        char cur_tag = '\0';
 
-#endif /* ALLOW_REPEAT */
-
-#ifdef ALLOW_EASY_FLOOR /* TNB */
-
        if (easy_floor || use_menu) return get_item_floor(cp, pmt, str, mode);
 
-#endif /* ALLOW_EASY_FLOOR -- TNB */
-
        /* Extract args */
        if (mode & USE_EQUIP) equip = TRUE;
        if (mode & USE_INVEN) inven = TRUE;
        if (mode & USE_FLOOR) floor = TRUE;
 
-#ifdef ALLOW_REPEAT
-
        /* Get the item index */
        if (repeat_pull(cp))
        {
@@ -2845,8 +2830,6 @@ bool get_item(OBJECT_IDX *cp, cptr pmt, cptr str, BIT_FLAGS mode)
                }
        }
 
-#endif /* ALLOW_REPEAT */
-
 
        /* Paranoia */
        msg_print(NULL);
@@ -3358,9 +3341,7 @@ bool get_item(OBJECT_IDX *cp, cptr pmt, cptr str, BIT_FLAGS mode)
                                (*cp) = k;
                                item = TRUE;
                                done = TRUE;
-#ifdef ALLOW_REPEAT
                                cur_tag = which;
-#endif /* ALLOW_REPEAT */
                                break;
                        }
 
@@ -3443,9 +3424,7 @@ bool get_item(OBJECT_IDX *cp, cptr pmt, cptr str, BIT_FLAGS mode)
                                        (*cp) = k;
                                        item = TRUE;
                                        done = TRUE;
-#ifdef ALLOW_REPEAT
                                        cur_tag = which;
-#endif /* ALLOW_REPEAT */
                                        break;
                                }
 
@@ -3539,21 +3518,13 @@ bool get_item(OBJECT_IDX *cp, cptr pmt, cptr str, BIT_FLAGS mode)
 
        if (item)
        {
-#ifdef ALLOW_REPEAT
                repeat_push(*cp);
                if (command_cmd) prev_tag = cur_tag;
-#endif /* ALLOW_REPEAT */
-
                command_cmd = 0; /* Hack -- command_cmd is no longer effective */
        }
-
-       /* Result */
        return (item);
 }
 
-
-#ifdef ALLOW_EASY_FLOOR
-
 /*!
  * @brief 床下に落ちているオブジェクトの数を返す / scan_floor
  * @param items オブジェクトのIDリストを返すための配列参照ポインタ
@@ -3605,8 +3576,6 @@ ITEM_NUMBER scan_floor(OBJECT_IDX *items, POSITION y, POSITION x, BIT_FLAGS mode
                /* Only one */
                if (mode & 0x04) break;
        }
-
-       /* Result */
        return num;
 }
 
@@ -3643,7 +3612,6 @@ COMMAND_CODE show_floor(int target_item, POSITION y, POSITION x, TERM_LEN *min_w
 
        bool dont_need_to_show_weights = TRUE;
 
-       /* Get size */
        Term_get_size(&wid, &hgt);
 
        /* Default length */
@@ -3795,8 +3763,6 @@ bool get_item_floor(COMMAND_CODE *cp, cptr pmt, cptr str, BIT_FLAGS mode)
        int max_inven = 0;
        int max_equip = 0;
 
-#ifdef ALLOW_REPEAT
-
        static char prev_tag = '\0';
        char cur_tag = '\0';
 
@@ -3891,8 +3857,6 @@ bool get_item_floor(COMMAND_CODE *cp, cptr pmt, cptr str, BIT_FLAGS mode)
                }
        }
 
-#endif /* ALLOW_REPEAT */
-
 
        /* Paranoia */
        msg_print(NULL);
@@ -4724,9 +4688,7 @@ bool get_item_floor(COMMAND_CODE *cp, cptr pmt, cptr str, BIT_FLAGS mode)
                                (*cp) = k;
                                item = TRUE;
                                done = TRUE;
-#ifdef ALLOW_REPEAT
                                cur_tag = which;
-#endif /* ALLOW_REPEAT */
                                break;
                        }
 
@@ -4835,9 +4797,7 @@ bool get_item_floor(COMMAND_CODE *cp, cptr pmt, cptr str, BIT_FLAGS mode)
                                                (*cp) = k;
                                                item = TRUE;
                                                done = TRUE;
-#ifdef ALLOW_REPEAT
                                                cur_tag = which;
-#endif /* ALLOW_REPEAT */
                                                break;
                                        }
                                }
@@ -4853,9 +4813,7 @@ bool get_item_floor(COMMAND_CODE *cp, cptr pmt, cptr str, BIT_FLAGS mode)
                                                (*cp) = k;
                                                item = TRUE;
                                                done = TRUE;
-#ifdef ALLOW_REPEAT
                                                cur_tag = which;
-#endif /* ALLOW_REPEAT */
                                                break;
                                        }
                                }
@@ -4963,15 +4921,10 @@ bool get_item_floor(COMMAND_CODE *cp, cptr pmt, cptr str, BIT_FLAGS mode)
 
        if (item)
        {
-#ifdef ALLOW_REPEAT
                repeat_push(*cp);
                if (command_cmd) prev_tag = cur_tag;
-#endif /* ALLOW_REPEAT */
-
                command_cmd = 0; /* Hack -- command_cmd is no longer effective */
        }
-
-       /* Result */
        return (item);
 }
 
@@ -5041,7 +4994,7 @@ void py_pickup_floor(bool pickup)
                next_o_idx = o_ptr->next_o_idx;
 
                /* Hack -- disturb */
-               disturb(0, 0);
+               disturb(FALSE, FALSE);
 
                /* Pick up gold */
                if (o_ptr->tval == TV_GOLD)
@@ -5226,5 +5179,3 @@ void py_pickup_floor(bool pickup)
                }
        }
 }
-
-#endif /* ALLOW_EASY_FLOOR */