• R/O
  • HTTP
  • SSH
  • HTTPS

hengband: Commit

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


Commit MetaInfo

Revisiond905dc395bccfa31f1c7973444e1c53a976e9d96 (tree)
Time2019-03-13 13:26:33
Authordeskull <deskull@user...>
Commiterdeskull

Log Message

[Fix] #38844 ambush_flag の player_type 入りが不完全だったのを修正。 Fix incompleted refactoring of ambush_flag.

Change Summary

Incremental Difference

--- a/src/dungeon.c
+++ b/src/dungeon.c
@@ -3984,7 +3984,7 @@ static void process_command(void)
39843984 {
39853985 if (vanilla_town) break;
39863986
3987- if (ambush_flag)
3987+ if (p_ptr->ambush_flag)
39883988 {
39893989 msg_print(_("襲撃から逃げるにはマップの端まで移動しなければならない。", "To flee the ambush you have to reach the edge of the map."));
39903990 break;
@@ -5184,7 +5184,7 @@ static void dungeon(bool load_game)
51845184 target_who = 0;
51855185 pet_t_m_idx = 0;
51865186 riding_t_m_idx = 0;
5187- ambush_flag = FALSE;
5187+ p_ptr->ambush_flag = FALSE;
51885188
51895189 /* Cancel the health bar */
51905190 health_track(0);
--- a/src/load.c
+++ b/src/load.c
@@ -3694,8 +3694,8 @@ static errr rd_savefile_new_aux(void)
36943694
36953695 if (z_older_than(10, 3, 7)) p_ptr->wild_mode = FALSE;
36963696 else rd_byte((byte *)&p_ptr->wild_mode);
3697- if (z_older_than(10, 3, 7)) ambush_flag = FALSE;
3698- else rd_byte((byte *)&ambush_flag);
3697+ if (z_older_than(10, 3, 7)) p_ptr->ambush_flag = FALSE;
3698+ else rd_byte((byte *)&p_ptr->ambush_flag);
36993699
37003700 /* Size of the wilderness */
37013701 rd_s32b(&wild_x_size);
--- a/src/save.c
+++ b/src/save.c
@@ -1410,7 +1410,7 @@ static bool wr_savefile_new(void)
14101410 wr_s32b(p_ptr->wilderness_y);
14111411
14121412 wr_byte(p_ptr->wild_mode);
1413- wr_byte(ambush_flag);
1413+ wr_byte(p_ptr->ambush_flag);
14141414
14151415 wr_s32b(current_world_ptr->max_wild_x);
14161416 wr_s32b(current_world_ptr->max_wild_y);
--- a/src/util.c
+++ b/src/util.c
@@ -1681,7 +1681,7 @@ void select_floor_music(void)
16811681 /* No sound */
16821682 if (!use_music) return;
16831683
1684- if(ambush_flag)
1684+ if(p_ptr->ambush_flag)
16851685 {
16861686 play_music(TERM_XTRA_MUSIC_BASIC, MUSIC_BASIC_AMBUSH);
16871687 return;
--- a/src/wild.c
+++ b/src/wild.c
@@ -676,7 +676,7 @@ void wilderness_gen(void)
676676 (void)alloc_monster(generate_encounter ? 0 : 3, mode);
677677 }
678678
679- if(generate_encounter) ambush_flag = TRUE;
679+ if(generate_encounter) p_ptr->ambush_flag = TRUE;
680680 generate_encounter = FALSE;
681681
682682 /* Fill the arrays of floors and walls in the good proportions */
Show on old repository browser