OSDN Git Service

[MISC] cmd-item/cmd-refill.c 内の player_type 変数名を統一. / Unified player_type variable...
authordeskull <deskull@users.sourceforge.jp>
Sat, 24 Oct 2020 16:14:18 +0000 (01:14 +0900)
committerdeskull <deskull@users.sourceforge.jp>
Sat, 24 Oct 2020 16:14:18 +0000 (01:14 +0900)
src/cmd-item/cmd-refill.c
src/cmd-item/cmd-refill.h

index 8f9872b..164b60d 100644 (file)
@@ -62,7 +62,7 @@ static void do_cmd_refill_lamp(player_type *user_ptr)
  * Refuel the players torch (from the pack or floor)
  * @return \82È\82µ
  */
-static void do_cmd_refill_torch(player_type *creature_ptr)
+static void do_cmd_refill_torch(player_type *user_ptr)
 {
     OBJECT_IDX item;
     object_type *o_ptr;
@@ -70,16 +70,16 @@ static void do_cmd_refill_torch(player_type *creature_ptr)
     item_tester_hook = object_can_refill_torch;
     concptr q = _("\82Ç\82Ì\8f¼\96¾\82Å\96¾\82©\82è\82ð\8b­\82ß\82Ü\82·\82©? ", "Refuel with which torch? ");
     concptr s = _("\91¼\82É\8f¼\96¾\82ª\82È\82¢\81B", "You have no extra torches.");
-    o_ptr = choose_object(creature_ptr, &item, q, s, USE_INVEN | USE_FLOOR, 0);
+    o_ptr = choose_object(user_ptr, &item, q, s, USE_INVEN | USE_FLOOR, 0);
     if (!o_ptr)
         return;
 
     BIT_FLAGS flgs[TR_FLAG_SIZE], flgs2[TR_FLAG_SIZE];
-    object_flags(creature_ptr, o_ptr, flgs);
+    object_flags(user_ptr, o_ptr, flgs);
 
-    take_turn(creature_ptr, 50);
-    j_ptr = &creature_ptr->inventory_list[INVEN_LITE];
-    object_flags(creature_ptr, j_ptr, flgs2);
+    take_turn(user_ptr, 50);
+    j_ptr = &user_ptr->inventory_list[INVEN_LITE];
+    object_flags(user_ptr, j_ptr, flgs2);
     j_ptr->xtra4 += o_ptr->xtra4 + 5;
     msg_print(_("\8f¼\96¾\82ð\8c\8b\8d\87\82µ\82½\81B", "You combine the torches."));
     if (has_flag(flgs, TR_DARK_SOURCE) && (j_ptr->xtra4 > 0)) {
@@ -94,8 +94,8 @@ static void do_cmd_refill_torch(player_type *creature_ptr)
     } else
         msg_print(_("\8f¼\96¾\82Í\82¢\82Á\82»\82¤\96¾\82é\82­\8bP\82¢\82½\81B", "Your torch glows more brightly."));
 
-    vary_item(creature_ptr, item, -1);
-    creature_ptr->update |= PU_TORCH;
+    vary_item(user_ptr, item, -1);
+    user_ptr->update |= PU_TORCH;
 }
 
 /*!
@@ -103,19 +103,19 @@ static void do_cmd_refill_torch(player_type *creature_ptr)
  * Refill the players lamp, or restock his torches
  * @return \82È\82µ
  */
-void do_cmd_refill(player_type *creature_ptr)
+void do_cmd_refill(player_type *user_ptr)
 {
     object_type *o_ptr;
-    o_ptr = &creature_ptr->inventory_list[INVEN_LITE];
-    if (creature_ptr->special_defense & KATA_MUSOU)
-        set_action(creature_ptr, ACTION_NONE);
+    o_ptr = &user_ptr->inventory_list[INVEN_LITE];
+    if (user_ptr->special_defense & KATA_MUSOU)
+        set_action(user_ptr, ACTION_NONE);
 
     if (o_ptr->tval != TV_LITE)
         msg_print(_("\8cõ\8c¹\82ð\91\95\94õ\82µ\82Ä\82¢\82È\82¢\81B", "You are not wielding a light."));
     else if (o_ptr->sval == SV_LITE_LANTERN)
-        do_cmd_refill_lamp(creature_ptr);
+        do_cmd_refill_lamp(user_ptr);
     else if (o_ptr->sval == SV_LITE_TORCH)
-        do_cmd_refill_torch(creature_ptr);
+        do_cmd_refill_torch(user_ptr);
     else
         msg_print(_("\82±\82Ì\8cõ\8c¹\82Í\8eõ\96½\82ð\89\84\82Î\82¹\82È\82¢\81B", "Your light cannot be refilled."));
 }
index ff6af6f..1ea359d 100644 (file)
@@ -2,4 +2,4 @@
 
 #include "system/angband.h"
 
-void do_cmd_refill(player_type *creature_ptr);
+void do_cmd_refill(player_type *user_ptr);