"SELF_LITE_2",
"GUARDIAN",
"CHAMELEON",
- "KILL_EXP",
+ "XXXX4XXX",
"TANUKI",
"HAS_DARK_1",
"SELF_DARK_1",
"WARNING",
"HIDE_TYPE",
"SHOW_MODS",
- "XXX1",
+ "SLAY_GOOD",
"LEVITATION",
"LITE",
"SEE_INVIS",
"BLESSED",
"XXX3", /* Fake flag for Smith */
"XXX4", /* Fake flag for Smith */
- "XXX5",
+ "KILL_GOOD",
"KILL_ANIMAL",
"KILL_EVIL",
"FIXED_FLAVOR",
"ADD_L_CURSE",
"ADD_H_CURSE",
+ "DRAIN_HP",
+ "DRAIN_MANA",
+
+ "LITE_2",
+ "LITE_3",
+ "LITE_M1",
+ "LITE_M2",
+ "LITE_M3",
+ "LITE_FUEL",
+
+ "CALL_ANIMAL",
+ "CALL_DEMON",
+ "CALL_DRAGON",
+ "CALL_UNDEAD",
+ "COWARDICE",
+ "LOW_MELEE",
+ "LOW_AC",
+ "LOW_MAGIC",
+ "FAST_DIGEST",
+ "SLOW_REGEN",
};
-
static cptr k_info_gen_flags[] =
{
"INSTA_ART",
"RANDOM_CURSE1",
"RANDOM_CURSE2",
"XTRA_DICE",
- "XXX",
+ "POWERFUL",
"XXX",
"XXX",
"XXX",
"GLASS_DOOR",
"CAVE",
"CAVERN",
- "XXX",
+ "ARCADE",
"XXX",
"XXX",
"XXX",
return (1);
}
+/*
+ * Grab one activation index flag
+ */
+static byte grab_one_activation_flag(cptr what)
+{
+ int i;
+
+ for (i = 0; ; i++)
+ {
+ if (activation_info[i].flag == NULL) break;
+
+ if (streq(what, activation_info[i].flag))
+ {
+ return activation_info[i].index;
+ }
+ }
+
+ i = atoi(what);
+ if (i > 0)
+ {
+ return ((byte) i);
+ }
+
+ /* Oops */
+#ifdef JP
+ msg_format("̤ÃΤÎȯư¡¦¥Õ¥é¥° '%s'¡£", what);
+#else
+ msg_format("Unknown activation flag '%s'.", what);
+#endif
+
+ /* Error */
+ return (0);
+}
+
/*
* Initialize the "k_info" array, by parsing an ascii "template" file
k_ptr->to_a = ta;
}
+ /* Hack -- Process 'U' for activation index */
+ else if (buf[0] == 'U')
+ {
+ byte n;
+ n = grab_one_activation_flag(buf + 2);
+ if (n > 0)
+ {
+ k_ptr->act_idx = n;
+ }
+ else
+ {
+ return (5);
+ }
+ }
+
/* Hack -- Process 'F' for flags */
else if (buf[0] == 'F')
{
return (1);
}
-/*
- * Grab one activation index flag
- */
-static byte grab_one_activation_flag(cptr what)
-{
- int i;
-
- for (i = 0; ; i++)
- {
- if (activation_info[i].flag == NULL) break;
-
- if (streq(what, activation_info[i].flag))
- {
- return activation_info[i].index;
- }
- }
-
- i = atoi(what);
- if (i > 0)
- {
- return ((byte) i);
- }
-
- /* Oops */
-#ifdef JP
- msg_format("̤ÃΤÎȯư¡¦¥Õ¥é¥° '%s'¡£", what);
-#else
- msg_format("Unknown activation flag '%s'.", what);
-#endif
-
- /* Error */
- return (0);
-}
-
/*
* Initialize the "a_info" array, by parsing an ascii "template" file
r_ptr->next_r_idx = nextmon;
}
+ /* Process 'R' for "Reinforcement" (up to six lines) */
+ else if (buf[0] == 'R')
+ {
+ int id, ds, dd;
+ /* Find the next empty blow slot (if any) */
+ for (i = 0; i < 6; i++) if (r_ptr->reinforce_id[i] == 0) break;
+
+ /* Oops, no more slots */
+ if (i == 6) return (1);
+
+ /* Scan for the values */
+ if (3 != sscanf(buf+2, "%d:%dd%d", &id, &dd, &ds)) return (1);
+ r_ptr->reinforce_id[i] = id;
+ r_ptr->reinforce_dd[i] = dd;
+ r_ptr->reinforce_ds[i] = ds;
+ }
+
/* Process 'B' for "Blows" (up to four lines) */
else if (buf[0] == 'B')
{
if (!buf[0]) return (0);
/* Skip "blank" lines */
- if (isspace(buf[0])) return (0);
+ if (iswspace(buf[0])) return (0);
/* Skip comments */
if (buf[0] == '#') return (0);
s = (*sp);
/* Skip spaces */
- while (isspace(*s)) s++;
+ while (iswspace(*s)) s++;
/* Save start */
b = s;
if (!buf[0]) continue;
/* Skip "blank" lines */
- if (isspace(buf[0])) continue;
+ if (iswspace(buf[0])) continue;
/* Skip comments */
if (buf[0] == '#') continue;
/* Start the line */
sprintf(buf, "D:");
- for (bc = 0, t = buf + 2; ((bc < 60) || !isspace(desc[j])) && (j < dlen); j++, bc++, t++)
+ for (bc = 0, t = buf + 2; ((bc < 60) || !iswspace(desc[j])) && (j < dlen); j++, bc++, t++)
{
*t = desc[j];
}