* @param len データの長さ
* @return エラーコード
*/
-static void init_header(header *head, int num, int len)
+static void init_header(header *head, IDX num, int len)
{
/* Save the "version" */
head->v_major = FAKE_VER_MAJOR;
head->v_extra = 0;
/* Save the "record" information */
- head->info_num = num;
+ head->info_num = (IDX)num;
head->info_len = len;
/* Save the size of "*_head" and "*_info" */
{
int fd;
- int mode = 0644;
+ BIT_FLAGS mode = 0644;
errr err = 1;
/*** Prepare the quests ***/
/* Allocate the quests */
- C_MAKE(quest, max_quests, quest_type);
+ C_MAKE(quest, max_q_idx, quest_type);
/* Set all quest to "untaken" */
- for (i = 0; i < max_quests; i++)
+ for (i = 0; i < max_q_idx; i++)
{
quest[i].status = QUEST_STATUS_UNTAKEN;
}
z = y + aux[x];
/* Load the entry */
- table[z].index = i;
+ table[z].index = (KIND_OBJECT_IDX)i;
table[z].level = (DEPTH)x;
table[z].prob1 = (PROB)p;
table[z].prob2 = (PROB)p;
p = (100 / r_ptr->rarity);
/* Load the entry */
- alloc_race_table[i].index = elements[i].index;
+ alloc_race_table[i].index = (KIND_OBJECT_IDX)elements[i].index;
alloc_race_table[i].level = (DEPTH)x;
alloc_race_table[i].prob1 = (PROB)p;
alloc_race_table[i].prob2 = (PROB)p;
{
int fd = -1;
- int mode = 0664;
+ BIT_FLAGS mode = 0664;
FILE *fp;