From 2053de41cb831a978a1009a7d85ae933f8edb236 Mon Sep 17 00:00:00 2001 From: deskull Date: Thu, 6 Jun 2019 22:32:43 +0900 Subject: [PATCH] =?utf8?q?[Refactor]=20#37353=20MAX=5FWID=20=E3=81=A8=20MA?= =?utf8?q?X=5FHGT=20=E3=82=92=20floor.h=20=E3=81=B8=E7=A7=BB=E5=8B=95?= =?utf8?q?=EF=BC=8E?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- src/defines.h | 12 ------------ src/floor-generate.h | 1 + src/floor.h | 12 ++++++++++++ src/player-move.h | 1 + src/wild.h | 2 ++ 5 files changed, 16 insertions(+), 12 deletions(-) diff --git a/src/defines.h b/src/defines.h index 85221872b..ca428a8f8 100644 --- a/src/defines.h +++ b/src/defines.h @@ -63,18 +63,6 @@ */ #define SCREEN_WID 66 -/*! - * @brief 表示上のダンジョンの最大垂直サイズ(SCREEN_HGTの3倍が望ましい) - * Maximum dungeon height in grids, must be a multiple of SCREEN_HGT, probably hard-coded to SCREEN_HGT * 3. - */ -#define MAX_HGT 66 - -/*! - * @brief 表示上のダンジョンの最大水平サイズ(SCREEN_WIDの3倍が望ましい) - * Maximum dungeon width in grids, must be a multiple of SCREEN_WID, probably hard-coded to SCREEN_WID * 3. - */ -#define MAX_WID 198 - /* * Arena constants */ diff --git a/src/floor-generate.h b/src/floor-generate.h index 83590f837..01210855e 100644 --- a/src/floor-generate.h +++ b/src/floor-generate.h @@ -1,4 +1,5 @@ #pragma once +#include "floor.h" /*! * @file generate.h diff --git a/src/floor.h b/src/floor.h index 054b6ba8a..842624244 100644 --- a/src/floor.h +++ b/src/floor.h @@ -26,6 +26,18 @@ #define BLOCK_WID 11 /*! + * @brief 表示上のダンジョンの最大垂直サイズ(SCREEN_HGTの3倍が望ましい) + * Maximum dungeon height in grids, must be a multiple of SCREEN_HGT, probably hard-coded to SCREEN_HGT * 3. + */ +#define MAX_HGT 66 + +/*! + * @brief 表示上のダンジョンの最大水平サイズ(SCREEN_WIDの3倍が望ましい) + * Maximum dungeon width in grids, must be a multiple of SCREEN_WID, probably hard-coded to SCREEN_WID * 3. + */ +#define MAX_WID 198 + +/*! * @brief プレイヤー用光源処理配列サイズ / Maximum size of the "lite" array (see "current_floor_ptr->grid_array.c") * @details Note that the "lite radius" will NEVER exceed 14, and we would * never require more than 581 entries in the array for circular "lite". diff --git a/src/player-move.h b/src/player-move.h index 2a00b82c8..7bb555f0f 100644 --- a/src/player-move.h +++ b/src/player-move.h @@ -1,4 +1,5 @@ #pragma once +#include "floor.h" extern void disturb(bool stop_search, bool flush_output); extern void move_player(DIRECTION dir, bool do_pickup, bool break_trap); diff --git a/src/wild.h b/src/wild.h index 808ba94e9..dade049b7 100644 --- a/src/wild.h +++ b/src/wild.h @@ -1,4 +1,6 @@ #pragma once +#include "floor.h" + #define NO_TOWN 6 #define SECRET_TOWN 5 -- 2.11.0