#include "angband.h"
#include "core.h"
#include "util.h"
-#include "autopick.h"
-#include "term.h"
+#include "main/sound-definitions-table.h"
+#include "gameterm.h"
#include "selfinfo.h"
#include "cmd-activate.h"
#include "player-class.h"
#include "player-personality.h"
#include "monster.h"
-#include "view-mainwindow.h"
+#include "view/display-main-window.h"
#include "spells.h"
-#include "objectkind.h"
-#include "autopick.h"
+#include "object/object-kind.h"
+#include "autopick/autopick.h"
#include "targeting.h"
#include "snipe.h"
#include "player-race.h"
-#include "view-mainwindow.h"
+#include "view/display-main-window.h"
#include "player-inventory.h"
/*!
command_wrk = FALSE;
if (easy_floor) command_wrk = (USE_INVEN);
screen_save();
- (void)show_inven(creature_ptr, 0, USE_FULL, 0);
+ (void)show_inventory(creature_ptr, 0, USE_FULL, 0);
#ifdef JP
sprintf(out_val, "持ち物: 合計 %3d.%1d kg (限界の%ld%%) コマンド: ",
if (easy_floor) command_wrk = (USE_EQUIP);
screen_save();
- (void)show_equip(creature_ptr, 0, USE_FULL, 0);
+ (void)show_equipment(creature_ptr, 0, USE_FULL, 0);
#ifdef JP
sprintf(out_val, "装備: 合計 %3d.%1d kg (限界の%ld%%) コマンド: ",
/* Prevent wielding into a cursed slot */
if (object_is_cursed(&creature_ptr->inventory_list[slot]))
{
- object_desc(o_name, &creature_ptr->inventory_list[slot], (OD_OMIT_PREFIX | OD_NAME_ONLY));
+ object_desc(creature_ptr, o_name, &creature_ptr->inventory_list[slot], (OD_OMIT_PREFIX | OD_NAME_ONLY));
#ifdef JP
- msg_format("%s%sは呪われているようだ。", describe_use(slot) , o_name );
+ msg_format("%s%sは呪われているようだ。", describe_use(creature_ptr, slot), o_name);
#else
- msg_format("The %s you are %s appears to be cursed.", o_name, describe_use(slot));
+ msg_format("The %s you are %s appears to be cursed.", o_name, describe_use(creature_ptr, slot));
#endif
return;
}
{
char dummy[MAX_NLEN+80];
- object_desc(o_name, o_ptr, (OD_OMIT_PREFIX | OD_NAME_ONLY));
+ object_desc(creature_ptr, o_name, o_ptr, (OD_OMIT_PREFIX | OD_NAME_ONLY));
sprintf(dummy, _("本当に%s{呪われている}を使いますか?", "Really use the %s {cursed}? "), o_name);
if (!get_check(dummy)) return;
{
char dummy[MAX_NLEN+100];
- object_desc(o_name, o_ptr, (OD_OMIT_PREFIX | OD_NAME_ONLY));
+ object_desc(creature_ptr, o_name, o_ptr, (OD_OMIT_PREFIX | OD_NAME_ONLY));
sprintf(dummy, _("%sを装備すると吸血鬼になります。よろしいですか?",
"%s will transforms you into a vampire permanently when equiped. Do you become a vampire?"), o_name);
object_type *otmp_ptr = &object_tmp;
GAME_TEXT switch_name[MAX_NLEN];
- object_desc(switch_name, switch_o_ptr, (OD_OMIT_PREFIX | OD_NAME_ONLY));
+ object_desc(creature_ptr, switch_name, switch_o_ptr, (OD_OMIT_PREFIX | OD_NAME_ONLY));
object_copy(otmp_ptr, switch_o_ptr);
object_copy(switch_o_ptr, slot_o_ptr);
else
{
floor_item_increase(creature_ptr->current_floor_ptr, 0 - item, -1);
- floor_item_optimize(creature_ptr->current_floor_ptr, 0 - item);
+ floor_item_optimize(creature_ptr, 0 - item);
}
/* Access the wield slot */
switch (slot)
{
case INVEN_RARM:
- if (object_allow_two_hands_wielding(o_ptr) && (empty_hands(creature_ptr, FALSE) == EMPTY_HAND_LARM) && CAN_TWO_HANDS_WIELDING())
+ if (object_allow_two_hands_wielding(o_ptr) && (empty_hands(creature_ptr, FALSE) == EMPTY_HAND_LARM) && can_two_hands_wielding(creature_ptr))
act = STR_WIELD_ARMS;
else
act = (left_hander ? STR_WIELD_LARM : STR_WIELD_RARM);
break;
case INVEN_LARM:
- if (object_allow_two_hands_wielding(o_ptr) && (empty_hands(creature_ptr, FALSE) == EMPTY_HAND_RARM) && CAN_TWO_HANDS_WIELDING())
+ if (object_allow_two_hands_wielding(o_ptr) && (empty_hands(creature_ptr, FALSE) == EMPTY_HAND_RARM) && can_two_hands_wielding(creature_ptr))
act = STR_WIELD_ARMS;
else
act = (left_hander ? STR_WIELD_RARM : STR_WIELD_LARM);
break;
}
- object_desc(o_name, o_ptr, 0);
+ object_desc(creature_ptr, o_name, o_ptr, 0);
msg_format(act, o_name, index_to_label(slot));
/* Cursed! */
calc_android_exp(creature_ptr);
}
+
/*!
* @brief 持ち替え処理
+ * @param owner_ptr プレーヤーへの参照ポインタ
* @param item 持ち替えを行いたい装備部位ID
* @return なし
*/
if (!has_melee_weapon(owner_ptr, INVEN_LARM)) return;
o_ptr = &owner_ptr->inventory_list[INVEN_LARM];
- object_desc(o_name, o_ptr, 0);
+ object_desc(owner_ptr, o_name, o_ptr, 0);
if (object_is_cursed(o_ptr))
{
- if (object_allow_two_hands_wielding(o_ptr) && CAN_TWO_HANDS_WIELDING())
+ if (object_allow_two_hands_wielding(o_ptr) && can_two_hands_wielding(owner_ptr))
msg_format(_("%sを両手で構えた。", "You are wielding %s with both hands."), o_name);
return;
}
owner_ptr->total_weight += o_ptr->weight;
inven_item_increase(owner_ptr, INVEN_LARM, -((int)o_ptr->number));
inven_item_optimize(owner_ptr, INVEN_LARM);
- if (object_allow_two_hands_wielding(o_ptr) && CAN_TWO_HANDS_WIELDING())
+ if (object_allow_two_hands_wielding(o_ptr) && can_two_hands_wielding(owner_ptr))
msg_format(_("%sを両手で構えた。", "You are wielding %s with both hands."), o_name);
else
msg_format(_("%sを%sで構えた。", "You are wielding %s in your %s hand."), o_name,
if (item != INVEN_LARM) return;
o_ptr = &owner_ptr->inventory_list[INVEN_RARM];
- if (o_ptr->k_idx) object_desc(o_name, o_ptr, 0);
+ if (o_ptr->k_idx) object_desc(owner_ptr, o_name, o_ptr, 0);
if (has_melee_weapon(owner_ptr, INVEN_RARM))
{
- if (object_allow_two_hands_wielding(o_ptr) && CAN_TWO_HANDS_WIELDING())
+ if (object_allow_two_hands_wielding(o_ptr) && can_two_hands_wielding(owner_ptr))
msg_format(_("%sを両手で構えた。", "You are wielding %s with both hands."), o_name);
return;
}
if (((o_ptr->curse_flags & TRC_HEAVY_CURSE) && one_in_(7)) || one_in_(4))
{
- msg_print(_("呪われた装備を力づくで剥がした!", "You teared a cursed equipment off by sheer strength!"));
+ msg_print(_("呪われた装備を力づくで剥がした!", "You tore off a piece of cursed equipment by sheer strength!"));
o_ptr->ident |= (IDENT_SENSE);
o_ptr->curse_flags = 0L;
/* Verify unless quantity given beforehand */
if (!force && (confirm_destroy || (object_value(o_ptr) > 0)))
{
- object_desc(o_name, o_ptr, OD_OMIT_PREFIX);
+ object_desc(creature_ptr, o_name, o_ptr, OD_OMIT_PREFIX);
/* Make a verification */
sprintf(out_val, _("本当に%sを壊しますか? [y/n/Auto]", "Really destroy %s? [y/n/Auto]"), o_name);
old_number = o_ptr->number;
o_ptr->number = amt;
- object_desc(o_name, o_ptr, 0);
+ object_desc(creature_ptr, o_name, o_ptr, 0);
o_ptr->number = old_number;
take_turn(creature_ptr, 100);
if (!o_ptr) return;
/* Require full knowledge */
- if (!(o_ptr->ident & IDENT_MENTAL))
+ if (!OBJECT_IS_FULL_KNOWN(o_ptr))
{
msg_print(_("このアイテムについて特に知っていることはない。", "You have no special knowledge about that item."));
return;
}
- object_desc(o_name, o_ptr, 0);
+ object_desc(creature_ptr, o_name, o_ptr, 0);
msg_format(_("%sを調べている...", "Examining %s..."), o_name);
- if (!screen_object(o_ptr, SCROBJ_FORCE_DETAIL)) msg_print(_("特に変わったところはないようだ。", "You see nothing special."));
+ if (!screen_object(creature_ptr, o_ptr, SCROBJ_FORCE_DETAIL)) msg_print(_("特に変わったところはないようだ。", "You see nothing special."));
}
if (!o_ptr) return;
/* Describe the activity */
- object_desc(o_name, o_ptr, OD_OMIT_INSCRIPTION);
+ object_desc(creature_ptr, o_name, o_ptr, OD_OMIT_INSCRIPTION);
msg_format(_("%sに銘を刻む。", "Inscribing %s."), o_name);
msg_print(NULL);
else if ((o_ptr->name2 == EGO_LITE_DARKNESS) || (j_ptr->name2 == EGO_LITE_DARKNESS))
{
j_ptr->xtra4 = 0;
- msg_print(_("しかし松明は全く光らない。", "Curiously, your torche don't light."));
+ msg_print(_("しかし松明は全く光らない。", "Curiously, your torch doesn't light."));
}
/* Over-fuel message */
else if (j_ptr->xtra4 >= FUEL_TORCH)
if (!dir) break;
/* Apply the motion */
- if (change_panel(ddy[dir], ddx[dir]))
+ if (change_panel(creature_ptr, ddy[dir], ddx[dir]))
{
y2 = panel_row_min;
x2 = panel_col_min;
/* Recenter the map around the player */
- verify_panel();
+ verify_panel(creature_ptr);
creature_ptr->update |= (PU_MONSTERS);
creature_ptr->redraw |= (PR_MAP);
r_idx = who[i];
/* Hack -- Auto-recall */
- monster_race_track(r_idx);
+ monster_race_track(creature_ptr, r_idx);
handle_stuff(creature_ptr);
/* Interact */
screen_save();
/* Recall on screen */
- screen_roff(who[i], 0);
+ screen_roff(creature_ptr, who[i], 0);
}
/* Hack -- Begin the prompt */