version 1.7 | | version 1.8 |
---|
| | |
/* | | /* |
* static char *rcsid_spell_attack_c = | | * static char *rcsid_spell_attack_c = |
* "$Id: spell_attack.c,v 1.7 2004/02/26 06:17:28 mwedel Exp $"; | | * "$Id: spell_attack.c,v 1.8 2004/02/27 23:00:28 ryo_saeba Exp $"; |
*/ | | */ |
| | |
| | |
| | |
| | |
if(op->range>0) { | | if(op->range>0) { |
for(i=1;i<9;i++) { | | for(i=1;i<9;i++) { |
int dx,dy; | | sint16 dx,dy; |
| | |
dx=op->x+freearr_x[i]; | | dx=op->x+freearr_x[i]; |
dy=op->y+freearr_y[i]; | | dy=op->y+freearr_y[i]; |
| | |
} | | } |
| | |
for(i= -1;i<2;i++) { | | for(i= -1;i<2;i++) { |
int x=op->x+freearr_x[absdir(op->stats.sp+i)], | | sint16 x=op->x+freearr_x[absdir(op->stats.sp+i)], |
y=op->y+freearr_y[absdir(op->stats.sp+i)]; | | y=op->y+freearr_y[absdir(op->stats.sp+i)]; |
| | |
if(ok_to_put_more(op->map,x,y,op,op->attacktype)) { | | if(ok_to_put_more(op->map,x,y,op,op->attacktype)) { |
| | |
} | | } |
| | |
for(i=range_min;i<=range_max;i++) { | | for(i=range_min;i<=range_max;i++) { |
int x,y, d; | | sint16 x,y, d; |
| | |
/* We can't use absdir here, because it never returns | | /* We can't use absdir here, because it never returns |
* 0. If this is a rune, we want to hit the person on top | | * 0. If this is a rune, we want to hit the person on top |
| | |
| | |
object *tmp; | | object *tmp; |
| | |
int dx=op->x+freearr_x[dir], dy=op->y+freearr_y[dir]; | | sint16 dx=op->x+freearr_x[dir], dy=op->y+freearr_y[dir]; |
| | |
if(get_map_flags(op->map,NULL, dx,dy, NULL,NULL) & (P_OUT_OF_MAP | P_WALL)) { | | if(get_map_flags(op->map,NULL, dx,dy, NULL,NULL) & (P_OUT_OF_MAP | P_WALL)) { |
new_draw_info(NDI_UNIQUE, 0,op,"There is something in the way."); | | new_draw_info(NDI_UNIQUE, 0,op,"There is something in the way."); |
| | |
*/ | | */ |
| | |
void move_ball_spell(object *op) { | | void move_ball_spell(object *op) { |
int i,nx,ny,j,dam_save,dir, mflags; | | int i,j,dam_save,dir, mflags; |
| | sint16 nx,ny; |
object *owner; | | object *owner; |
mapstruct *m; | | mapstruct *m; |
| | |