version 1.197 | | version 1.198 |
---|
| | |
/* | | /* |
* static char *rcsid_player_c = | | * static char *rcsid_player_c = |
* "$Id: player.c,v 1.197 2006/05/05 09:26:35 ryo_saeba Exp $"; | | * "$Id: player.c,v 1.198 2006/05/26 23:13:42 akirschbaum Exp $"; |
*/ | | */ |
| | |
/* | | /* |
| | |
blocked = (mflags & P_OUT_OF_MAP) ? MOVE_ALL : GET_MAP_MOVE_BLOCK(m, x, y); | | blocked = (mflags & P_OUT_OF_MAP) ? MOVE_ALL : GET_MAP_MOVE_BLOCK(m, x, y); |
| | |
/* Space is blocked - try changing direction a little */ | | /* Space is blocked - try changing direction a little */ |
if ((mflags & P_OUT_OF_MAP) || ((OB_TYPE_MOVE_BLOCK(mon, blocked)) | | if ((mflags & P_OUT_OF_MAP) || ((OB_TYPE_MOVE_BLOCK(mon, blocked) || (mflags&P_IS_ALIVE)) |
&& (m == mon->map && blocked_link(mon, m, x, y)))) { | | && (m == mon->map && blocked_link(mon, m, x, y)))) { |
/* recalculate direction from last good location. Possible | | /* recalculate direction from last good location. Possible |
* we were not traversing ideal location before. | | * we were not traversing ideal location before. |
| | |
if (mflags & P_OUT_OF_MAP) continue; | | if (mflags & P_OUT_OF_MAP) continue; |
blocked = GET_MAP_MOVE_BLOCK(m, x, y); | | blocked = GET_MAP_MOVE_BLOCK(m, x, y); |
if (OB_TYPE_MOVE_BLOCK(mon, blocked)) continue; | | if (OB_TYPE_MOVE_BLOCK(mon, blocked)) continue; |
| | if (mflags & P_IS_ALIVE) continue; |
| | |
if (m == mon->map && blocked_link(mon, m, x, y)) break; | | if (m == mon->map && blocked_link(mon, m, x, y)) break; |
} | | } |