OSDN Git Service

[Refactor] #1372 フロア中の最大アイテム数/最大モンスター数をgamevalue.h にコンパイル時定数で移した
[hengbandforosx/hengbandosx.git] / src / monster / monster-status.cpp
index d28f353..37805d3 100644 (file)
@@ -25,7 +25,6 @@
 #include "timed-effect/timed-effects.h"
 #include "util/bit-flags-calculator.h"
 #include "view/display-messages.h"
-#include "world/world.h"
 #if JP
 #else
 #include "monster/monster-description-types.h"
@@ -130,7 +129,7 @@ int get_mproc_idx(FloorType *floor_ptr, MONSTER_IDX m_idx, int mproc_type)
  */
 void mproc_add(FloorType *floor_ptr, MONSTER_IDX m_idx, int mproc_type)
 {
-    if (floor_ptr->mproc_max[mproc_type] < w_ptr->max_m_idx) {
+    if (floor_ptr->mproc_max[mproc_type] < MAX_FLOOR_MONSTERS) {
         floor_ptr->mproc_list[mproc_type][floor_ptr->mproc_max[mproc_type]++] = (int16_t)m_idx;
     }
 }