OSDN Git Service

プレイヤーの壁掘り移動判定のバグ修正.
authornothere <nothere@0568b783-4c39-0410-ac80-bf13821ea2a2>
Fri, 28 Nov 2003 01:50:14 +0000 (01:50 +0000)
committernothere <nothere@0568b783-4c39-0410-ac80-bf13821ea2a2>
Fri, 28 Nov 2003 01:50:14 +0000 (01:50 +0000)
* 入れない地形かどうかを見ずにLOSの有無を見ていて, 透明な壁が掘れなく
  なっていたバグを修正.
* 移動可能な非LOS地形 (木など) の上にアーティファクトがあれば地形を掘
  れないバグを修正.

src/cmd1.c

index 4c18192..76fe5d8 100644 (file)
@@ -3571,7 +3571,8 @@ void move_player(int dir, int do_pickup, bool break_trap)
        /* Player can not walk through "walls"... */
        /* unless in Shadow Form */
        p_can_kill_walls = p_ptr->kill_wall && have_flag(f_ptr->flags, FF_TUNNEL) &&
-               !cave_floor_grid(c_ptr) && cave_valid_bold(y, x);
+               (!p_can_enter || !have_flag(f_ptr->flags, FF_LOS)) &&
+               !have_flag(f_ptr->flags, FF_PERMANENT);
 
        /* Hack -- attack monsters */
        if (c_ptr->m_idx && (m_ptr->ml || p_can_enter || p_can_kill_walls))