• R/O
  • HTTP
  • SSH
  • HTTPS

hengband: Commit

変愚蛮怒のメインリポジトリです


Commit MetaInfo

Revisiondb74a94011056c6f5cb5c70f27ce7bf2ff65fb02 (tree)
Time2019-05-15 00:13:23
Authordeskull <deskull@user...>
Commiterdeskull

Log Message

[Refactor] #37353 highscore_fd を scores.c/h へ移動.

Change Summary

Incremental Difference

--- a/src/externs.h
+++ b/src/externs.h
@@ -93,7 +93,6 @@ extern u32b saved_floor_file_sign;
9393 extern concptr keymap_act[KEYMAP_MODES][256];
9494 extern player_type *p_ptr;
9595
96-extern int highscore_fd;
9796 extern bool can_save;
9897
9998 extern MONSTER_IDX pet_t_m_idx;
--- a/src/files.c
+++ b/src/files.c
@@ -64,6 +64,8 @@
6464 #include "autopick.h"
6565 #include "save.h"
6666
67+#include "scores.h"
68+
6769 concptr ANGBAND_DIR; //!< Path name: The main "lib" directory This variable is not actually used anywhere in the code
6870 concptr ANGBAND_DIR_APEX; //!< High score files (binary) These files may be portable between platforms
6971 concptr ANGBAND_DIR_BONE; //!< Bone files for player ghosts (ascii) These files are portable between platforms
--- a/src/scores.c
+++ b/src/scores.c
@@ -27,6 +27,11 @@
2727 #include "report.h"
2828 #include "japanese.h"
2929
30+ /*
31+ * The "highscore" file descriptor, if available.
32+ */
33+int highscore_fd = -1;
34+
3035 /*!
3136 * @brief i番目のスコア情報にバッファ位置をシークする / Seek score 'i' in the highscore file
3237 * @param i スコア情報ID
--- a/src/scores.h
+++ b/src/scores.h
@@ -35,6 +35,8 @@ struct high_score
3535 GAME_TEXT how[40]; /* Method of death (string) */
3636 };
3737
38+extern int highscore_fd;
39+
3840 /* scores.c */
3941 extern void display_scores_aux(int from, int to, int note, high_score *score);
4042 extern void display_scores(int from, int to);
--- a/src/variable.c
+++ b/src/variable.c
@@ -115,11 +115,6 @@ player_type p_body;
115115 */
116116 player_type *p_ptr = &p_body;
117117
118-/*
119- * The "highscore" file descriptor, if available.
120- */
121-int highscore_fd = -1;
122-
123118 bool can_save = FALSE; /* Game can be saved */
124119
125120
Show on old repository browser