• R/O
  • HTTP
  • SSH
  • HTTPS

hengband: Commit

変愚蛮怒のメインリポジトリです


Commit MetaInfo

Revisiond891e1b8ec7d3661ef290ec0eb37eea793f7db9b (tree)
Time2019-01-10 22:15:15
AuthorDeskull <deskull@user...>
CommiterDeskull

Log Message

[Refactor] #38824 get_item() を choose_object() に置換中。 / Replacing get_item() to choose_object().

Change Summary

Incremental Difference

--- a/src/cmd-activate.c
+++ b/src/cmd-activate.c
@@ -385,7 +385,7 @@ void do_cmd_activate(void)
385385 q = _("どのアイテムを始動させますか? ", "Activate which item? ");
386386 s = _("始動できるアイテムを装備していない。", "You have nothing to activate.");
387387
388- if (!get_item(&item, q, s, (USE_EQUIP | IGNORE_BOTHHAND_SLOT))) return;
388+ if (!choose_object(&item, q, s, (USE_EQUIP | IGNORE_BOTHHAND_SLOT))) return;
389389
390390 /* Activate the item */
391391 do_cmd_activate_aux(item);
--- a/src/cmd-eat.c
+++ b/src/cmd-eat.c
@@ -500,7 +500,6 @@ void do_cmd_eat_food(void)
500500 OBJECT_IDX item;
501501 cptr q, s;
502502
503-
504503 if (p_ptr->special_defense & (KATA_MUSOU | KATA_KOUKIJIN))
505504 {
506505 set_action(ACTION_NONE);
@@ -512,7 +511,7 @@ void do_cmd_eat_food(void)
512511 q = _("どれを食べますか? ", "Eat which item? ");
513512 s = _("食べ物がない。", "You have nothing to eat.");
514513
515- if (!get_item(&item, q, s, (USE_INVEN | USE_FLOOR))) return;
514+ if (!choose_object(&item, q, s, (USE_INVEN | USE_FLOOR))) return;
516515
517516 /* Eat the object */
518517 do_cmd_eat_food_aux(item);
--- a/src/cmd-item.c
+++ b/src/cmd-item.c
@@ -186,7 +186,7 @@ void do_cmd_wield(void)
186186 /* Choose a weapon from the equipment only */
187187 q = _("どちらの武器と取り替えますか?", "Replace which weapon? ");
188188 s = _("おっと。", "Oops.");
189- if (!get_item(&slot, q, s, (USE_EQUIP | IGNORE_BOTHHAND_SLOT))) return;
189+ if (!choose_object(&slot, q, s, (USE_EQUIP | IGNORE_BOTHHAND_SLOT))) return;
190190 if (slot == INVEN_RARM) need_switch_wielding = INVEN_LARM;
191191 }
192192
@@ -202,7 +202,7 @@ void do_cmd_wield(void)
202202 /* Choose a hand */
203203 q = _("どちらの手に装備しますか?", "Equip which hand? ");
204204 s = _("おっと。", "Oops.");
205- if (!get_item(&slot, q, s, (USE_EQUIP))) return;
205+ if (!choose_object(&slot, q, s, (USE_EQUIP))) return;
206206 }
207207 break;
208208
Show on old repository browser