Difference for server/spell_effect.c from version 1.94 to 1.95


version 1.94 version 1.95
Line 1
 
Line 1
 /*  /*
  * static char *rcsid_spell_effect_c =   * static char *rcsid_spell_effect_c =
  *   "$Id: spell_effect.c,v 1.94 2003/01/30 00:07:09 garbled Exp $";   *   "$Id: spell_effect.c,v 1.95 2003/02/03 07:23:48 mwedel Exp $";
  */   */
   
   
Line 1268
 
Line 1268
 }  }
   
 int dimension_door(object *op,int dir) {  int dimension_door(object *op,int dir) {
     int dist, maxdist;      int dist, maxdist, mflags;
   
     if(op->type!=PLAYER)      if(op->type!=PLAYER)
  return 0;   return 0;
Line 1290
 
Line 1290
      return 0;       return 0;
  }   }
   
  for(dist=0;dist<op->contr->count; dist++)   for(dist=0;dist<op->contr->count; dist++) {
      if (get_map_flags(op->map, NULL,        mflags = 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 | P_OUT_OF_MAP)) break;   NULL, NULL);
   
        if ((mflags & (P_NO_MAGIC | P_OUT_OF_MAP)) ||
    ((mflags & P_NO_PASS) && (mflags & P_BLOCKSVIEW))) 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");
Line 1321
 
Line 1325
  * spaces that blocked the players view.   * spaces that blocked the players view.
  */   */
   
  for(dist=1; dist < maxdist; dist++)   for(dist=0; dist < maxdist; dist++) {
      if (get_map_flags(op->map, NULL,        mflags = get_map_flags(op->map, NULL,
        op->x+freearr_x[dir] * dist,    op->x+freearr_x[dir] * (dist+1),
        op->y+freearr_y[dir] * dist,           op->y+freearr_y[dir] * (dist+1),
        NULL, NULL) & (P_NO_MAGIC | P_OUT_OF_MAP)) {           NULL, NULL);
  dist--;       if ((mflags & (P_NO_MAGIC | P_OUT_OF_MAP)) ||
    ((mflags & P_NO_PASS) && (mflags & P_BLOCKSVIEW))) {
  break;   break;
      }       }
    }
   
  /* If the destinate is blocked, keep backing up until we   /* If the destination is blocked, keep backing up until we
  * find a place for the player.   * find a place for the player.
  */   */
  for(;dist>0; dist--)   for(;dist>0; dist--)
Line 3443
 
Line 3449
 int animate_weapon(object *op,object *caster,int dir, archetype *at, int spellnum) {  int animate_weapon(object *op,object *caster,int dir, archetype *at, int spellnum) {
     object *weapon, *tmp;      object *weapon, *tmp;
     char buf[MAX_BUF];      char buf[MAX_BUF];
     int a, i, j;      int a, i;
     sint16 x, y;      sint16 x, y;
     int magic;      int magic;
     mapstruct *m;      mapstruct *m;


Legend:
line(s) removed in v.1.94 
line(s) changed
 line(s) added in v.1.95

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