OSDN Git Service

fix #37913
[jnethack/source.git] / include / artilistj.h
1 /* NetHack 3.6  artilist.h      $NHDT-Date: 1433050874 2015/05/31 05:41:14 $  $NHDT-Branch: master $:$NHDT-Revision: 1.16 $ */
2 /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
3 /* NetHack may be freely redistributed.  See license for details. */
4
5 /*JP:
6   artilist.h \82Í makedefs.c \82Æ artifact.c \82©\82ç\93Ç\82Ý\8d\9e\82Ü\82ê\82é\81B
7   makedefs.c \82Å\82Í\89p\8cê\82Ì\82Ü\82Ü\82É\82µ\82Ä\82¨\82­\95K\97v\82ª\82 \82é\82Ì\82Å\81Aartilistj.h \82É\95ª\97£\81B
8 */
9
10 #ifdef MAKEDEFS_C
11 /* in makedefs.c, all we care about is the list of names */
12
13 #define A(nam, typ, s1, s2, mt, atk, dfn, cry, inv, al, cl, rac, cost, clr) nam
14
15 static const char *artifact_names[] = {
16 #else
17 /* in artifact.c, set up the actual artifact list structure */
18
19 #define A(nam, typ, s1, s2, mt, atk, dfn, cry, inv, al, cl, rac, cost, clr) \
20     {                                                                       \
21         typ, nam, s1, s2, mt, atk, dfn, cry, inv, al, cl, rac, cost, clr    \
22     }
23
24 /* clang-format off */
25 #define     NO_ATTK     {0,0,0,0}               /* no attack */
26 #define     NO_DFNS     {0,0,0,0}               /* no defense */
27 #define     NO_CARY     {0,0,0,0}               /* no carry effects */
28 #define     DFNS(c)     {0,c,0,0}
29 #define     CARY(c)     {0,c,0,0}
30 #define     PHYS(a,b)   {0,AD_PHYS,a,b}         /* physical */
31 #define     DRLI(a,b)   {0,AD_DRLI,a,b}         /* life drain */
32 #define     COLD(a,b)   {0,AD_COLD,a,b}
33 #define     FIRE(a,b)   {0,AD_FIRE,a,b}
34 #define     ELEC(a,b)   {0,AD_ELEC,a,b}         /* electrical shock */
35 #define     STUN(a,b)   {0,AD_STUN,a,b}         /* magical attack */
36 /* clang-format on */
37
38 STATIC_OVL NEARDATA struct artifact artilist[] = {
39 #endif /* MAKEDEFS_C */
40
41     /* Artifact cost rationale:
42      * 1.  The more useful the artifact, the better its cost.
43      * 2.  Quest artifacts are highly valued.
44      * 3.  Chaotic artifacts are inflated due to scarcity (and balance).
45      */
46
47     /*  dummy element #0, so that all interesting indices are non-zero */
48     A("", STRANGE_OBJECT, 0, 0, 0, NO_ATTK, NO_DFNS, NO_CARY, 0, A_NONE,
49       NON_PM, NON_PM, 0L, NO_COLOR),
50
51     A("\83G\83N\83X\83J\83\8a\83o\81[", LONG_SWORD, (SPFX_NOGEN | SPFX_RESTR | SPFX_SEEK
52                                 | SPFX_DEFN | SPFX_INTEL | SPFX_SEARCH),
53       0, 0, PHYS(5, 10), DRLI(0, 0), NO_CARY, 0, A_LAWFUL, PM_KNIGHT, NON_PM,
54       4000L, NO_COLOR),
55     /*
56      *      Stormbringer only has a 2 because it can drain a level,
57      *      providing 8 more.
58      */
59     A("\83X\83g\81[\83\80\83u\83\8a\83\93\83K\81[", RUNESWORD,
60       (SPFX_RESTR | SPFX_ATTK | SPFX_DEFN | SPFX_INTEL | SPFX_DRLI), 0, 0,
61       DRLI(5, 2), DRLI(0, 0), NO_CARY, 0, A_CHAOTIC, NON_PM, NON_PM, 8000L,
62       NO_COLOR),
63     /*
64      *      Mjollnir will return to the hand of the wielder when thrown
65      *      if the wielder is a Valkyrie wearing Gauntlets of Power.
66      */
67     A("\83~\83\85\83\8b\83j\81[\83\8b", WAR_HAMMER, /* Mjo:llnir */
68       (SPFX_RESTR | SPFX_ATTK), 0, 0, ELEC(5, 24), NO_DFNS, NO_CARY, 0,
69       A_NEUTRAL, PM_VALKYRIE, NON_PM, 4000L, NO_COLOR),
70
71     A("\83N\83\8a\81[\83o\81[", BATTLE_AXE, SPFX_RESTR, 0, 0, PHYS(3, 6), NO_DFNS, NO_CARY,
72       0, A_NEUTRAL, PM_BARBARIAN, NON_PM, 1500L, NO_COLOR),
73
74     /*
75      *      Grimtooth glows in warning when elves are present, but its
76      *      damage bonus applies to all targets rather than just elves
77      *      (handled as special case in spec_dbon()).
78      */
79     A("\83O\83\8a\83\80\83g\83D\81[\83X", ORCISH_DAGGER, (SPFX_RESTR | SPFX_WARN | SPFX_DFLAG2),
80       0, M2_ELF, PHYS(2, 6), NO_DFNS,
81       NO_CARY, 0, A_CHAOTIC, NON_PM, PM_ORC, 300L, CLR_RED),
82     /*
83      *      Orcrist and Sting have same alignment as elves.
84      *
85      *      The combination of SPFX_WARN+SPFX_DFLAG2+M2_value will trigger
86      *      EWarn_of_mon for all monsters that have the M2_value flag.
87      *      Sting and Orcrist will warn of M2_ORC monsters.
88      */
89     A("\83I\81[\83N\83\8a\83X\83g", ELVEN_BROADSWORD, (SPFX_WARN | SPFX_DFLAG2), 0, M2_ORC,
90       PHYS(5, 0), NO_DFNS, NO_CARY, 0, A_CHAOTIC, NON_PM, PM_ELF, 2000L,
91       CLR_BRIGHT_BLUE), /* bright blue is actually light blue */
92
93     A("\83X\83e\83B\83\93\83O", ELVEN_DAGGER, (SPFX_WARN | SPFX_DFLAG2), 0, M2_ORC, PHYS(5, 0),
94       NO_DFNS, NO_CARY, 0, A_CHAOTIC, NON_PM, PM_ELF, 800L, CLR_BRIGHT_BLUE),
95     /*
96      *      Magicbane is a bit different!  Its magic fanfare
97      *      unbalances victims in addition to doing some damage.
98      */
99     A("\83}\83W\83b\83N\83x\81[\83\93", ATHAME, (SPFX_RESTR | SPFX_ATTK | SPFX_DEFN), 0, 0,
100       STUN(3, 4), DFNS(AD_MAGM), NO_CARY, 0, A_NEUTRAL, PM_WIZARD, NON_PM,
101       3500L, NO_COLOR),
102
103     A("\83t\83\8d\83X\83g\83u\83\89\83\93\83h", LONG_SWORD, (SPFX_RESTR | SPFX_ATTK | SPFX_DEFN), 0, 0,
104       COLD(5, 0), COLD(0, 0), NO_CARY, 0, A_NONE, NON_PM, NON_PM, 3000L,
105       NO_COLOR),
106
107     A("\83t\83@\83C\83A\83u\83\89\83\93\83h", LONG_SWORD, (SPFX_RESTR | SPFX_ATTK | SPFX_DEFN), 0, 0,
108       FIRE(5, 0), FIRE(0, 0), NO_CARY, 0, A_NONE, NON_PM, NON_PM, 3000L,
109       NO_COLOR),
110
111     A("\83h\83\89\83S\83\93\83x\81[\83\93", BROADSWORD, (SPFX_RESTR | SPFX_DCLAS), 0, S_DRAGON,
112       PHYS(5, 0), NO_DFNS, NO_CARY, 0, A_NONE, NON_PM, NON_PM, 500L,
113       NO_COLOR),
114
115     A("\83f\81[\83\82\83\93\83x\81[\83\93", LONG_SWORD, (SPFX_RESTR | SPFX_DFLAG2), 0, M2_DEMON,
116       PHYS(5, 0), NO_DFNS, NO_CARY, 0, A_LAWFUL, NON_PM, NON_PM, 2500L,
117       NO_COLOR),
118
119     A("\83E\83F\83A\83x\81[\83\93", SILVER_SABER, (SPFX_RESTR | SPFX_DFLAG2), 0, M2_WERE,
120       PHYS(5, 0), DFNS(AD_WERE), NO_CARY, 0, A_NONE, NON_PM, NON_PM, 1500L,
121       NO_COLOR),
122
123     A("\83O\83\8c\83C\83X\83\8f\83\93\83_\81[", SILVER_SABER, (SPFX_RESTR | SPFX_HALRES), 0, 0,
124       PHYS(5, 0), NO_DFNS, NO_CARY, 0, A_LAWFUL, NON_PM, NON_PM, 8000L,
125       NO_COLOR),
126
127     A("\83W\83\83\83C\83A\83\93\83g\83X\83\8c\83C\83\84\81[", LONG_SWORD, (SPFX_RESTR | SPFX_DFLAG2), 0, M2_GIANT,
128       PHYS(5, 0), NO_DFNS, NO_CARY, 0, A_NEUTRAL, NON_PM, NON_PM, 200L,
129       NO_COLOR),
130
131     A("\83I\81[\83K\83X\83}\83b\83V\83\83\81[", WAR_HAMMER, (SPFX_RESTR | SPFX_DCLAS), 0, S_OGRE,
132       PHYS(5, 0), NO_DFNS, NO_CARY, 0, A_NONE, NON_PM, NON_PM, 200L,
133       NO_COLOR),
134
135     A("\83g\83\8d\83\8b\83X\83x\81[\83\93", MORNING_STAR, (SPFX_RESTR | SPFX_DCLAS), 0, S_TROLL,
136       PHYS(5, 0), NO_DFNS, NO_CARY, 0, A_NONE, NON_PM, NON_PM, 200L,
137       NO_COLOR),
138     /*
139      *      Two problems:  1) doesn't let trolls regenerate heads,
140      *      2) doesn't give unusual message for 2-headed monsters (but
141      *      allowing those at all causes more problems than worth the effort).
142      */
143     A("\83{\81[\83p\83\8b\83u\83\8c\81[\83h", LONG_SWORD, (SPFX_RESTR | SPFX_BEHEAD), 0, 0,
144       PHYS(5, 1), NO_DFNS, NO_CARY, 0, A_NEUTRAL, NON_PM, NON_PM, 4000L,
145       NO_COLOR),
146     /*
147      *      Ah, never shall I forget the cry,
148      *              or the shriek that shrieked he,
149      *      As I gnashed my teeth, and from my sheath
150      *              I drew my Snickersnee!
151      *                      --Koko, Lord high executioner of Titipu
152      *                        (From Sir W.S. Gilbert's "The Mikado")
153      */
154     A("\83X\83j\83b\83J\81[\83Y\83j\81[", KATANA, SPFX_RESTR, 0, 0, PHYS(0, 8), NO_DFNS, NO_CARY,
155       0, A_LAWFUL, PM_SAMURAI, NON_PM, 1200L, NO_COLOR),
156
157     A("\83T\83\93\83\\81[\83h", LONG_SWORD, (SPFX_RESTR | SPFX_DFLAG2), 0, M2_UNDEAD,
158       PHYS(5, 0), DFNS(AD_BLND), NO_CARY, 0, A_LAWFUL, NON_PM, NON_PM, 1500L,
159       NO_COLOR),
160
161     /*
162      *      The artifacts for the quest dungeon, all self-willed.
163      */
164
165     A("\92T\8dõ\82Ì\83I\81[\83u", CRYSTAL_BALL,
166       (SPFX_NOGEN | SPFX_RESTR | SPFX_INTEL), (SPFX_ESP | SPFX_HSPDAM), 0,
167       NO_ATTK, NO_DFNS, CARY(AD_MAGM), INVIS, A_LAWFUL, PM_ARCHEOLOGIST,
168       NON_PM, 2500L, NO_COLOR),
169
170     A("\83A\81[\83\8a\83}\83\93\82Ì\90S\91\9f", LUCKSTONE,
171       (SPFX_NOGEN | SPFX_RESTR | SPFX_INTEL), SPFX_STLTH, 0,
172       /* this stone does double damage if used as a projectile weapon */
173       PHYS(5, 0), NO_DFNS, NO_CARY, LEVITATION, A_NEUTRAL, PM_BARBARIAN,
174       NON_PM, 2500L, NO_COLOR),
175
176     A("\8c \97Í\82Ìâ\94", MACE,
177       (SPFX_NOGEN | SPFX_RESTR | SPFX_INTEL | SPFX_DALIGN), 0, 0, PHYS(5, 0),
178       DFNS(AD_MAGM), NO_CARY, CONFLICT, A_LAWFUL, PM_CAVEMAN, NON_PM, 2500L,
179       NO_COLOR),
180
181 #if 0 /* OBSOLETE */
182 A("The Palantir of Westernesse",        CRYSTAL_BALL,
183         (SPFX_NOGEN|SPFX_RESTR|SPFX_INTEL),
184                 (SPFX_ESP|SPFX_REGEN|SPFX_HSPDAM), 0,
185         NO_ATTK,        NO_DFNS,        NO_CARY,
186         TAMING,         A_CHAOTIC, NON_PM , PM_ELF, 8000L, NO_COLOR ),
187 #endif
188
189     A("\83A\83X\83N\83\8c\83s\83I\83X\82Ì\8fñ", QUARTERSTAFF,
190       (SPFX_NOGEN | SPFX_RESTR | SPFX_ATTK | SPFX_INTEL | SPFX_DRLI
191        | SPFX_REGEN),
192       0, 0, DRLI(0, 0), DRLI(0, 0), NO_CARY, HEALING, A_NEUTRAL, PM_HEALER,
193       NON_PM, 5000L, NO_COLOR),
194
195     A("\83}\81[\83\8a\83\93\82Ì\96\82\96@\82Ì\8b¾", MIRROR,
196       (SPFX_NOGEN | SPFX_RESTR | SPFX_INTEL | SPFX_SPEAK), SPFX_ESP, 0,
197       NO_ATTK, NO_DFNS, CARY(AD_MAGM), 0, A_LAWFUL, PM_KNIGHT, NON_PM, 1500L,
198       NO_COLOR),
199
200     A("\92´\90¢\8aE\82Ì\96Ú", LENSES,
201       (SPFX_NOGEN | SPFX_RESTR | SPFX_INTEL | SPFX_XRAY), 0, 0, NO_ATTK,
202       DFNS(AD_MAGM), NO_CARY, ENLIGHTENING, A_NEUTRAL, PM_MONK, NON_PM,
203       2500L, NO_COLOR),
204
205     A("\90¹\82È\82é\8a¥", HELM_OF_BRILLIANCE,
206       (SPFX_NOGEN | SPFX_RESTR | SPFX_DFLAG2 | SPFX_INTEL | SPFX_PROTECT), 0,
207       M2_UNDEAD, NO_ATTK, NO_DFNS, CARY(AD_FIRE), ENERGY_BOOST, A_LAWFUL,
208       PM_PRIEST, NON_PM, 2000L, NO_COLOR),
209
210     A("\83_\83C\83A\83i\82Ì\92·\8b|", BOW,
211       (SPFX_NOGEN | SPFX_RESTR | SPFX_INTEL | SPFX_REFLECT), SPFX_ESP, 0,
212       PHYS(5, 0), NO_DFNS, NO_CARY, CREATE_AMMO, A_CHAOTIC, PM_RANGER, NON_PM,
213       4000L, NO_COLOR),
214
215     A("\93\90\91¯\82Ì\83}\83X\83^\81[\83L\81[", SKELETON_KEY,
216       (SPFX_NOGEN | SPFX_RESTR | SPFX_INTEL | SPFX_SPEAK),
217       (SPFX_WARN | SPFX_TCTRL | SPFX_HPHDAM), 0, NO_ATTK, NO_DFNS, NO_CARY,
218       UNTRAP, A_CHAOTIC, PM_ROGUE, NON_PM, 3500L, NO_COLOR),
219
220     A("\91º\90³\82Ì\93\81", TSURUGI,
221       (SPFX_NOGEN | SPFX_RESTR | SPFX_INTEL | SPFX_BEHEAD | SPFX_LUCK
222        | SPFX_PROTECT),
223       0, 0, PHYS(0, 8), NO_DFNS, NO_CARY, 0, A_LAWFUL, PM_SAMURAI, NON_PM,
224       4500L, NO_COLOR),
225
226     A("\83v\83\89\83`\83i\83C\83F\83\93\83_\81[\88ó\83G\83N\83X\83v\83\8c\83X\83J\81[\83h", CREDIT_CARD,
227       (SPFX_NOGEN | SPFX_RESTR | SPFX_INTEL | SPFX_DEFN),
228       (SPFX_ESP | SPFX_HSPDAM), 0, NO_ATTK, NO_DFNS, CARY(AD_MAGM),
229       CHARGE_OBJ, A_NEUTRAL, PM_TOURIST, NON_PM, 7000L, NO_COLOR),
230
231     A("\89^\96½\82Ì\83I\81[\83u", CRYSTAL_BALL,
232       (SPFX_NOGEN | SPFX_RESTR | SPFX_INTEL | SPFX_LUCK),
233       (SPFX_WARN | SPFX_HSPDAM | SPFX_HPHDAM), 0, NO_ATTK, NO_DFNS, NO_CARY,
234       LEV_TELE, A_NEUTRAL, PM_VALKYRIE, NON_PM, 3500L, NO_COLOR),
235
236     A("\83G\83`\83I\83s\83A\82Ì\96Ú", AMULET_OF_ESP,
237       (SPFX_NOGEN | SPFX_RESTR | SPFX_INTEL), (SPFX_EREGEN | SPFX_HSPDAM), 0,
238       NO_ATTK, DFNS(AD_MAGM), NO_CARY, CREATE_PORTAL, A_NEUTRAL, PM_WIZARD,
239       NON_PM, 4000L, NO_COLOR),
240
241     /*
242      *  terminator; otyp must be zero
243      */
244     A(0, 0, 0, 0, 0, NO_ATTK, NO_DFNS, NO_CARY, 0, A_NONE, NON_PM, NON_PM, 0L,
245       0) /* 0 is CLR_BLACK rather than NO_COLOR but it doesn't matter here */
246
247 }; /* artilist[] (or artifact_names[]) */
248
249 #undef A
250
251 #ifndef MAKEDEFS_C
252 #undef NO_ATTK
253 #undef NO_DFNS
254 #undef DFNS
255 #undef PHYS
256 #undef DRLI
257 #undef COLD
258 #undef FIRE
259 #undef ELEC
260 #undef STUN
261 #endif
262
263 /*artilist.h*/