• R/O
  • HTTP
  • SSH
  • HTTPS

hengband: Commit

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


Commit MetaInfo

Revision1097b1ea7a4c56178b2059a9355537635ee49e38 (tree)
Time2019-05-02 23:18:29
Authordeskull <deskull@user...>
Commiterdeskull

Log Message

[Refactor] #37353 dragonbreath_type 構造体と関連変数を cmd-activate.c/h へ移動.

Change Summary

Incremental Difference

--- a/src/cmd-activate.c
+++ b/src/cmd-activate.c
@@ -31,6 +31,28 @@
3131 #include "grid.h"
3232
3333 /*!
34+ * @brief 装備耐性に準じたブレス効果の選択テーブル /
35+ * Define flags, effect type, name for dragon breath activation
36+ */
37+const dragonbreath_type dragonbreath_info[] = {
38+ { TR_RES_ACID, GF_ACID, _("酸", "acid") },
39+ { TR_RES_ELEC, GF_ELEC, _("電撃", "lightning") },
40+ { TR_RES_FIRE, GF_FIRE, _("火炎", "fire") },
41+ { TR_RES_COLD, GF_COLD, _("冷気", "cold") },
42+ { TR_RES_POIS, GF_POIS, _("毒", "poison") },
43+ { TR_RES_LITE, GF_LITE, _("閃光", "light") },
44+ { TR_RES_DARK, GF_DARK, _("暗黒", "dark") },
45+ { TR_RES_SHARDS, GF_SHARDS, _("破片", "shard") },
46+ { TR_RES_CONF, GF_CONFUSION, _("混乱", "confusion") },
47+ { TR_RES_SOUND, GF_SOUND, _("轟音", "sound") },
48+ { TR_RES_NEXUS, GF_NEXUS, _("因果混乱", "nexus") },
49+ { TR_RES_NETHER, GF_NETHER, _("地獄", "nether") },
50+ { TR_RES_CHAOS, GF_CHAOS, _("カオス", "chaos") },
51+ { TR_RES_DISEN, GF_DISENCHANT, _("劣化", "disenchant") },
52+ { 0, 0, NULL }
53+};
54+
55+/*!
3456 * @brief アイテムの発動効果テーブル /
3557 * Define flags, levels, values of activations
3658 */
--- a/src/cmd-activate.h
+++ b/src/cmd-activate.h
@@ -18,6 +18,13 @@ typedef struct {
1818
1919 extern const activation_type activation_info[];
2020
21+typedef struct {
22+ int flag;
23+ int type;
24+ concptr name;
25+} dragonbreath_type;
26+
27+extern const dragonbreath_type dragonbreath_info[];
2128
2229 /* Activation effects for random artifacts */
2330 #define ACT_SUNLIGHT 1
--- a/src/externs.h
+++ b/src/externs.h
@@ -86,10 +86,8 @@ extern const concptr game_inscriptions[];
8686 extern const kamae kamae_shurui[MAX_KAMAE];
8787 extern const kamae kata_shurui[MAX_KATA];
8888
89-
9089 extern const concptr ident_info[];
9190 extern const byte feature_action_flags[FF_FLAG_MAX];
92-extern const dragonbreath_type dragonbreath_info[];
9391
9492 /* variable.c */
9593 extern const concptr copyright[5];
--- a/src/tables.c
+++ b/src/tables.c
@@ -2654,26 +2654,3 @@ const byte feature_action_flags[FF_FLAG_MAX] =
26542654 0, /* GLASS */
26552655 };
26562656
2657-
2658-/*!
2659- * @brief 装備耐性に準じたブレス効果の選択テーブル /
2660- * Define flags, effect type, name for dragon breath activation
2661- */
2662-const dragonbreath_type dragonbreath_info[] = {
2663- { TR_RES_ACID, GF_ACID, _("酸", "acid") },
2664- { TR_RES_ELEC, GF_ELEC, _("電撃", "lightning") },
2665- { TR_RES_FIRE, GF_FIRE, _("火炎", "fire") },
2666- { TR_RES_COLD, GF_COLD, _("冷気", "cold") },
2667- { TR_RES_POIS, GF_POIS, _("毒", "poison") },
2668- { TR_RES_LITE, GF_LITE, _("閃光", "light") },
2669- { TR_RES_DARK, GF_DARK, _("暗黒", "dark") },
2670- { TR_RES_SHARDS, GF_SHARDS, _("破片", "shard") },
2671- { TR_RES_CONF, GF_CONFUSION, _("混乱", "confusion") },
2672- { TR_RES_SOUND, GF_SOUND, _("轟音", "sound") },
2673- { TR_RES_NEXUS, GF_NEXUS, _("因果混乱", "nexus") },
2674- { TR_RES_NETHER, GF_NETHER, _("地獄", "nether") },
2675- { TR_RES_CHAOS, GF_CHAOS, _("カオス", "chaos") },
2676- { TR_RES_DISEN, GF_DISENCHANT, _("劣化", "disenchant") },
2677- { 0, 0, NULL }
2678-};
2679-
--- a/src/types.h
+++ b/src/types.h
@@ -93,8 +93,3 @@ typedef struct
9393 }
9494 feat_prob;
9595
96-typedef struct {
97- int flag;
98- int type;
99- concptr name;
100-} dragonbreath_type;
Show on old repository browser