OSDN Git Service
(root)
/
hengband
/
hengband.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[Refactor] #37353 アリーナのコマンド制限処理を cmd_limit_arena() に統合。 / Integrate command limitatio...
[hengband/hengband.git]
/
src
/
cmd-activate.c
diff --git
a/src/cmd-activate.c
b/src/cmd-activate.c
index
8900d33
..
0dc1c83
100644
(file)
--- a/
src/cmd-activate.c
+++ b/
src/cmd-activate.c
@@
-10,6
+10,12
@@
#include "cmd-activate.h"
#include "object-hook.h"
#include "spells-summon.h"
#include "cmd-activate.h"
#include "object-hook.h"
#include "spells-summon.h"
+#include "sort.h"
+#include "projection.h"
+#include "artifact.h"
+#include "avatar.h"
+#include "spells-status.h"
+#include "realm-hex.h"
/*!
* @brief ペット入りモンスターボールをソートするための比較関数
/*!
* @brief ペット入りモンスターボールをソートするための比較関数
@@
-182,12
+188,12
@@
void do_cmd_activate_aux(INVENTORY_IDX item)
{
IDX pet_ctr, i;
{
IDX pet_ctr, i;
- IDX *who;
+
MONSTER_
IDX *who;
int max_pet = 0;
u16b dummy_why;
/* Allocate the "who" array */
int max_pet = 0;
u16b dummy_why;
/* Allocate the "who" array */
- C_MAKE(who, max_m_idx, IDX);
+ C_MAKE(who, max_m_idx,
MONSTER_
IDX);
/* Process the monsters (backwards) */
for (pet_ctr = m_max - 1; pet_ctr >= 1; pet_ctr--)
/* Process the monsters (backwards) */
for (pet_ctr = m_max - 1; pet_ctr >= 1; pet_ctr--)
@@
-236,7
+242,7
@@
void do_cmd_activate_aux(INVENTORY_IDX item)
o_ptr->xtra5 = (XTRA16)cap_maxhp;
if (cap_nickname)
{
o_ptr->xtra5 = (XTRA16)cap_maxhp;
if (cap_nickname)
{
- cptr t;
+ c
onc
ptr t;
char *s;
char buf[80] = "";
char *s;
char buf[80] = "";
@@
-288,7
+294,7
@@
void do_cmd_activate_aux(INVENTORY_IDX item)
if (o_ptr->inscription)
{
char buf[80];
if (o_ptr->inscription)
{
char buf[80];
- cptr t;
+ c
onc
ptr t;
#ifndef JP
bool quote = FALSE;
#endif
#ifndef JP
bool quote = FALSE;
#endif
@@
-364,16
+370,10
@@
void do_cmd_activate_aux(INVENTORY_IDX item)
void do_cmd_activate(void)
{
OBJECT_IDX item;
void do_cmd_activate(void)
{
OBJECT_IDX item;
- cptr q, s;
+ c
onc
ptr q, s;
if (p_ptr->wild_mode) return;
if (p_ptr->wild_mode) return;
-
- if (p_ptr->inside_arena)
- {
- msg_print(_("アリーナが魔法を吸収した!", "The arena absorbs all attempted magic!"));
- msg_print(NULL);
- return;
- }
+ if (cmd_limit_arena(p_ptr)) return;
if (p_ptr->special_defense & (KATA_MUSOU | KATA_KOUKIJIN))
{
if (p_ptr->special_defense & (KATA_MUSOU | KATA_KOUKIJIN))
{
@@
-401,7
+401,7
@@
static bool activate_dragon_breath(object_type *o_ptr)
{
BIT_FLAGS flgs[TR_FLAG_SIZE]; /* for resistance flags */
int type[20];
{
BIT_FLAGS flgs[TR_FLAG_SIZE]; /* for resistance flags */
int type[20];
- cptr name[20];
+ c
onc
ptr name[20];
int i, t, n = 0;
DIRECTION dir;
int i, t, n = 0;
DIRECTION dir;
@@
-443,7
+443,7
@@
bool activate_artifact(object_type *o_ptr)
PLAYER_LEVEL plev = p_ptr->lev;
int k, dummy = 0;
DIRECTION dir;
PLAYER_LEVEL plev = p_ptr->lev;
int k, dummy = 0;
DIRECTION dir;
- cptr name = k_name + k_info[o_ptr->k_idx].name;
+ c
onc
ptr name = k_name + k_info[o_ptr->k_idx].name;
const activation_type* const act_ptr = find_activation_info(o_ptr);
/* Paranoia */
const activation_type* const act_ptr = find_activation_info(o_ptr);
/* Paranoia */
@@
-1656,7
+1656,7
@@
bool activate_artifact(object_type *o_ptr)
{
int count = 0, i;
monster_type *m_ptr;
{
int count = 0, i;
monster_type *m_ptr;
- cptr kakusan = "";
+ c
onc
ptr kakusan = "";
if (summon_named_creature(0, p_ptr->y, p_ptr->x, MON_SUKE, PM_FORCE_PET))
{
if (summon_named_creature(0, p_ptr->y, p_ptr->x, MON_SUKE, PM_FORCE_PET))
{