OSDN Git Service

Merge pull request #993 from iks3/fix-imp-food
[hengbandforosx/hengbandosx.git] / src / system / object-type-definition.h
1 #pragma once
2
3 #include "object/tval-types.h"
4 #include "system/angband.h"
5 #include "system/system-variables.h"
6
7 typedef struct object_type {
8     KIND_OBJECT_IDX k_idx; /* Kind index (zero if "dead") */
9     POSITION iy; /* Y-position on map, or zero */
10     POSITION ix; /* X-position on map, or zero */
11     tval_type tval; /* Item type (from kind) */
12
13     OBJECT_SUBTYPE_VALUE sval; /* Item sub-type (from kind) */
14     PARAMETER_VALUE pval; /* Item extra-parameter */
15     DISCOUNT_RATE discount; /* Discount (if any) */
16     ITEM_NUMBER number; /* Number of items */
17     WEIGHT weight; /* Item weight */
18     ARTIFACT_IDX name1; /* Artifact type, if any */
19     EGO_IDX name2; /* Ego-Item type, if any */
20
21     XTRA8 xtra1; /* Extra info type (now unused) */
22     XTRA16 xtra2; /*!< エゴ/アーティファクトの発動ID / Extra info activation index */
23     XTRA8 xtra3; /*!< 複数の使用用途 捕らえたモンスターの速度,付加した特殊なエッセンスID / Extra info for weaponsmith */
24     XTRA16 xtra4; /*!< 複数の使用用途 光源の残り寿命、あるいは捕らえたモンスターの現HP / Extra info fuel or captured monster's current HP */
25     XTRA16 xtra5; /*!< 複数の使用用途 捕らえたモンスターの最大HP / Extra info captured monster's max HP */
26
27     HIT_PROB to_h; /* Plusses to hit */
28     HIT_POINT to_d; /* Plusses to damage */
29     ARMOUR_CLASS to_a; /* Plusses to AC */
30     ARMOUR_CLASS ac; /* Normal AC */
31
32     DICE_NUMBER dd;
33     DICE_SID ds; /* Damage dice/sides */
34     TIME_EFFECT timeout; /* Timeout Counter */
35     byte ident; /* Special flags  */
36     byte marked; /* Object is marked */
37     u16b inscription; /* Inscription index */
38     u16b art_name; /* Artifact name (random artifacts) */
39     byte feeling; /* Game generated inscription number (eg, pseudo-id) */
40
41     BIT_FLAGS art_flags[TR_FLAG_SIZE]; /* Extra Flags for ego and artifacts */
42     BIT_FLAGS curse_flags; /* Flags for curse */
43     MONSTER_IDX held_m_idx; /*!< アイテムを所持しているモンスターID (いないなら 0) / Monster holding us (if any) */
44     ARTIFACT_BIAS_IDX artifact_bias; /*!< ランダムアーティファクト生成時のバイアスID */
45 } object_type;