version 1.90 | | version 1.91 |
---|
| | |
/* | | /* |
* static char *rcsid_spell_effect_c = | | * static char *rcsid_spell_effect_c = |
* "$Id: spell_effect.c,v 1.90 2003/01/08 08:39:21 mwedel Exp $"; | | * "$Id: spell_effect.c,v 1.91 2003/01/15 07:18:06 mwedel Exp $"; |
*/ | | */ |
| | |
| | |
| | |
for(dist=0;dist<op->contr->count; dist++) | | for(dist=0;dist<op->contr->count; dist++) |
if (get_map_flags(op->map, NULL, | | if (get_map_flags(op->map, NULL, |
op->x+freearr_x[dir]*(dist+1), op->y+freearr_y[dir]*(dist+1), | | op->x+freearr_x[dir]*(dist+1), op->y+freearr_y[dir]*(dist+1), |
NULL, NULL) & P_NO_MAGIC) break; | | NULL, NULL) & (P_NO_MAGIC | P_OUT_OF_MAP)) break; |
| | |
if(dist<op->contr->count) { | | if(dist<op->contr->count) { |
new_draw_info(NDI_UNIQUE, 0,op,"Something blocks the magic of the spell.\n"); | | new_draw_info(NDI_UNIQUE, 0,op,"Something blocks the magic of the spell.\n"); |
| | |
if (get_map_flags(op->map, NULL, | | if (get_map_flags(op->map, NULL, |
op->x+freearr_x[dir] * dist, | | op->x+freearr_x[dir] * dist, |
op->y+freearr_y[dir] * dist, | | op->y+freearr_y[dir] * dist, |
NULL, NULL) & P_NO_MAGIC) { | | NULL, NULL) & (P_NO_MAGIC | P_OUT_OF_MAP)) { |
dist--; | | dist--; |
break; | | break; |
} | | } |