#include "view/display-messages.h"
/*!
- * @brief 巻物を読むコマンドのサブルーチン
- * Read a scroll (from the pack or floor).
+ * @brief コンストラクタ
* @param player_ptr プレイヤーへの参照ポインタ
* @param item 読むオブジェクトの所持品ID
+ */
+ObjectReadEntity::ObjectReadEntity(player_type *player_ptr, INVENTORY_IDX item)
+ : player_ptr(player_ptr)
+ , item(item)
+{
+}
+
+/*!
+ * @brief 巻物を読む
* @param known 判明済ならばTRUE
- * @details
- * <pre>
- * Certain scrolls can be "aborted" without losing the scroll. These
- * include scrolls with no effects but recharge or identify, which are
- * cancelled before use. XXX Reading them still takes a turn, though.
- * </pre>
*/
-void exe_read(player_type *player_ptr, INVENTORY_IDX item, bool known)
+void ObjectReadEntity::execute(bool known)
{
- int k, used_up, ident, lev;
- object_type *o_ptr;
- o_ptr = ref_item(player_ptr, item);
- PlayerEnergy(player_ptr).set_player_turn_energy(100);
- if (cmd_limit_time_walk(player_ptr))
+ auto *o_ptr = ref_item(this->player_ptr, this->item);
+ PlayerEnergy(this->player_ptr).set_player_turn_energy(100);
+ if (cmd_limit_time_walk(this->player_ptr)) {
return;
+ }
- if (player_ptr->pclass == CLASS_BERSERKER) {
+ if (this->player_ptr->pclass == CLASS_BERSERKER) {
msg_print(_("巻物なんて読めない。", "You cannot read."));
return;
}
- if (music_singing_any(player_ptr))
- stop_singing(player_ptr);
+ if (music_singing_any(this->player_ptr)) {
+ stop_singing(this->player_ptr);
+ }
- SpellHex spell_hex(player_ptr);
- if (spell_hex.is_spelling_any() && ((player_ptr->lev < 35) || spell_hex.is_casting_full_capacity())) {
- (void)SpellHex(player_ptr).stop_all_spells();
+ SpellHex spell_hex(this->player_ptr);
+ if (spell_hex.is_spelling_any() && ((this->player_ptr->lev < 35) || spell_hex.is_casting_full_capacity())) {
+ (void)SpellHex(this->player_ptr).stop_all_spells();
}
- ident = false;
- lev = k_info[o_ptr->k_idx].level;
- used_up = true;
+ auto ident = false;
+ auto lev = k_info[o_ptr->k_idx].level;
+ auto used_up = true;
if (o_ptr->tval == TV_SCROLL) {
switch (o_ptr->sval) {
case SV_SCROLL_DARKNESS: {
- if (!has_resist_blind(player_ptr) && !has_resist_dark(player_ptr))
- (void)BadStatusSetter(player_ptr).mod_blindness(3 + randint1(5));
+ if (!has_resist_blind(this->player_ptr) && !has_resist_dark(this->player_ptr))
+ (void)BadStatusSetter(this->player_ptr).mod_blindness(3 + randint1(5));
- if (unlite_area(player_ptr, 10, 3))
+ if (unlite_area(this->player_ptr, 10, 3))
ident = true;
break;
}
case SV_SCROLL_AGGRAVATE_MONSTER: {
msg_print(_("カン高くうなる様な音が辺りを覆った。", "There is a high pitched humming noise."));
- aggravate_monsters(player_ptr, 0);
+ aggravate_monsters(this->player_ptr, 0);
ident = true;
break;
}
case SV_SCROLL_CURSE_ARMOR: {
- if (curse_armor(player_ptr))
+ if (curse_armor(this->player_ptr))
ident = true;
break;
}
case SV_SCROLL_CURSE_WEAPON: {
- k = 0;
- if (has_melee_weapon(player_ptr, INVEN_MAIN_HAND)) {
+ auto k = 0;
+ if (has_melee_weapon(this->player_ptr, INVEN_MAIN_HAND)) {
k = INVEN_MAIN_HAND;
- if (has_melee_weapon(player_ptr, INVEN_SUB_HAND) && one_in_(2))
+ if (has_melee_weapon(this->player_ptr, INVEN_SUB_HAND) && one_in_(2))
k = INVEN_SUB_HAND;
- } else if (has_melee_weapon(player_ptr, INVEN_SUB_HAND))
+ } else if (has_melee_weapon(this->player_ptr, INVEN_SUB_HAND))
k = INVEN_SUB_HAND;
- if (k && curse_weapon_object(player_ptr, false, &player_ptr->inventory_list[k]))
+ if (k && curse_weapon_object(this->player_ptr, false, &this->player_ptr->inventory_list[k]))
ident = true;
break;
}
case SV_SCROLL_SUMMON_MONSTER: {
- for (k = 0; k < randint1(3); k++) {
- if (summon_specific(player_ptr, 0, player_ptr->y, player_ptr->x, player_ptr->current_floor_ptr->dun_level, SUMMON_NONE,
+ for (auto k = 0; k < randint1(3); k++) {
+ if (summon_specific(this->player_ptr, 0, this->player_ptr->y, this->player_ptr->x, this->player_ptr->current_floor_ptr->dun_level, SUMMON_NONE,
PM_ALLOW_GROUP | PM_ALLOW_UNIQUE | PM_NO_PET)) {
ident = true;
}
break;
}
case SV_SCROLL_SUMMON_UNDEAD: {
- for (k = 0; k < randint1(3); k++) {
- if (summon_specific(player_ptr, 0, player_ptr->y, player_ptr->x, player_ptr->current_floor_ptr->dun_level, SUMMON_UNDEAD,
+ for (auto k = 0; k < randint1(3); k++) {
+ if (summon_specific(this->player_ptr, 0, this->player_ptr->y, this->player_ptr->x, this->player_ptr->current_floor_ptr->dun_level, SUMMON_UNDEAD,
PM_ALLOW_GROUP | PM_ALLOW_UNIQUE | PM_NO_PET)) {
ident = true;
}
}
case SV_SCROLL_SUMMON_PET: {
if (summon_specific(
- player_ptr, -1, player_ptr->y, player_ptr->x, player_ptr->current_floor_ptr->dun_level, SUMMON_NONE, PM_ALLOW_GROUP | PM_FORCE_PET))
+ this->player_ptr, -1, this->player_ptr->y, this->player_ptr->x, this->player_ptr->current_floor_ptr->dun_level, SUMMON_NONE, PM_ALLOW_GROUP | PM_FORCE_PET))
ident = true;
break;
}
case SV_SCROLL_SUMMON_KIN: {
- if (summon_kin_player(player_ptr, player_ptr->lev, player_ptr->y, player_ptr->x, PM_FORCE_PET | PM_ALLOW_GROUP))
+ if (summon_kin_player(this->player_ptr, this->player_ptr->lev, this->player_ptr->y, this->player_ptr->x, PM_FORCE_PET | PM_ALLOW_GROUP))
ident = true;
break;
}
case SV_SCROLL_TRAP_CREATION: {
- if (trap_creation(player_ptr, player_ptr->y, player_ptr->x))
+ if (trap_creation(this->player_ptr, this->player_ptr->y, this->player_ptr->x))
ident = true;
break;
}
case SV_SCROLL_PHASE_DOOR: {
- teleport_player(player_ptr, 10, TELEPORT_SPONTANEOUS);
+ teleport_player(this->player_ptr, 10, TELEPORT_SPONTANEOUS);
ident = true;
break;
}
case SV_SCROLL_TELEPORT: {
- teleport_player(player_ptr, 100, TELEPORT_SPONTANEOUS);
+ teleport_player(this->player_ptr, 100, TELEPORT_SPONTANEOUS);
ident = true;
break;
}
case SV_SCROLL_TELEPORT_LEVEL: {
- (void)teleport_level(player_ptr, 0);
+ (void)teleport_level(this->player_ptr, 0);
ident = true;
break;
}
case SV_SCROLL_WORD_OF_RECALL: {
- if (!recall_player(player_ptr, randint0(21) + 15))
+ if (!recall_player(this->player_ptr, randint0(21) + 15))
used_up = false;
ident = true;
break;
}
case SV_SCROLL_IDENTIFY: {
- if (!ident_spell(player_ptr, false))
+ if (!ident_spell(this->player_ptr, false))
used_up = false;
ident = true;
break;
}
case SV_SCROLL_STAR_IDENTIFY: {
- if (!identify_fully(player_ptr, false))
+ if (!identify_fully(this->player_ptr, false))
used_up = false;
ident = true;
break;
}
case SV_SCROLL_REMOVE_CURSE: {
- if (remove_curse(player_ptr))
+ if (remove_curse(this->player_ptr))
ident = true;
break;
}
case SV_SCROLL_STAR_REMOVE_CURSE: {
- if (remove_all_curse(player_ptr))
+ if (remove_all_curse(this->player_ptr))
ident = true;
break;
}
case SV_SCROLL_ENCHANT_ARMOR: {
ident = true;
- if (!enchant_spell(player_ptr, 0, 0, 1))
+ if (!enchant_spell(this->player_ptr, 0, 0, 1))
used_up = false;
break;
}
case SV_SCROLL_ENCHANT_WEAPON_TO_HIT: {
- if (!enchant_spell(player_ptr, 1, 0, 0))
+ if (!enchant_spell(this->player_ptr, 1, 0, 0))
used_up = false;
ident = true;
break;
}
case SV_SCROLL_ENCHANT_WEAPON_TO_DAM: {
- if (!enchant_spell(player_ptr, 0, 1, 0))
+ if (!enchant_spell(this->player_ptr, 0, 1, 0))
used_up = false;
ident = true;
break;
}
case SV_SCROLL_STAR_ENCHANT_ARMOR: {
- if (!enchant_spell(player_ptr, 0, 0, randint1(3) + 2))
+ if (!enchant_spell(this->player_ptr, 0, 0, randint1(3) + 2))
used_up = false;
ident = true;
break;
}
case SV_SCROLL_STAR_ENCHANT_WEAPON: {
- if (!enchant_spell(player_ptr, randint1(3), randint1(3), 0))
+ if (!enchant_spell(this->player_ptr, randint1(3), randint1(3), 0))
used_up = false;
ident = true;
break;
}
case SV_SCROLL_RECHARGING: {
- if (!recharge(player_ptr, 130))
+ if (!recharge(this->player_ptr, 130))
used_up = false;
ident = true;
}
case SV_SCROLL_MUNDANITY: {
ident = true;
- if (!mundane_spell(player_ptr, false))
+ if (!mundane_spell(this->player_ptr, false))
used_up = false;
break;
}
case SV_SCROLL_LIGHT: {
- if (lite_area(player_ptr, damroll(2, 8), 2))
+ if (lite_area(this->player_ptr, damroll(2, 8), 2))
ident = true;
break;
}
case SV_SCROLL_MAPPING: {
- map_area(player_ptr, DETECT_RAD_MAP);
+ map_area(this->player_ptr, DETECT_RAD_MAP);
ident = true;
break;
}
case SV_SCROLL_DETECT_GOLD: {
- if (detect_treasure(player_ptr, DETECT_RAD_DEFAULT) || detect_objects_gold(player_ptr, DETECT_RAD_DEFAULT))
+ if (detect_treasure(this->player_ptr, DETECT_RAD_DEFAULT) || detect_objects_gold(this->player_ptr, DETECT_RAD_DEFAULT))
ident = true;
break;
}
case SV_SCROLL_DETECT_ITEM: {
- if (detect_objects_normal(player_ptr, DETECT_RAD_DEFAULT))
+ if (detect_objects_normal(this->player_ptr, DETECT_RAD_DEFAULT))
ident = true;
break;
}
case SV_SCROLL_DETECT_TRAP: {
- if (detect_traps(player_ptr, DETECT_RAD_DEFAULT, known))
+ if (detect_traps(this->player_ptr, DETECT_RAD_DEFAULT, known))
ident = true;
break;
}
case SV_SCROLL_DETECT_DOOR: {
- if (detect_doors(player_ptr, DETECT_RAD_DEFAULT) || detect_stairs(player_ptr, DETECT_RAD_DEFAULT))
+ if (detect_doors(this->player_ptr, DETECT_RAD_DEFAULT) || detect_stairs(this->player_ptr, DETECT_RAD_DEFAULT))
ident = true;
break;
}
case SV_SCROLL_DETECT_INVIS: {
- if (detect_monsters_invis(player_ptr, DETECT_RAD_DEFAULT))
+ if (detect_monsters_invis(this->player_ptr, DETECT_RAD_DEFAULT))
ident = true;
break;
}
case SV_SCROLL_SATISFY_HUNGER: {
- if (set_food(player_ptr, PY_FOOD_MAX - 1))
+ if (set_food(this->player_ptr, PY_FOOD_MAX - 1))
ident = true;
break;
}
case SV_SCROLL_BLESSING: {
- if (set_blessed(player_ptr, player_ptr->blessed + randint1(12) + 6, false))
+ if (set_blessed(this->player_ptr, this->player_ptr->blessed + randint1(12) + 6, false))
ident = true;
break;
}
case SV_SCROLL_HOLY_CHANT: {
- if (set_blessed(player_ptr, player_ptr->blessed + randint1(24) + 12, false))
+ if (set_blessed(this->player_ptr, this->player_ptr->blessed + randint1(24) + 12, false))
ident = true;
break;
}
case SV_SCROLL_HOLY_PRAYER: {
- if (set_blessed(player_ptr, player_ptr->blessed + randint1(48) + 24, false))
+ if (set_blessed(this->player_ptr, this->player_ptr->blessed + randint1(48) + 24, false))
ident = true;
break;
}
case SV_SCROLL_MONSTER_CONFUSION: {
- if (!(player_ptr->special_attack & ATTACK_CONFUSE)) {
+ if (!(this->player_ptr->special_attack & ATTACK_CONFUSE)) {
msg_print(_("手が輝き始めた。", "Your hands begin to glow."));
- player_ptr->special_attack |= ATTACK_CONFUSE;
- player_ptr->redraw |= PR_STATUS;
+ this->player_ptr->special_attack |= ATTACK_CONFUSE;
+ this->player_ptr->redraw |= PR_STATUS;
ident = true;
}
break;
}
case SV_SCROLL_PROTECTION_FROM_EVIL: {
- k = 3 * player_ptr->lev;
- if (set_protevil(player_ptr, player_ptr->protevil + randint1(25) + k, false))
+ auto k = 3 * this->player_ptr->lev;
+ if (set_protevil(this->player_ptr, this->player_ptr->protevil + randint1(25) + k, false))
ident = true;
break;
}
case SV_SCROLL_RUNE_OF_PROTECTION: {
- create_rune_protection_one(player_ptr);
+ create_rune_protection_one(this->player_ptr);
ident = true;
break;
}
case SV_SCROLL_TRAP_DOOR_DESTRUCTION: {
- if (destroy_doors_touch(player_ptr))
+ if (destroy_doors_touch(this->player_ptr))
ident = true;
break;
}
case SV_SCROLL_STAR_DESTRUCTION: {
- if (destroy_area(player_ptr, player_ptr->y, player_ptr->x, 13 + randint0(5), false))
+ if (destroy_area(this->player_ptr, this->player_ptr->y, this->player_ptr->x, 13 + randint0(5), false))
ident = true;
else
msg_print(_("ダンジョンが揺れた...", "The dungeon trembles..."));
break;
}
case SV_SCROLL_DISPEL_UNDEAD: {
- if (dispel_undead(player_ptr, 80))
+ if (dispel_undead(this->player_ptr, 80))
ident = true;
break;
}
case SV_SCROLL_SPELL: {
- if ((player_ptr->pclass == CLASS_WARRIOR) || (player_ptr->pclass == CLASS_IMITATOR) || (player_ptr->pclass == CLASS_MINDCRAFTER)
- || (player_ptr->pclass == CLASS_SORCERER) || (player_ptr->pclass == CLASS_ARCHER) || (player_ptr->pclass == CLASS_MAGIC_EATER)
- || (player_ptr->pclass == CLASS_RED_MAGE) || (player_ptr->pclass == CLASS_SAMURAI) || (player_ptr->pclass == CLASS_BLUE_MAGE)
- || (player_ptr->pclass == CLASS_CAVALRY) || (player_ptr->pclass == CLASS_BERSERKER) || (player_ptr->pclass == CLASS_SMITH)
- || (player_ptr->pclass == CLASS_MIRROR_MASTER) || (player_ptr->pclass == CLASS_NINJA) || (player_ptr->pclass == CLASS_SNIPER))
+ if ((this->player_ptr->pclass == CLASS_WARRIOR) || (this->player_ptr->pclass == CLASS_IMITATOR) || (this->player_ptr->pclass == CLASS_MINDCRAFTER)
+ || (this->player_ptr->pclass == CLASS_SORCERER) || (this->player_ptr->pclass == CLASS_ARCHER) || (this->player_ptr->pclass == CLASS_MAGIC_EATER)
+ || (this->player_ptr->pclass == CLASS_RED_MAGE) || (this->player_ptr->pclass == CLASS_SAMURAI) || (this->player_ptr->pclass == CLASS_BLUE_MAGE)
+ || (this->player_ptr->pclass == CLASS_CAVALRY) || (this->player_ptr->pclass == CLASS_BERSERKER) || (this->player_ptr->pclass == CLASS_SMITH)
+ || (this->player_ptr->pclass == CLASS_MIRROR_MASTER) || (this->player_ptr->pclass == CLASS_NINJA) || (this->player_ptr->pclass == CLASS_SNIPER))
break;
- player_ptr->add_spells++;
- player_ptr->update |= PU_SPELLS;
+ this->player_ptr->add_spells++;
+ this->player_ptr->update |= PU_SPELLS;
ident = true;
break;
}
case SV_SCROLL_GENOCIDE: {
- (void)symbol_genocide(player_ptr, 300, true);
+ (void)symbol_genocide(this->player_ptr, 300, true);
ident = true;
break;
}
case SV_SCROLL_MASS_GENOCIDE: {
- (void)mass_genocide(player_ptr, 300, true);
+ (void)mass_genocide(this->player_ptr, 300, true);
ident = true;
break;
}
case SV_SCROLL_ACQUIREMENT: {
- acquirement(player_ptr, player_ptr->y, player_ptr->x, 1, true, false, false);
+ acquirement(this->player_ptr, this->player_ptr->y, this->player_ptr->x, 1, true, false, false);
ident = true;
break;
}
case SV_SCROLL_STAR_ACQUIREMENT: {
- acquirement(player_ptr, player_ptr->y, player_ptr->x, randint1(2) + 1, true, false, false);
+ acquirement(this->player_ptr, this->player_ptr->y, this->player_ptr->x, randint1(2) + 1, true, false, false);
ident = true;
break;
}
case SV_SCROLL_FIRE: {
- fire_ball(player_ptr, GF_FIRE, 0, 666, 4);
- if (!(is_oppose_fire(player_ptr) || has_resist_fire(player_ptr) || has_immune_fire(player_ptr)))
- take_hit(player_ptr, DAMAGE_NOESCAPE, 50 + randint1(50), _("炎の巻物", "a Scroll of Fire"));
+ fire_ball(this->player_ptr, GF_FIRE, 0, 666, 4);
+ if (!(is_oppose_fire(this->player_ptr) || has_resist_fire(this->player_ptr) || has_immune_fire(this->player_ptr)))
+ take_hit(this->player_ptr, DAMAGE_NOESCAPE, 50 + randint1(50), _("炎の巻物", "a Scroll of Fire"));
ident = true;
break;
}
case SV_SCROLL_ICE: {
- fire_ball(player_ptr, GF_ICE, 0, 777, 4);
- if (!(is_oppose_cold(player_ptr) || has_resist_cold(player_ptr) || has_immune_cold(player_ptr)))
- take_hit(player_ptr, DAMAGE_NOESCAPE, 100 + randint1(100), _("氷の巻物", "a Scroll of Ice"));
+ fire_ball(this->player_ptr, GF_ICE, 0, 777, 4);
+ if (!(is_oppose_cold(this->player_ptr) || has_resist_cold(this->player_ptr) || has_immune_cold(this->player_ptr)))
+ take_hit(this->player_ptr, DAMAGE_NOESCAPE, 100 + randint1(100), _("氷の巻物", "a Scroll of Ice"));
ident = true;
break;
}
case SV_SCROLL_CHAOS: {
- fire_ball(player_ptr, GF_CHAOS, 0, 1000, 4);
- if (!has_resist_chaos(player_ptr))
- take_hit(player_ptr, DAMAGE_NOESCAPE, 111 + randint1(111), _("ログルスの巻物", "a Scroll of Logrus"));
+ fire_ball(this->player_ptr, GF_CHAOS, 0, 1000, 4);
+ if (!has_resist_chaos(this->player_ptr))
+ take_hit(this->player_ptr, DAMAGE_NOESCAPE, 111 + randint1(111), _("ログルスの巻物", "a Scroll of Logrus"));
ident = true;
break;
case SV_SCROLL_RUMOR: {
msg_print(_("巻物にはメッセージが書かれている:", "There is message on the scroll. It says:"));
msg_print(nullptr);
- display_rumor(player_ptr, true);
+ display_rumor(this->player_ptr, true);
msg_print(nullptr);
msg_print(_("巻物は煙を立てて消え去った!", "The scroll disappears in a puff of smoke!"));
ident = true;
}
case SV_SCROLL_ARTIFACT: {
ident = true;
- if (!artifact_scroll(player_ptr))
+ if (!artifact_scroll(this->player_ptr))
used_up = false;
break;
}
case SV_SCROLL_RESET_RECALL: {
ident = true;
- if (!reset_recall(player_ptr))
+ if (!reset_recall(this->player_ptr))
used_up = false;
break;
}
case SV_SCROLL_AMUSEMENT: {
ident = true;
- amusement(player_ptr, player_ptr->y, player_ptr->x, 1, false);
+ amusement(this->player_ptr, this->player_ptr->y, this->player_ptr->x, 1, false);
break;
}
case SV_SCROLL_STAR_AMUSEMENT: {
ident = true;
- amusement(player_ptr, player_ptr->y, player_ptr->x, randint1(2) + 1, false);
+ amusement(this->player_ptr, this->player_ptr->y, this->player_ptr->x, randint1(2) + 1, false);
break;
}
}
msg_print(_("暗闇の中に繋ぎとめる。」", "and in the darkness bind them.'"));
used_up = false;
} else if (o_ptr->tval == TV_PARCHMENT) {
- concptr q;
GAME_TEXT o_name[MAX_NLEN];
char buf[1024];
screen_save();
- q = format("book-%d_jp.txt", o_ptr->sval);
- describe_flavor(player_ptr, o_name, o_ptr, OD_NAME_ONLY);
+ auto q = format("book-%d_jp.txt", o_ptr->sval);
+ describe_flavor(this->player_ptr, o_name, o_ptr, OD_NAME_ONLY);
path_build(buf, sizeof(buf), ANGBAND_DIR_FILE, q);
- (void)show_file(player_ptr, true, buf, o_name, 0, 0);
+ (void)show_file(this->player_ptr, true, buf, o_name, 0, 0);
screen_load();
used_up = false;
}
- BIT_FLAGS inventory_flags = PU_COMBINE | PU_REORDER | (player_ptr->update & PU_AUTODESTROY);
- player_ptr->update &= ~(PU_COMBINE | PU_REORDER | PU_AUTODESTROY);
+ BIT_FLAGS inventory_flags = PU_COMBINE | PU_REORDER | (this->player_ptr->update & PU_AUTODESTROY);
+ this->player_ptr->update &= ~(PU_COMBINE | PU_REORDER | PU_AUTODESTROY);
if (!(o_ptr->is_aware())) {
- chg_virtue(player_ptr, V_PATIENCE, -1);
- chg_virtue(player_ptr, V_CHANCE, 1);
- chg_virtue(player_ptr, V_KNOWLEDGE, -1);
+ chg_virtue(this->player_ptr, V_PATIENCE, -1);
+ chg_virtue(this->player_ptr, V_CHANCE, 1);
+ chg_virtue(this->player_ptr, V_KNOWLEDGE, -1);
}
object_tried(o_ptr);
if (ident && !o_ptr->is_aware()) {
- object_aware(player_ptr, o_ptr);
- gain_exp(player_ptr, (lev + (player_ptr->lev >> 1)) / player_ptr->lev);
+ object_aware(this->player_ptr, o_ptr);
+ gain_exp(this->player_ptr, (lev + (this->player_ptr->lev >> 1)) / this->player_ptr->lev);
}
- player_ptr->window_flags |= PW_INVEN | PW_EQUIP | PW_PLAYER;
- player_ptr->update |= inventory_flags;
+ this->player_ptr->window_flags |= PW_INVEN | PW_EQUIP | PW_PLAYER;
+ this->player_ptr->update |= inventory_flags;
if (!used_up)
return;
sound(SOUND_SCROLL);
- vary_item(player_ptr, item, -1);
+ vary_item(this->player_ptr, this->item, -1);
}