OSDN Git Service

[Refactor] #39964 Moved autopick.c/h to autopick/autopick.c/h
[hengband/hengband.git] / src / cmd / cmd-smith.c
index 6a4d68e..455cc1a 100644 (file)
@@ -1,6 +1,6 @@
 #include "angband.h"
 #include "util.h"
-#include "term.h"
+#include "gameterm.h"
 
 #include "object-flavor.h"
 #include "object-hook.h"
@@ -8,8 +8,8 @@
 #include "player-status.h"
 #include "cmd-basic.h"
 #include "cmd-smith.h"
-#include "objectkind.h"
-#include "autopick.h"
+#include "object/object-kind.h"
+#include "autopick/autopick.h"
 #include "view-mainwindow.h"
 #include "player-inventory.h"
 
@@ -517,7 +517,7 @@ static void display_essence(player_type *creature_ptr)
 static void drain_essence(player_type *creature_ptr)
 {
        int drain_value[sizeof(creature_ptr->magic_num1) / sizeof(s32b)];
-       int i;
+       size_t i;
        OBJECT_IDX item;
        int dec = 4;
        bool observe = FALSE;
@@ -527,7 +527,7 @@ static void drain_essence(player_type *creature_ptr)
        object_type *o_ptr;
        concptr q, s;
        POSITION iy, ix;
-       byte_hack marked;
+       byte marked;
        ITEM_NUMBER number;
        OBJECT_IDX next_o_idx;
        WEIGHT weight;
@@ -608,7 +608,7 @@ static void drain_essence(player_type *creature_ptr)
        o_ptr->number = number;
        if (o_ptr->tval == TV_DRAG_ARMOR) o_ptr->timeout = old_timeout;
        if (item >= 0) creature_ptr->total_weight += (o_ptr->weight*o_ptr->number - weight * number);
-       o_ptr->ident |= (IDENT_MENTAL);
+       o_ptr->ident |= (IDENT_FULL_KNOWN);
        object_aware(creature_ptr, o_ptr);
        object_known(o_ptr);
 
@@ -1122,7 +1122,7 @@ static void add_essence(player_type *creature_ptr, ESSENCE_IDX mode)
 
        if ((mode != 10) && (object_is_artifact(o_ptr) || object_is_smith(o_ptr)))
        {
-               msg_print(_("そのアイテムはこれ以上改良できない。", "This item is no more able to be improved."));
+               msg_print(_("そのアイテムはこれ以上改良できない。", "This item can not be improved any further."));
                return;
        }
 
@@ -1313,12 +1313,8 @@ static void add_essence(player_type *creature_ptr, ESSENCE_IDX mode)
        }
 
        take_turn(creature_ptr, 100);
-
-#ifdef JP
-       msg_format("%sに%sの能力を付加しました。", o_name, es_ptr->add_name);
-#else
-       msg_format("You have added ability of %s to %s.", es_ptr->add_name, o_name);
-#endif
+       _(msg_format("%sに%sの能力を付加しました。", o_name, es_ptr->add_name),
+         msg_format("You have added ability of %s to %s.", es_ptr->add_name, o_name));
        creature_ptr->update |= (PU_COMBINE | PU_REORDER);
        creature_ptr->window |= (PW_INVEN);
 }