変愚蛮怒のメインリポジトリです
Revision | 4615224341a021ecb63bf7051eb7a5d404cfe2fa (tree) |
---|---|
Time | 2019-03-12 13:29:24 |
Author | deskull <deskull@user...> |
Commiter | deskull |
[Refactor] #37353 パトロン周りの整理。 / Refactor about patrons.
@@ -16,6 +16,7 @@ | ||
16 | 16 | #include "history.h" |
17 | 17 | #include "monsterrace-hook.h" |
18 | 18 | #include "store.h" |
19 | +#include "patron.h" | |
19 | 20 | #include "quest.h" |
20 | 21 | #include "player-status.h" |
21 | 22 | #include "spells.h" |
@@ -148,7 +148,6 @@ | ||
148 | 148 | #define MAX_SEXES 2 /*!< 性別の定義最大数 / Maximum number of player "sex" types (see "table.c", etc) */ |
149 | 149 | #define MAX_CLASS 28 /*!< 職業の最大定義数 Maximum number of player "class" types (see "table.c", etc) */ |
150 | 150 | #define MAX_SEIKAKU 13 /*!< 性格の最大定義数 */ |
151 | -#define MAX_PATRON 16 /*!< カオスパトロンの最大定義数 / The number of "patrons" available (for Chaos Warriors) */ | |
152 | 151 | |
153 | 152 | /* ELDRITCH_HORRORによるsanity blast処理に関するメッセージの最大数 / Number of entries in the sanity-blast descriptions */ |
154 | 153 | #define MAX_SAN_HORROR 20 /*!< 恐ろしい対象の形容数(正常時) */ |
@@ -92,9 +92,6 @@ extern const concptr color_names[16]; | ||
92 | 92 | extern const concptr stat_names[6]; |
93 | 93 | extern const concptr stat_names_reduced[6]; |
94 | 94 | extern const concptr window_flag_desc[32]; |
95 | -extern const concptr chaos_patrons[MAX_PATRON]; | |
96 | -extern const int chaos_stats[MAX_PATRON]; | |
97 | -extern const int chaos_rewards[MAX_PATRON][20]; | |
98 | 95 | extern const martial_arts ma_blows[MAX_MA]; |
99 | 96 | extern const int monk_ave_damage[PY_MAX_LEVEL+1][3]; |
100 | 97 | extern const concptr game_inscriptions[]; |
@@ -24,6 +24,7 @@ | ||
24 | 24 | #include "avatar.h" |
25 | 25 | #include "shoot.h" |
26 | 26 | #include "player-move.h" |
27 | +#include "patron.h" | |
27 | 28 | |
28 | 29 | |
29 | 30 | /* |
@@ -51,6 +51,7 @@ | ||
51 | 51 | #include "spells-status.h" |
52 | 52 | #include "object-hook.h" |
53 | 53 | #include "wild.h" |
54 | +#include "patron.h" | |
54 | 55 | |
55 | 56 | |
56 | 57 | /* |
@@ -17,6 +17,7 @@ | ||
17 | 17 | #include "projection.h" |
18 | 18 | #include "monster.h" |
19 | 19 | #include "spells-summon.h" |
20 | +#include "patron.h" | |
20 | 21 | #include "quest.h" |
21 | 22 | #include "artifact.h" |
22 | 23 | #include "avatar.h" |
@@ -3123,11 +3124,7 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item) | ||
3123 | 3124 | |
3124 | 3125 | do_cmd_write_nikki(NIKKI_BUNSHOU, 0, _("見事に変愚蛮怒の勝利者となった!", "become *WINNER* of Hengband finely!")); |
3125 | 3126 | |
3126 | - if ((p_ptr->pclass == CLASS_CHAOS_WARRIOR) || (p_ptr->muta2 & MUT2_CHAOS_GIFT)) | |
3127 | - { | |
3128 | - msg_format(_("%sからの声が響いた。", "The voice of %s booms out:"), chaos_patrons[p_ptr->chaos_patron]); | |
3129 | - msg_print(_("『よくやった、定命の者よ!』", "'Thou art donst well, mortal!'")); | |
3130 | - } | |
3127 | + admire_from_patron(p_ptr); | |
3131 | 3128 | |
3132 | 3129 | /* Congratulations */ |
3133 | 3130 | msg_print(_("*** おめでとう ***", "*** CONGRATULATIONS ***")); |
@@ -1,6 +1,7 @@ | ||
1 | -#include "patron.h" | |
2 | - | |
1 | + | |
3 | 2 | #include "angband.h" |
3 | + | |
4 | +#include "patron.h" | |
4 | 5 | #include "cmd-pet.h" |
5 | 6 | #include "object-curse.h" |
6 | 7 | #include "monsterrace-hook.h" |
@@ -661,3 +662,11 @@ void gain_level_reward(int chosen_reward) | ||
661 | 662 | } |
662 | 663 | } |
663 | 664 | |
665 | +void admire_from_patron(player_type *creature_ptr) | |
666 | +{ | |
667 | + if ((creature_ptr->pclass == CLASS_CHAOS_WARRIOR) || (creature_ptr->muta2 & MUT2_CHAOS_GIFT)) | |
668 | + { | |
669 | + msg_format(_("%sからの声が響いた。", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]); | |
670 | + msg_print(_("『よくやった、定命の者よ!』", "'Thou art donst well, mortal!'")); | |
671 | + } | |
672 | +} |
@@ -1,4 +1,7 @@ | ||
1 | -/* カオスパトロンからの報酬種別定義 / Chaos Warrior: Reward types: */ | |
1 | + | |
2 | +#define MAX_PATRON 16 /*!< カオスパトロンの最大定義数 / The number of "patrons" available (for Chaos Warriors) */ | |
3 | + | |
4 | +/* カオスパトロンからの報酬種別定義 / Chaos Warrior: Reward types: */ | |
2 | 5 | #define REW_POLY_SLF 1 /*!< カオスパトロンからの報酬: 自己変容 */ |
3 | 6 | #define REW_GAIN_EXP 2 /*!< カオスパトロンからの報酬: 経験値増加 */ |
4 | 7 | #define REW_LOSE_EXP 3 /*!< カオスパトロンからの報酬: 経験値減少 */ |
@@ -37,3 +40,6 @@ | ||
37 | 40 | #define REW_SER_MONS 36 /*!< カオスパトロンからの報酬: モンスターの下僕下賜 */ |
38 | 41 | |
39 | 42 | extern void gain_level_reward(int chosen_reward); |
43 | +extern void admire_from_patron(player_type *creature_ptr); | |
44 | +extern const concptr chaos_patrons[MAX_PATRON]; | |
45 | + |