OSDN Git Service

Merge branch '#39321' into For2.2.2-Refactoring
authordeskull <deskull@users.sourceforge.jp>
Sat, 15 Jun 2019 10:35:46 +0000 (19:35 +0900)
committerdeskull <deskull@users.sourceforge.jp>
Sat, 15 Jun 2019 10:35:46 +0000 (19:35 +0900)
1  2 
src/cmd-activate.c
src/cmd-activate.h
src/cmd-eat.c
src/cmd-item.c
src/cmd-quaff.c
src/cmd-usestaff.c
src/cmd-zaprod.c

@@@ -345,7 -345,7 +345,7 @@@ const activation_type activation_info[
   * the user hits "escape" at the "direction" prompt.
   * </pre>
   */
- void do_cmd_activate_aux(player_type *user_ptr, INVENTORY_IDX item)
 -void exe_activate(INVENTORY_IDX item)
++void exe_activate(player_type *user_ptr, INVENTORY_IDX item)
  {
        DIRECTION dir;
        DEPTH lev;
@@@ -651,7 -653,7 +651,7 @@@ void do_cmd_activate(void
        if (!choose_object(&item, q, s, (USE_EQUIP | IGNORE_BOTHHAND_SLOT), 0)) return;
  
        /* Activate the item */
-       do_cmd_activate_aux(p_ptr, item);
 -      exe_activate(item);
++      exe_activate(p_ptr, item);
  }
  
  /*!
@@@ -1,7 -1,7 +1,7 @@@
  #pragma once
  
  extern void do_cmd_activate(void);
- extern void do_cmd_activate_aux(player_type *user_ptr, INVENTORY_IDX item);
 -extern void exe_activate(INVENTORY_IDX item);
++extern void exe_activate(player_type *user_ptr, INVENTORY_IDX item);
  extern bool activate_artifact(object_type * o_ptr);
  
  typedef struct {
diff --cc src/cmd-eat.c
Simple merge
diff --cc src/cmd-item.c
@@@ -1544,45 -1546,73 +1544,45 @@@ void do_cmd_use(void
  
        switch (o_ptr->tval)
        {
 -              /* Spike a door */
                case TV_SPIKE:
 -              {
                        do_cmd_spike();
                        break;
 -              }
  
 -              /* Eat some food */
                case TV_FOOD:
-                       do_cmd_eat_food_aux(item);
 -              {
+                       exe_eat_food(item);
                        break;
 -              }
  
 -              /* Aim a wand */
                case TV_WAND:
-                       do_cmd_aim_wand_aux(item);
 -              {
+                       exe_aim_wand(item);
                        break;
 -              }
  
 -              /* Use a staff */
                case TV_STAFF:
-                       do_cmd_use_staff_aux(item);
 -              {
+                       exe_use_staff(item);
                        break;
 -              }
  
 -              /* Zap a rod */
                case TV_ROD:
-                       do_cmd_zap_rod_aux(item);
 -              {
+                       exe_zap_rod(item);
                        break;
 -              }
  
 -              /* Quaff a potion */
                case TV_POTION:
-                       do_cmd_quaff_potion_aux(item);
 -              {
+                       exe_quaff_potion(item);
                        break;
 -              }
  
 -              /* Read a scroll */
                case TV_SCROLL:
 -              {
                        if (cmd_limit_blind(p_ptr)) return;
                        if (cmd_limit_confused(p_ptr)) return;
-                       do_cmd_read_scroll_aux(item, TRUE);
 -
+                       exe_read(item, TRUE);
                        break;
 -              }
  
 -              /* Fire ammo */
                case TV_SHOT:
                case TV_ARROW:
                case TV_BOLT:
 -              {
                        exe_fire(item, &p_ptr->inventory_list[INVEN_BOW], SP_NONE);
                        break;
 -              }
  
 -              /* Activate an artifact */
                default:
-                       do_cmd_activate_aux(p_ptr, item);
 -              {
 -                      exe_activate(item);
++                      exe_activate(p_ptr, item);
                        break;
 -              }
        }
  }
  
diff --cc src/cmd-quaff.c
Simple merge
Simple merge
Simple merge