* @param x 召喚位置X座標
* @return 作用が実際にあった場合TRUEを返す
*/
-int summon_cyber(MONSTER_IDX who, POSITION y, POSITION x)
+int summon_cyber(floor_type *floor_ptr, MONSTER_IDX who, POSITION y, POSITION x)
{
int i;
- int max_cyber = (easy_band ? 1 : (p_ptr->current_floor_ptr->dun_level / 50) + randint1(2));
+ int max_cyber = (easy_band ? 1 : (floor_ptr->dun_level / 50) + randint1(2));
int count = 0;
BIT_FLAGS mode = PM_ALLOW_GROUP;
/* Summoned by a monster */
if (who > 0)
{
- monster_type *m_ptr = &p_ptr->current_floor_ptr->m_list[who];
+ monster_type *m_ptr = &floor_ptr->m_list[who];
if (is_pet(m_ptr)) mode |= PM_FORCE_PET;
}
extern bool item_tester_offer(object_type *o_ptr);
extern bool cast_summon_greater_demon(player_type *caster_ptr);
extern bool summon_kin_player(DEPTH level, POSITION y, POSITION x, BIT_FLAGS mode);
-extern int summon_cyber(MONSTER_IDX who, POSITION y, POSITION x);
+extern int summon_cyber(floor_type *floor_ptr, MONSTER_IDX who, POSITION y, POSITION x);
extern void mitokohmon(player_type *kohmon_ptr);
-
{
BIT_FLAGS flg = (PROJECT_GRID | PROJECT_ITEM | PROJECT_KILL | PROJECT_JUMP);
bool is_first_curse = TRUE;
+ floor_type *floor_ptr = target_ptr->current_floor_ptr;
while (is_first_curse || one_in_(3) && !stop_ty)
{
is_first_curse = FALSE;
(*count) += activate_hi_summon(target_ptr, target_ptr->y, target_ptr->x, FALSE);
if (!one_in_(6)) break;
case 7: case 8: case 9: case 18:
- (*count) += summon_specific(0, target_ptr->y, target_ptr->x, target_ptr->current_floor_ptr->dun_level, 0, (PM_ALLOW_GROUP | PM_ALLOW_UNIQUE | PM_NO_PET));
+ (*count) += summon_specific(0, target_ptr->y, target_ptr->x, floor_ptr->dun_level, 0, (PM_ALLOW_GROUP | PM_ALLOW_UNIQUE | PM_NO_PET));
if (!one_in_(6)) break;
case 10: case 11: case 12:
msg_print(_("経験値が体から吸い取られた気がする!", "You feel your experience draining away..."));
lose_all_info(target_ptr);
if (!one_in_(6)) break;
case 25:
- if ((target_ptr->current_floor_ptr->dun_level > 65) && !stop_ty)
+ if ((floor_ptr->dun_level > 65) && !stop_ty)
{
- (*count) += summon_cyber(-1, target_ptr->y, target_ptr->x);
+ (*count) += summon_cyber(floor_ptr, -1, target_ptr->y, target_ptr->x);
stop_ty = TRUE;
break;
}
if (type < SUMMON_MOLD) type = SUMMON_MOLD;
else if (type > SUMMON_MIMIC) type = SUMMON_MIMIC;
+ floor_type *floor_ptr = caster_ptr->current_floor_ptr;
switch (randint1(spell) + randint1(8) + 1)
{
case 1:
case 35:
for (int counter = 0; counter < 8; counter++)
{
- (void)summon_specific(0, caster_ptr->y, caster_ptr->x, (caster_ptr->current_floor_ptr->dun_level * 3) / 2, type, (PM_ALLOW_GROUP | PM_NO_PET));
+ (void)summon_specific(0, caster_ptr->y, caster_ptr->x, (floor_ptr->dun_level * 3) / 2, type, (PM_ALLOW_GROUP | PM_NO_PET));
}
break;
activate_hi_summon(caster_ptr, caster_ptr->y, caster_ptr->x, FALSE);
break;
case 38:
- (void)summon_cyber(-1, caster_ptr->y, caster_ptr->x);
+ (void)summon_cyber(floor_ptr, -1, caster_ptr->y, caster_ptr->x);
break;
default:
{