OSDN Git Service

[Refactor] #37353 inside_quest を player_type から floor_type へ移動. / Move inside_quest...
[hengband/hengband.git] / src / birth.c
index 72fd155..0e13817 100644 (file)
@@ -238,7 +238,7 @@ static concptr race_jouhou[MAX_RACES] =
 
 "A Kutar is an expressionless animal-like living creature.  The word 'kuta' means 'absentmindedly' or 'vacantly'.  Their absentmindedness hurts their searching and perception skills, but renders them incapable of being confused.  Their unearthly calmness and serenity make them among the most stealthy of any race.  Kutars, although expressionless, are beautiful and so have a high charisma.  Members of this race can learn to expand their body horizontally.  This increases armour class, but renders them vulnerable to magical attacks.",
 
-"An android is a artificial creation with a body of machinery.  They are poor at spell casting, but they make excellent warriors.  They don't acquire experience like other races, but rather gain in power as they attach new equipment to their frame.  Rings, amulets, and lights do not influence growth.  Androids are resistant to poison, can move freely, and are immune to exp-draining attacks.  Moreover, because of their hard metallic bodies, they get a bonus to AC.  Androids have electronic circuits throughout their body and must beware of electric shocks.  They gain very little nutrition from the food of mortals, but they can use flasks of oil as their energy source."
+"An android is a artificial creation with a body of machinery.  They are poor at spell casting, but they make excellent warriors.  They don't acquire experience like other races, but rather gain in power as they attach new equipment to their frame.  Rings, amulets, and lights do not influence growth.  Androids are resistant to poison, can move freely, and are immune to exp-draining attacks.  Moreover, because of their hard metallic bodies, they get a bonus to AC.  Androids have electronic circuits throughout their body and must beware of electric shocks.  They gain very little nutrition from the food of mortals, but they can use flasks of oil as their energy source.",
 
 "Merfolk implementing.",
 
@@ -1682,6 +1682,9 @@ static void player_wipe_without_name(player_type *creature_ptr)
        /* Hack -- zero the struct */
        (void)WIPE(creature_ptr, player_type);
 
+       //TODO: キャラ作成からゲーム開始までに  current_floor_ptr を参照しなければならない処理は今後整理して外す。
+       creature_ptr->current_floor_ptr = &floor_info;
+
        C_MAKE(creature_ptr->inventory_list, INVEN_TOTAL, object_type);
 
        /* Wipe the history */
@@ -1831,7 +1834,7 @@ static void player_wipe_without_name(player_type *creature_ptr)
        /* Initialize arena and rewards information -KMW- */
        creature_ptr->arena_number = 0;
        creature_ptr->inside_arena = FALSE;
-       creature_ptr->inside_quest = 0;
+       creature_ptr->current_floor_ptr->inside_quest = 0;
        for (i = 0; i < MAX_MANE; i++)
        {
                creature_ptr->mane_spell[i] = -1;
@@ -1883,11 +1886,11 @@ static void init_dungeon_quests(player_type *creature_ptr)
 
        /* Init the random quests */
        init_flags = INIT_ASSIGN;
-       creature_ptr->inside_quest = MIN_RANDOM_QUEST;
+       creature_ptr->current_floor_ptr->inside_quest = MIN_RANDOM_QUEST;
 
        process_dungeon_file("q_info.txt", 0, 0, 0, 0);
 
-       creature_ptr->inside_quest = 0;
+       creature_ptr->current_floor_ptr->inside_quest = 0;
 
        /* Generate quests */
        for (i = MIN_RANDOM_QUEST + number_of_quests - 1; i >= MIN_RANDOM_QUEST; i--)
@@ -1907,22 +1910,22 @@ static void init_dungeon_quests(player_type *creature_ptr)
 
        /* Init the two main quests (Oberon + Serpent) */
        init_flags = INIT_ASSIGN;
-       creature_ptr->inside_quest = QUEST_OBERON;
+       creature_ptr->current_floor_ptr->inside_quest = QUEST_OBERON;
 
        process_dungeon_file("q_info.txt", 0, 0, 0, 0);
 
        quest[QUEST_OBERON].status = QUEST_STATUS_TAKEN;
 
-       creature_ptr->inside_quest = QUEST_SERPENT;
+       creature_ptr->current_floor_ptr->inside_quest = QUEST_SERPENT;
 
        process_dungeon_file("q_info.txt", 0, 0, 0, 0);
 
        quest[QUEST_SERPENT].status = QUEST_STATUS_TAKEN;
-       creature_ptr->inside_quest = 0;
+       creature_ptr->current_floor_ptr->inside_quest = 0;
 }
 
 /*!
- * @brief ゲームターンを初期化する / Reset current_world_ptr->game_turn
+ * @brief ゲームターンを初期化する / Reset turn
  * @details アンデッド系種族は開始時刻を夜からにする。
  * @return なし
  */
@@ -4154,7 +4157,7 @@ static bool player_birth_aux(player_type *creature_ptr)
 #endif /* ALLOW_AUTOROLLER */
        clear_from(10);
 
-       /* Reset current_world_ptr->game_turn; before auto-roll and after choosing race */
+       /* Reset turn; before auto-roll and after choosing race */
        init_turn(creature_ptr);
 
        /*** Generate ***/