OSDN Git Service

[Refactor] #37353 clear_creature_bonuses() を calc_bonuses() から分離. / Separated clear_c...
[hengband/hengband.git] / src / perception / identification.c
1 #include "perception/identification.h"
2 #include "art-definition/art-protector-types.h"
3 #include "game-option/special-options.h"
4 #include "io/input-key-acceptor.h"
5 #include "monster-race/monster-race.h"
6 #include "monster-race/race-flags2.h"
7 #include "monster-race/race-indice-types.h"
8 #include "object-enchant/artifact.h"
9 #include "object-enchant/object-ego.h"
10 #include "object-enchant/tr-types.h"
11 #include "object-enchant/trc-types.h"
12 #include "object/object-flags.h"
13 #include "object/object-flavor.h"
14 #include "object/object-hook.h"
15 #include "object/object-kind.h"
16 #include "object/object-info.h"
17 #include "sv-definition/sv-amulet-types.h"
18 #include "sv-definition/sv-other-types.h"
19 #include "sv-definition/sv-ring-types.h"
20 #include "sv-definition/sv-weapon-types.h"
21 #include "term/screen-processor.h"
22 #include "util/bit-flags-calculator.h"
23 #include "util/buffer-shaper.h"
24
25 /*!
26  * @brief オブジェクトの*鑑定*内容を詳述して表示する /
27  * Describe a "fully identified" item
28  * @param player_ptr プレーヤーへの参照ポインタ
29  * @param o_ptr *鑑定*情報を取得する元のオブジェクト構造体参照ポインタ
30  * @param mode 表示オプション
31  * @return 特筆すべき情報が一つでもあった場合TRUE、一つもなく表示がキャンセルされた場合FALSEを返す。
32  */
33 bool screen_object(player_type *player_ptr, object_type *o_ptr, BIT_FLAGS mode)
34 {
35     BIT_FLAGS flgs[TR_FLAG_SIZE];
36     char temp[70 * 20];
37     concptr info[128];
38     GAME_TEXT o_name[MAX_NLEN];
39     char desc[256];
40
41     int trivial_info = 0;
42     object_flags(o_ptr, flgs);
43
44     shape_buffer(o_ptr->name1 ? (a_text + a_info[o_ptr->name1].text) : (k_text + k_info[o_ptr->k_idx].text), 77 - 15, temp, sizeof(temp));
45
46     int i = 0;
47     for (int j = 0; temp[j]; j += 1 + strlen(&temp[j])) {
48         info[i] = &temp[j];
49         i++;
50     }
51
52     if (object_is_equipment(o_ptr)) {
53         trivial_info = i;
54     }
55
56     if (have_flag(flgs, TR_ACTIVATE)) {
57         info[i++] = _("始動したときの効果...", "It can be activated for...");
58         info[i++] = activation_explanation(o_ptr);
59         info[i++] = _("...ただし装備していなければならない。", "...if it is being worn.");
60     }
61
62     if (o_ptr->tval == TV_FIGURINE) {
63         info[i++] = _("それは投げた時ペットに変化する。", "It will transform into a pet when thrown.");
64     }
65
66     if (o_ptr->name1 == ART_STONEMASK) {
67         info[i++] = _("それを装備した者は吸血鬼になる。", "It makes you turn into a vampire permanently.");
68     }
69
70     if ((o_ptr->tval == TV_SWORD) && (o_ptr->sval == SV_POISON_NEEDLE)) {
71         info[i++] = _("それは相手を一撃で倒すことがある。", "It will attempt to kill a monster instantly.");
72     }
73
74     if ((o_ptr->tval == TV_POLEARM) && (o_ptr->sval == SV_DEATH_SCYTHE)) {
75         info[i++] = _("それは自分自身に攻撃が返ってくることがある。", "It causes you to strike yourself sometimes.");
76         info[i++] = _("それは無敵のバリアを切り裂く。", "It always penetrates invulnerability barriers.");
77     }
78
79     if (o_ptr->name2 == EGO_2WEAPON) {
80         info[i++] = _("それは二刀流での命中率を向上させる。", "It affects your ability to hit when you are wielding two weapons.");
81     }
82
83     if (have_flag(flgs, TR_EASY_SPELL)) {
84         info[i++] = _("それは魔法の難易度を下げる。", "It affects your ability to cast spells.");
85     }
86
87     if (o_ptr->name2 == EGO_AMU_FOOL) {
88         info[i++] = _("それは魔法の難易度を上げる。", "It interferes with casting spells.");
89     }
90
91     if (o_ptr->name2 == EGO_RING_THROW) {
92         info[i++] = _("それは物を強く投げることを可能にする。", "It provides great strength when you throw an item.");
93     }
94
95     if (o_ptr->name2 == EGO_AMU_NAIVETY) {
96         info[i++] = _("それは魔法抵抗力を下げる。", "It decreases your magic resistance.");
97     }
98
99     if (o_ptr->tval == TV_STATUE) {
100         monster_race *r_ptr = &r_info[o_ptr->pval];
101         if (o_ptr->pval == MON_BULLGATES)
102             info[i++] = _("それは部屋に飾ると恥ずかしい。", "It is shameful.");
103         else if (r_ptr->flags2 & (RF2_ELDRITCH_HORROR))
104             info[i++] = _("それは部屋に飾ると恐い。", "It is fearful.");
105         else
106             info[i++] = _("それは部屋に飾ると楽しい。", "It is cheerful.");
107     }
108
109     if (o_ptr->name2 == EGO_LITE_DARKNESS)
110         info[i++] = _("それは全く光らない。", "It provides no light.");
111
112     POSITION rad = 0;
113     if (have_flag(flgs, TR_LITE_1) && o_ptr->name2 != EGO_LITE_DARKNESS)
114         rad += 1;
115     if (have_flag(flgs, TR_LITE_2) && o_ptr->name2 != EGO_LITE_DARKNESS)
116         rad += 2;
117     if (have_flag(flgs, TR_LITE_3) && o_ptr->name2 != EGO_LITE_DARKNESS)
118         rad += 3;
119     if (have_flag(flgs, TR_LITE_M1))
120         rad -= 1;
121     if (have_flag(flgs, TR_LITE_M2))
122         rad -= 2;
123     if (have_flag(flgs, TR_LITE_M3))
124         rad -= 3;
125
126     if (o_ptr->name2 == EGO_LITE_SHINE)
127         rad++;
128
129     if (have_flag(flgs, TR_LITE_FUEL) && o_ptr->name2 != EGO_LITE_DARKNESS) {
130         if (rad > 0)
131             sprintf(desc, _("それは燃料補給によって明かり(半径 %d)を授ける。", "It provides light (radius %d) when fueled."), (int)rad);
132     } else {
133         if (rad > 0)
134             sprintf(desc, _("それは永遠なる明かり(半径 %d)を授ける。", "It provides light (radius %d) forever."), (int)rad);
135         if (rad < 0)
136             sprintf(desc, _("それは明かりの半径を狭める(半径に-%d)。", "It decreases radius of light source by %d."), (int)-rad);
137     }
138
139     if (rad != 0)
140         info[i++] = desc;
141
142     if (o_ptr->name2 == EGO_LITE_LONG) {
143         info[i++] = _("それは長いターン明かりを授ける。", "It provides light for much longer time.");
144     }
145
146     if (have_flag(flgs, TR_RIDING)) {
147         if ((o_ptr->tval == TV_POLEARM) && ((o_ptr->sval == SV_LANCE) || (o_ptr->sval == SV_HEAVY_LANCE)))
148             info[i++] = _("それは乗馬中は非常に使いやすい。", "It is made for use while riding.");
149         else {
150             info[i++] = _("それは乗馬中でも使いやすい。", "It is suitable for use while riding.");
151             trivial_info++;
152         }
153     }
154
155     if (have_flag(flgs, TR_STR)) {
156         info[i++] = _("それは腕力に影響を及ぼす。", "It affects your strength.");
157     }
158
159     if (have_flag(flgs, TR_INT)) {
160         info[i++] = _("それは知能に影響を及ぼす。", "It affects your intelligence.");
161     }
162
163     if (have_flag(flgs, TR_WIS)) {
164         info[i++] = _("それは賢さに影響を及ぼす。", "It affects your wisdom.");
165     }
166
167     if (have_flag(flgs, TR_DEX)) {
168         info[i++] = _("それは器用さに影響を及ぼす。", "It affects your dexterity.");
169     }
170
171     if (have_flag(flgs, TR_CON)) {
172         info[i++] = _("それは耐久力に影響を及ぼす。", "It affects your constitution.");
173     }
174
175     if (have_flag(flgs, TR_CHR)) {
176         info[i++] = _("それは魅力に影響を及ぼす。", "It affects your charisma.");
177     }
178
179     if (have_flag(flgs, TR_MAGIC_MASTERY)) {
180         info[i++] = _("それは魔法道具使用能力に影響を及ぼす。", "It affects your ability to use magic devices.");
181     }
182
183     if (have_flag(flgs, TR_STEALTH)) {
184         info[i++] = _("それは隠密行動能力に影響を及ぼす。", "It affects your stealth.");
185     }
186
187     if (have_flag(flgs, TR_SEARCH)) {
188         info[i++] = _("それは探索能力に影響を及ぼす。", "It affects your searching.");
189     }
190
191     if (have_flag(flgs, TR_INFRA)) {
192         info[i++] = _("それは赤外線視力に影響を及ぼす。", "It affects your infravision.");
193     }
194
195     if (have_flag(flgs, TR_TUNNEL)) {
196         info[i++] = _("それは採掘能力に影響を及ぼす。", "It affects your ability to tunnel.");
197     }
198
199     if (have_flag(flgs, TR_SPEED)) {
200         info[i++] = _("それはスピードに影響を及ぼす。", "It affects your speed.");
201     }
202
203     if (have_flag(flgs, TR_BLOWS)) {
204         info[i++] = _("それは打撃回数に影響を及ぼす。", "It affects your attack speed.");
205     }
206
207     if (have_flag(flgs, TR_BRAND_ACID)) {
208         info[i++] = _("それは酸によって大きなダメージを与える。", "It does extra damage from acid.");
209     }
210
211     if (have_flag(flgs, TR_BRAND_ELEC)) {
212         info[i++] = _("それは電撃によって大きなダメージを与える。", "It does extra damage from electricity.");
213     }
214
215     if (have_flag(flgs, TR_BRAND_FIRE)) {
216         info[i++] = _("それは火炎によって大きなダメージを与える。", "It does extra damage from fire.");
217     }
218
219     if (have_flag(flgs, TR_BRAND_COLD)) {
220         info[i++] = _("それは冷気によって大きなダメージを与える。", "It does extra damage from frost.");
221     }
222
223     if (have_flag(flgs, TR_BRAND_POIS)) {
224         info[i++] = _("それは敵を毒する。", "It poisons your foes.");
225     }
226
227     if (have_flag(flgs, TR_CHAOTIC)) {
228         info[i++] = _("それはカオス的な効果を及ぼす。", "It produces chaotic effects.");
229     }
230
231     if (have_flag(flgs, TR_VAMPIRIC)) {
232         info[i++] = _("それは敵から生命力を吸収する。", "It drains life from your foes.");
233     }
234
235     if (have_flag(flgs, TR_IMPACT)) {
236         info[i++] = _("それは地震を起こすことができる。", "It can cause earthquakes.");
237     }
238
239     if (have_flag(flgs, TR_VORPAL)) {
240         info[i++] = _("それは非常に切れ味が鋭く敵を切断することができる。", "It is very sharp and can cut your foes.");
241     }
242
243     if (have_flag(flgs, TR_KILL_DRAGON)) {
244         info[i++] = _("それはドラゴンにとっての天敵である。", "It is a great bane of dragons.");
245     } else if (have_flag(flgs, TR_SLAY_DRAGON)) {
246         info[i++] = _("それはドラゴンに対して特に恐るべき力を発揮する。", "It is especially deadly against dragons.");
247     }
248
249     if (have_flag(flgs, TR_KILL_ORC)) {
250         info[i++] = _("それはオークにとっての天敵である。", "It is a great bane of orcs.");
251     }
252
253     if (have_flag(flgs, TR_SLAY_ORC)) {
254         info[i++] = _("それはオークに対して特に恐るべき力を発揮する。", "It is especially deadly against orcs.");
255     }
256
257     if (have_flag(flgs, TR_KILL_TROLL)) {
258         info[i++] = _("それはトロルにとっての天敵である。", "It is a great bane of trolls.");
259     }
260
261     if (have_flag(flgs, TR_SLAY_TROLL)) {
262         info[i++] = _("それはトロルに対して特に恐るべき力を発揮する。", "It is especially deadly against trolls.");
263     }
264
265     if (have_flag(flgs, TR_KILL_GIANT)) {
266         info[i++] = _("それは巨人にとっての天敵である。", "It is a great bane of giants.");
267     } else if (have_flag(flgs, TR_SLAY_GIANT)) {
268         info[i++] = _("それは巨人に対して特に恐るべき力を発揮する。", "It is especially deadly against giants.");
269     }
270
271     if (have_flag(flgs, TR_KILL_DEMON)) {
272         info[i++] = _("それはデーモンにとっての天敵である。", "It is a great bane of demons.");
273     }
274
275     if (have_flag(flgs, TR_SLAY_DEMON)) {
276         info[i++] = _("それはデーモンに対して聖なる力を発揮する。", "It strikes at demons with holy wrath.");
277     }
278
279     if (have_flag(flgs, TR_KILL_UNDEAD)) {
280         info[i++] = _("それはアンデッドにとっての天敵である。", "It is a great bane of undead.");
281     }
282
283     if (have_flag(flgs, TR_SLAY_UNDEAD)) {
284         info[i++] = _("それはアンデッドに対して聖なる力を発揮する。", "It strikes at undead with holy wrath.");
285     }
286
287     if (have_flag(flgs, TR_KILL_EVIL)) {
288         info[i++] = _("それは邪悪なる存在にとっての天敵である。", "It is a great bane of evil monsters.");
289     }
290
291     if (have_flag(flgs, TR_SLAY_EVIL)) {
292         info[i++] = _("それは邪悪なる存在に対して聖なる力で攻撃する。", "It fights against evil with holy fury.");
293     }
294
295     if (have_flag(flgs, TR_KILL_ANIMAL)) {
296         info[i++] = _("それは自然界の動物にとっての天敵である。", "It is a great bane of natural creatures.");
297     }
298
299     if (have_flag(flgs, TR_SLAY_ANIMAL)) {
300         info[i++] = _("それは自然界の動物に対して特に恐るべき力を発揮する。", "It is especially deadly against natural creatures.");
301     }
302
303     if (have_flag(flgs, TR_KILL_HUMAN)) {
304         info[i++] = _("それは人間にとっての天敵である。", "It is a great bane of humans.");
305     }
306
307     if (have_flag(flgs, TR_SLAY_HUMAN)) {
308         info[i++] = _("それは人間に対して特に恐るべき力を発揮する。", "It is especially deadly against humans.");
309     }
310
311     if (have_flag(flgs, TR_FORCE_WEAPON)) {
312         info[i++] = _("それは使用者の魔力を使って攻撃する。", "It powerfully strikes at a monster using your mana.");
313     }
314
315     if (have_flag(flgs, TR_DEC_MANA)) {
316         info[i++] = _("それは魔力の消費を押さえる。", "It decreases your mana consumption.");
317     }
318
319     if (have_flag(flgs, TR_SUST_STR)) {
320         info[i++] = _("それはあなたの腕力を維持する。", "It sustains your strength.");
321     }
322
323     if (have_flag(flgs, TR_SUST_INT)) {
324         info[i++] = _("それはあなたの知能を維持する。", "It sustains your intelligence.");
325     }
326
327     if (have_flag(flgs, TR_SUST_WIS)) {
328         info[i++] = _("それはあなたの賢さを維持する。", "It sustains your wisdom.");
329     }
330
331     if (have_flag(flgs, TR_SUST_DEX)) {
332         info[i++] = _("それはあなたの器用さを維持する。", "It sustains your dexterity.");
333     }
334
335     if (have_flag(flgs, TR_SUST_CON)) {
336         info[i++] = _("それはあなたの耐久力を維持する。", "It sustains your constitution.");
337     }
338
339     if (have_flag(flgs, TR_SUST_CHR)) {
340         info[i++] = _("それはあなたの魅力を維持する。", "It sustains your charisma.");
341     }
342
343     if (have_flag(flgs, TR_IM_ACID)) {
344         info[i++] = _("それは酸に対する完全な免疫を授ける。", "It provides immunity to acid.");
345     }
346
347     if (have_flag(flgs, TR_IM_ELEC)) {
348         info[i++] = _("それは電撃に対する完全な免疫を授ける。", "It provides immunity to electricity.");
349     }
350
351     if (have_flag(flgs, TR_IM_FIRE)) {
352         info[i++] = _("それは火に対する完全な免疫を授ける。", "It provides immunity to fire.");
353     }
354
355     if (have_flag(flgs, TR_IM_COLD)) {
356         info[i++] = _("それは寒さに対する完全な免疫を授ける。", "It provides immunity to cold.");
357     }
358
359     if (have_flag(flgs, TR_THROW)) {
360         info[i++] = _("それは敵に投げて大きなダメージを与えることができる。", "It is perfectly balanced for throwing.");
361     }
362
363     if (have_flag(flgs, TR_FREE_ACT)) {
364         info[i++] = _("それは麻痺に対する完全な免疫を授ける。", "It provides immunity to paralysis.");
365     }
366
367     if (have_flag(flgs, TR_HOLD_EXP)) {
368         info[i++] = _("それは経験値吸収に対する耐性を授ける。", "It provides resistance to experience draining.");
369     }
370
371     if (have_flag(flgs, TR_RES_FEAR)) {
372         info[i++] = _("それは恐怖への完全な耐性を授ける。", "It makes you completely fearless.");
373     }
374
375     if (have_flag(flgs, TR_RES_ACID)) {
376         info[i++] = _("それは酸への耐性を授ける。", "It provides resistance to acid.");
377     }
378
379     if (have_flag(flgs, TR_RES_ELEC)) {
380         info[i++] = _("それは電撃への耐性を授ける。", "It provides resistance to electricity.");
381     }
382
383     if (have_flag(flgs, TR_RES_FIRE)) {
384         info[i++] = _("それは火への耐性を授ける。", "It provides resistance to fire.");
385     }
386
387     if (have_flag(flgs, TR_RES_COLD)) {
388         info[i++] = _("それは寒さへの耐性を授ける。", "It provides resistance to cold.");
389     }
390
391     if (have_flag(flgs, TR_RES_POIS)) {
392         info[i++] = _("それは毒への耐性を授ける。", "It provides resistance to poison.");
393     }
394
395     if (have_flag(flgs, TR_RES_LITE)) {
396         info[i++] = _("それは閃光への耐性を授ける。", "It provides resistance to light.");
397     }
398
399     if (have_flag(flgs, TR_RES_DARK)) {
400         info[i++] = _("それは暗黒への耐性を授ける。", "It provides resistance to dark.");
401     }
402
403     if (have_flag(flgs, TR_RES_BLIND)) {
404         info[i++] = _("それは盲目への耐性を授ける。", "It provides resistance to blindness.");
405     }
406
407     if (have_flag(flgs, TR_RES_CONF)) {
408         info[i++] = _("それは混乱への耐性を授ける。", "It provides resistance to confusion.");
409     }
410
411     if (have_flag(flgs, TR_RES_SOUND)) {
412         info[i++] = _("それは轟音への耐性を授ける。", "It provides resistance to sound.");
413     }
414
415     if (have_flag(flgs, TR_RES_SHARDS)) {
416         info[i++] = _("それは破片への耐性を授ける。", "It provides resistance to shards.");
417     }
418
419     if (have_flag(flgs, TR_RES_NETHER)) {
420         info[i++] = _("それは地獄への耐性を授ける。", "It provides resistance to nether.");
421     }
422
423     if (have_flag(flgs, TR_RES_NEXUS)) {
424         info[i++] = _("それは因果混乱への耐性を授ける。", "It provides resistance to nexus.");
425     }
426
427     if (have_flag(flgs, TR_RES_CHAOS)) {
428         info[i++] = _("それはカオスへの耐性を授ける。", "It provides resistance to chaos.");
429     }
430
431     if (have_flag(flgs, TR_RES_DISEN)) {
432         info[i++] = _("それは劣化への耐性を授ける。", "It provides resistance to disenchantment.");
433     }
434
435     if (have_flag(flgs, TR_LEVITATION)) {
436         info[i++] = _("それは宙に浮くことを可能にする。", "It allows you to levitate.");
437     }
438
439     if (have_flag(flgs, TR_SEE_INVIS)) {
440         info[i++] = _("それは透明なモンスターを見ることを可能にする。", "It allows you to see invisible monsters.");
441     }
442
443     if (have_flag(flgs, TR_TELEPATHY)) {
444         info[i++] = _("それはテレパシー能力を授ける。", "It gives telepathic powers.");
445     }
446
447     if (have_flag(flgs, TR_ESP_ANIMAL)) {
448         info[i++] = _("それは自然界の生物を感知する。", "It senses natural creatures.");
449     }
450
451     if (have_flag(flgs, TR_ESP_UNDEAD)) {
452         info[i++] = _("それはアンデッドを感知する。", "It senses undead.");
453     }
454
455     if (have_flag(flgs, TR_ESP_DEMON)) {
456         info[i++] = _("それは悪魔を感知する。", "It senses demons.");
457     }
458
459     if (have_flag(flgs, TR_ESP_ORC)) {
460         info[i++] = _("それはオークを感知する。", "It senses orcs.");
461     }
462
463     if (have_flag(flgs, TR_ESP_TROLL)) {
464         info[i++] = _("それはトロルを感知する。", "It senses trolls.");
465     }
466
467     if (have_flag(flgs, TR_ESP_GIANT)) {
468         info[i++] = _("それは巨人を感知する。", "It senses giants.");
469     }
470
471     if (have_flag(flgs, TR_ESP_DRAGON)) {
472         info[i++] = _("それはドラゴンを感知する。", "It senses dragons.");
473     }
474
475     if (have_flag(flgs, TR_ESP_HUMAN)) {
476         info[i++] = _("それは人間を感知する。", "It senses humans.");
477     }
478
479     if (have_flag(flgs, TR_ESP_EVIL)) {
480         info[i++] = _("それは邪悪な存在を感知する。", "It senses evil creatures.");
481     }
482
483     if (have_flag(flgs, TR_ESP_GOOD)) {
484         info[i++] = _("それは善良な存在を感知する。", "It senses good creatures.");
485     }
486
487     if (have_flag(flgs, TR_ESP_NONLIVING)) {
488         info[i++] = _("それは活動する無生物体を感知する。", "It senses non-living creatures.");
489     }
490
491     if (have_flag(flgs, TR_ESP_UNIQUE)) {
492         info[i++] = _("それは特別な強敵を感知する。", "It senses unique monsters.");
493     }
494
495     if (have_flag(flgs, TR_SLOW_DIGEST)) {
496         info[i++] = _("それはあなたの新陳代謝を遅くする。", "It slows your metabolism.");
497     }
498
499     if (have_flag(flgs, TR_REGEN)) {
500         info[i++] = _("それは体力回復力を強化する。", "It speeds your regenerative powers.");
501     }
502
503     if (have_flag(flgs, TR_WARNING)) {
504         info[i++] = _("それは危険に対して警告を発する。", "It warns you of danger");
505     }
506
507     if (have_flag(flgs, TR_REFLECT)) {
508         info[i++] = _("それは矢の呪文を反射する。", "It reflects bolt spells.");
509     }
510
511     if (have_flag(flgs, TR_SH_FIRE)) {
512         info[i++] = _("それは炎のバリアを張る。", "It produces a fiery sheath.");
513     }
514
515     if (have_flag(flgs, TR_SH_ELEC)) {
516         info[i++] = _("それは電気のバリアを張る。", "It produces an electric sheath.");
517     }
518
519     if (have_flag(flgs, TR_SH_COLD)) {
520         info[i++] = _("それは冷気のバリアを張る。", "It produces a sheath of coldness.");
521     }
522
523     if (have_flag(flgs, TR_NO_MAGIC)) {
524         info[i++] = _("それは反魔法バリアを張る。", "It produces an anti-magic shell.");
525     }
526
527     if (have_flag(flgs, TR_NO_TELE)) {
528         info[i++] = _("それはテレポートを邪魔する。", "It prevents teleportation.");
529     }
530
531     if (have_flag(flgs, TR_XTRA_MIGHT)) {
532         info[i++] = _("それは矢/ボルト/弾をより強力に発射することができる。", "It fires missiles with extra might.");
533     }
534
535     if (have_flag(flgs, TR_XTRA_SHOTS)) {
536         info[i++] = _("それは矢/ボルト/弾を非常に早く発射することができる。", "It fires missiles excessively fast.");
537     }
538
539     if (have_flag(flgs, TR_BLESSED)) {
540         info[i++] = _("それは神に祝福されている。", "It has been blessed by the gods.");
541     }
542
543     if (object_is_cursed(o_ptr)) {
544         if (o_ptr->curse_flags & TRC_PERMA_CURSE) {
545             info[i++] = _("それは永遠の呪いがかけられている。", "It is permanently cursed.");
546         } else if (o_ptr->curse_flags & TRC_HEAVY_CURSE) {
547             info[i++] = _("それは強力な呪いがかけられている。", "It is heavily cursed.");
548         } else {
549             info[i++] = _("それは呪われている。", "It is cursed.");
550
551             /*
552              * It's a trivial infomation since there is
553              * fake inscription {cursed}
554              */
555             trivial_info++;
556         }
557     }
558
559     if ((have_flag(flgs, TR_TY_CURSE)) || (o_ptr->curse_flags & TRC_TY_CURSE)) {
560         info[i++] = _("それは太古の禍々しい怨念が宿っている。", "It carries an ancient foul curse.");
561     }
562
563     if ((have_flag(flgs, TR_AGGRAVATE)) || (o_ptr->curse_flags & TRC_AGGRAVATE)) {
564         info[i++] = _("それは付近のモンスターを怒らせる。", "It aggravates nearby creatures.");
565     }
566
567     if ((have_flag(flgs, TR_DRAIN_EXP)) || (o_ptr->curse_flags & TRC_DRAIN_EXP)) {
568         info[i++] = _("それは経験値を吸い取る。", "It drains experience.");
569     }
570
571     if (o_ptr->curse_flags & TRC_SLOW_REGEN) {
572         info[i++] = _("それは回復力を弱める。", "It slows your regenerative powers.");
573     }
574
575     if ((o_ptr->curse_flags & TRC_ADD_L_CURSE) || have_flag(flgs, TR_ADD_L_CURSE)) {
576         info[i++] = _("それは弱い呪いを増やす。", "It adds weak curses.");
577     }
578
579     if ((o_ptr->curse_flags & TRC_ADD_H_CURSE) || have_flag(flgs, TR_ADD_H_CURSE)) {
580         info[i++] = _("それは強力な呪いを増やす。", "It adds heavy curses.");
581     }
582
583     if ((have_flag(flgs, TR_CALL_ANIMAL)) || (o_ptr->curse_flags & TRC_CALL_ANIMAL)) {
584         info[i++] = _("それは動物を呼び寄せる。", "It attracts animals.");
585     }
586
587     if ((have_flag(flgs, TR_CALL_DEMON)) || (o_ptr->curse_flags & TRC_CALL_DEMON)) {
588         info[i++] = _("それは悪魔を呼び寄せる。", "It attracts demons.");
589     }
590
591     if ((have_flag(flgs, TR_CALL_DRAGON)) || (o_ptr->curse_flags & TRC_CALL_DRAGON)) {
592         info[i++] = _("それはドラゴンを呼び寄せる。", "It attracts dragons.");
593     }
594
595     if ((have_flag(flgs, TR_CALL_UNDEAD)) || (o_ptr->curse_flags & TRC_CALL_UNDEAD)) {
596         info[i++] = _("それは死霊を呼び寄せる。", "It attracts undeads.");
597     }
598
599     if ((have_flag(flgs, TR_COWARDICE)) || (o_ptr->curse_flags & TRC_COWARDICE)) {
600         info[i++] = _("それは恐怖感を引き起こす。", "It makes you subject to cowardice.");
601     }
602
603     if ((have_flag(flgs, TR_TELEPORT)) || (o_ptr->curse_flags & TRC_TELEPORT)) {
604         info[i++] = _("それはランダムなテレポートを引き起こす。", "It induces random teleportation.");
605     }
606
607     if ((have_flag(flgs, TR_LOW_MELEE)) || o_ptr->curse_flags & TRC_LOW_MELEE) {
608         info[i++] = _("それは攻撃を外しやすい。", "It causes you to miss blows.");
609     }
610
611     if ((have_flag(flgs, TR_LOW_AC)) || (o_ptr->curse_flags & TRC_LOW_AC)) {
612         info[i++] = _("それは攻撃を受けやすい。", "It helps your enemies' blows.");
613     }
614
615     if ((have_flag(flgs, TR_LOW_MAGIC)) || (o_ptr->curse_flags & TRC_LOW_MAGIC)) {
616         info[i++] = _("それは魔法を唱えにくくする。", "It encumbers you while spellcasting.");
617     }
618
619     if ((have_flag(flgs, TR_FAST_DIGEST)) || (o_ptr->curse_flags & TRC_FAST_DIGEST)) {
620         info[i++] = _("それはあなたの新陳代謝を速くする。", "It speeds your metabolism.");
621     }
622
623     if ((have_flag(flgs, TR_DRAIN_HP)) || (o_ptr->curse_flags & TRC_DRAIN_HP)) {
624         info[i++] = _("それはあなたの体力を吸い取る。", "It drains you.");
625     }
626
627     if ((have_flag(flgs, TR_DRAIN_MANA)) || (o_ptr->curse_flags & TRC_DRAIN_MANA)) {
628         info[i++] = _("それはあなたの魔力を吸い取る。", "It drains your mana.");
629     }
630
631     if (mode & SCROBJ_FAKE_OBJECT) {
632         switch (o_ptr->tval) {
633         case TV_RING:
634             switch (o_ptr->sval) {
635             case SV_RING_LORDLY:
636                 info[i++] = _("それは幾つかのランダムな耐性を授ける。", "It provides some random resistances.");
637                 break;
638             case SV_RING_WARNING:
639                 info[i++] = _("それはひとつの低級なESPを授ける事がある。", "It may provide a low rank ESP.");
640                 break;
641             }
642
643             break;
644
645         case TV_AMULET:
646             switch (o_ptr->sval) {
647             case SV_AMULET_RESISTANCE:
648                 info[i++] = _("それは毒への耐性を授ける事がある。", "It may provides resistance to poison.");
649                 info[i++] = _("それはランダムな耐性を授ける事がある。", "It may provide a random resistances.");
650                 break;
651             case SV_AMULET_THE_MAGI:
652                 info[i++] = _("それは最大で3つまでの低級なESPを授ける。", "It provides up to three low rank ESPs.");
653                 break;
654             }
655
656             break;
657         }
658     }
659
660     if (have_flag(flgs, TR_IGNORE_ACID) && have_flag(flgs, TR_IGNORE_ELEC) && have_flag(flgs, TR_IGNORE_FIRE) && have_flag(flgs, TR_IGNORE_COLD)) {
661         info[i++] = _("それは酸・電撃・火炎・冷気では傷つかない。", "It cannot be harmed by the elements.");
662     } else {
663         if (have_flag(flgs, TR_IGNORE_ACID)) {
664             info[i++] = _("それは酸では傷つかない。", "It cannot be harmed by acid.");
665         }
666
667         if (have_flag(flgs, TR_IGNORE_ELEC)) {
668             info[i++] = _("それは電撃では傷つかない。", "It cannot be harmed by electricity.");
669         }
670
671         if (have_flag(flgs, TR_IGNORE_FIRE)) {
672             info[i++] = _("それは火炎では傷つかない。", "It cannot be harmed by fire.");
673         }
674
675         if (have_flag(flgs, TR_IGNORE_COLD)) {
676             info[i++] = _("それは冷気では傷つかない。", "It cannot be harmed by cold.");
677         }
678     }
679
680     if (mode & SCROBJ_FORCE_DETAIL)
681         trivial_info = 0;
682
683     if (i <= trivial_info)
684         return FALSE;
685
686     screen_save();
687     int wid, hgt;
688     Term_get_size(&wid, &hgt);
689
690     if (!(mode & SCROBJ_FAKE_OBJECT))
691         object_desc(player_ptr, o_name, o_ptr, 0);
692     else
693         object_desc(player_ptr, o_name, o_ptr, (OD_NAME_ONLY | OD_STORE));
694
695     prt(o_name, 0, 0);
696     for (int k = 1; k < hgt; k++) {
697         prt("", k, 13);
698     }
699
700     if ((o_ptr->tval == TV_STATUE) && (o_ptr->sval == SV_PHOTO)) {
701         monster_race *r_ptr = &r_info[o_ptr->pval];
702         int namelen = strlen(r_name + r_ptr->name);
703         prt(format("%s: '", r_name + r_ptr->name), 1, 15);
704         Term_queue_bigchar(18 + namelen, 1, r_ptr->x_attr, r_ptr->x_char, 0, 0);
705         prt("'", 1, (use_bigtile ? 20 : 19) + namelen);
706     } else {
707         prt(_("     アイテムの能力:", "     Item Attributes:"), 1, 15);
708     }
709
710     int k = 2;
711     for (int j = 0; j < i; j++) {
712         prt(info[j], k++, 15);
713         if ((k == hgt - 2) && (j + 1 < i)) {
714             prt(_("-- 続く --", "-- more --"), k, 15);
715             inkey();
716             for (; k > 2; k--)
717                 prt("", k, 15);
718         }
719     }
720
721     prt(_("[何かキーを押すとゲームに戻ります]", "[Press any key to continue]"), k, 15);
722     inkey();
723     screen_load();
724     return TRUE;
725 }