OSDN Git Service

[Fix] #38965 「気合いため」のための concentration() 関数抜け修正。 / Fix forgotten calling concentration().
[hengband/hengband.git] / src / player-status.c
index a86c463..7064df5 100644 (file)
@@ -3,6 +3,7 @@
 
 #include "artifact.h"
 #include "avatar.h"
+#include "spells-status.h"
 
 /*
  * Return alignment title
@@ -2812,7 +2813,7 @@ static void calc_torch(void)
 
        /* max radius is 14 (was 5) without rewriting other code -- */
        /* see cave.c:update_lite() and defines.h:LITE_MAX */
-       if (d_info[dungeon_type].flags1 & DF1_DARKNESS && p_ptr->cur_lite > 1)
+       if (d_info[p_ptr->dungeon_idx].flags1 & DF1_DARKNESS && p_ptr->cur_lite > 1)
                p_ptr->cur_lite = 1;
 
        /*
@@ -3814,10 +3815,10 @@ bool player_has_no_spellbooks(void)
 
 void take_turn(player_type *creature_ptr, PERCENTAGE need_cost)
 {
-       p_ptr->energy_use = (ENERGY)need_cost;
+       creature_ptr->energy_use = (ENERGY)need_cost;
 }
 
 void free_turn(player_type *creature_ptr)
 {
-       p_ptr->energy_use = 0;
+       creature_ptr->energy_use = 0;
 }