* @param parse_info_txt_line パース関数
* @return エラーコード
*/
-errr init_info_txt(FILE *fp, char *buf, header *head,
- parse_info_txt_func parse_info_txt_line)
+errr init_info_txt(FILE *fp, char *buf, header *head, parse_info_txt_func parse_info_txt_line)
{
errr err;
v_ptr->wid = (POSITION)wid;
}
- /* Oops */
else return (6);
/* Success */
}
- /* Oops */
else return (6);
/* Success */
}
- /* Oops */
else return (6);
/* Success */
}
}
- /* Oops */
msg_format(_("未知の地形フラグ '%s'。", "Unknown feature flag '%s'."), what);
/* Error */
}
}
- /* Oops */
msg_format(_("未知の地形アクション '%s'。", "Unknown feature action '%s'."), what);
/* Error */
while (*t == ' ' || *t == '|') t++;
}
- /* XXX XXX XXX Hack -- Read feature subtype */
+ /* Hack -- Read feature subtype */
if (1 == sscanf(s, "SUBTYPE_%d", &i))
{
/* Extract a "subtype" */
continue;
}
- /* XXX XXX XXX Hack -- Read feature power */
+ /* Hack -- Read feature power */
if (1 == sscanf(s, "POWER_%d", &i))
{
/* Extract a "power" */
}
}
- /* Oops */
else return (6);
/* Success */
if (grab_one_flag(&k_ptr->gen_flags, k_info_gen_flags, what) == 0)
return 0;
- /* Oops */
msg_format(_("未知のアイテム・フラグ '%s'。", "Unknown object flag '%s'."), what);
/* Error */
return ((byte) i);
}
- /* Oops */
msg_format(_("未知の発動・フラグ '%s'。", "Unknown activation flag '%s'."), what);
/* Error */
else if (buf[0] == 'A')
{
- /* XXX XXX XXX Simply read each number following a colon */
+ /* Simply read each number following a colon */
for (i = 0, s = buf+1; s && (s[0] == ':') && s[1]; ++i)
{
/* Default chance */
}
- /* Oops */
else return (6);
if (grab_one_flag(&a_ptr->gen_flags, k_info_gen_flags, what) == 0)
return 0;
- /* Oops */
msg_format(_("未知の伝説のアイテム・フラグ '%s'。", "Unknown artifact flag '%s'."), what);
/* Error */
}
- /* Oops */
else return (6);
if (grab_one_flag(&e_ptr->gen_flags, k_info_gen_flags, what) == 0)
return 0;
- /* Oops */
msg_format(_("未知の名のあるアイテム・フラグ '%s'。", "Unknown ego-item flag '%s'."), what);
/* Error */
}
}
- /* Oops */
else return (6);
/* Success */
if (grab_one_flag(&r_ptr->flagsr, r_info_flagsr, what) == 0)
return 0;
- /* Oops */
msg_format(_("未知のモンスター・フラグ '%s'。", "Unknown monster flag '%s'."), what);
/* Failure */
if (grab_one_flag(&r_ptr->a_ability_flags2, r_a_ability_flags2, what) == 0)
return 0;
- /* Oops */
msg_format(_("未知のモンスター・フラグ '%s'。", "Unknown monster flag '%s'."), what);
/* Failure */
while ((*t == ' ') || (*t == '|')) t++;
}
- /* XXX XXX XXX Hack -- Read spell frequency */
+ /* Hack -- Read spell frequency */
if (1 == sscanf(s, "1_IN_%d", &i))
{
/* Extract a "frequency" */
r_ptr->arena_ratio = (PERCENTAGE)val;
}
- /* Oops */
else return (6);
if (grab_one_flag(&d_ptr->flags1, d_info_flags1, what) == 0)
return 0;
- /* Oops */
msg_format(_("未知のダンジョン・フラグ '%s'。", "Unknown dungeon type flag '%s'."), what);
/* Failure */
if (grab_one_flag(&d_ptr->mflagsr, r_info_flagsr, what) == 0)
return 0;
- /* Oops */
msg_format(_("未知のモンスター・フラグ '%s'。", "Unknown monster flag '%s'."), what);
/* Failure */
return (1);
if (grab_one_flag(&d_ptr->m_a_ability_flags2, r_a_ability_flags2, what) == 0)
return 0;
- /* Oops */
msg_format(_("未知のモンスター・フラグ '%s'。", "Unknown monster flag '%s'."), what);
/* Failure */
while (*t == ' ' || *t == '|') t++;
}
- /* XXX XXX XXX Hack -- Read Final Artifact */
+ /* Hack -- Read Final Artifact */
if (1 == sscanf(s, "FINAL_ARTIFACT_%d", &artif))
{
/* Extract a "Final Artifact" */
continue;
}
- /* XXX XXX XXX Hack -- Read Final Object */
+ /* Hack -- Read Final Object */
if (1 == sscanf(s, "FINAL_OBJECT_%d", &artif))
{
/* Extract a "Final Artifact" */
continue;
}
- /* XXX XXX XXX Hack -- Read Artifact Guardian */
+ /* Hack -- Read Artifact Guardian */
if (1 == sscanf(s, "FINAL_GUARDIAN_%d", &monst))
{
/* Extract a "Artifact Guardian" */
continue;
}
- /* XXX XXX XXX Hack -- Read Special Percentage */
+ /* Hack -- Read Special Percentage */
if (1 == sscanf(s, "MONSTER_DIV_%d", &monst))
{
/* Extract a "Special %" */
while ((*t == ' ') || (*t == '|')) t++;
}
- /* XXX XXX XXX Hack -- Read spell frequency */
+ /* Hack -- Read spell frequency */
if (1 == sscanf(s, "1_IN_%d", &i))
{
/* Start at next entry */
}
}
- /* Oops */
else return (6);
/* Success */
{
if (p_ptr->inside_quest)
{
- int a_idx = quest[p_ptr->inside_quest].k_idx;
+ ARTIFACT_IDX a_idx = quest[p_ptr->inside_quest].k_idx;
if (a_idx)
{
artifact_type *a_ptr = &a_info[a_idx];
static errr process_dungeon_file_aux(char *buf, int ymin, int xmin, int ymax, int xmax, int *y, int *x)
{
int i;
-
char *zz[33];
-
/* Skip "empty" lines */
if (!buf[0]) return (0);
{
if (a_info[artifact_index].cur_num)
{
- IDX k_idx = lookup_kind(TV_SCROLL, SV_SCROLL_ACQUIREMENT);
+ KIND_OBJECT_IDX k_idx = lookup_kind(TV_SCROLL, SV_SCROLL_ACQUIREMENT);
object_type forge;
object_type *q_ptr = &forge;
/* First */
t = process_dungeon_file_expr(&s, &f);
- /* Oops */
if (!*t)
{
/* Nothing */
}
}
- /* Oops */
else
{
while (*s && (f != b2))
/* Save */
(*sp) = s;
-
- /* Result */
return (v);
}
/* Process the line */
err = process_dungeon_file_aux(buf, ymin, xmin, ymax, xmax, &y, &x);
- /* Oops */
if (err) break;
}
/* Error string */
oops = (((err > 0) && (err < PARSE_ERROR_MAX)) ? err_str[err] : "unknown");
- /* Oops */
msg_format("Error %d (%s) at line %d of '%s'.", err, oops, num, name);
msg_format(_("'%s'を解析中。", "Parsing '%s'."), buf);
/* Close the file */
my_fclose(fp);
-
- /* Result */
return (err);
}
fprintf(fff, "\n");
}
- /* Done */
fclose(fff);
}