Difference for server/spell_attack.c from version 1.3 to 1.4


version 1.3 version 1.4
Line 1
 
Line 1
 /*  /*
  * static char *rcsid_spell_attack_c =   * static char *rcsid_spell_attack_c =
  *   "$Id: spell_attack.c,v 1.3 2004/02/13 07:42:10 mwedel Exp $";   *   "$Id: spell_attack.c,v 1.4 2004/02/17 00:22:25 mwedel Exp $";
  */   */
   
   
Line 744
 
Line 744
     }      }
   
     for(i=range_min;i<=range_max;i++) {      for(i=range_min;i<=range_max;i++) {
  int x=op->x+freearr_x[absdir(dir+i)],   int x,y, d;
      y=op->y+freearr_y[absdir(dir+i)];  
    /* We can't use absdir here, because it never returns
    * 0.  If this is a rune, we want to hit the person on top
    * of the trap (d==0).  If it is not a rune, then we don't want
    * to hit that person.
    */
    d = dir + i;
    while (d < 0) d+=8;
    while (d > 8) d-=8;
   
    if (caster->type != RUNE && d==0) continue;
   
    x = op->x+freearr_x[d];
    y = op->y+freearr_y[d];
   
  if(get_map_flags(op->map,NULL, x,y, NULL, NULL) & (P_WALL | P_OUT_OF_MAP))   if(get_map_flags(op->map,NULL, x,y, NULL, NULL) & (P_WALL | P_OUT_OF_MAP))
      continue;       continue;
Line 769
 
Line 782
      tmp->stats.sp=i;       tmp->stats.sp=i;
   
  tmp->range=spell->range + SP_level_range_adjust(caster,spell);   tmp->range=spell->range + SP_level_range_adjust(caster,spell);
   
    /* If casting it in all directions, it doesn't go as far */
    if (dir == 0) {
        tmp->range /= 4;
        if (tmp->range < 2 && spell->range >=2) tmp->range = 2;
    }
  tmp->stats.dam=spell->stats.dam + SP_level_dam_adjust(caster,spell);   tmp->stats.dam=spell->stats.dam + SP_level_dam_adjust(caster,spell);
  tmp->duration=spell->duration + SP_level_duration_adjust(caster,spell);   tmp->duration=spell->duration + SP_level_duration_adjust(caster,spell);
   


Legend:
line(s) removed in v.1.3 
line(s) changed
 line(s) added in v.1.4

File made using version 1.98 of cvs2html by leaf at 2011-07-21 17:47