Difference for server/time.c from version 1.25 to 1.26


version 1.25 version 1.26
Line 1
 
Line 1
 /*  /*
  * static char *rcsid_time_c =   * static char *rcsid_time_c =
  *    "$Id: time.c,v 1.25 2001/06/13 12:51:58 michtoen Exp $";   *    "$Id: time.c,v 1.26 2001/07/14 04:11:18 mwedel Exp $";
  */   */
   
 /*  /*
Line 90
 
Line 90
     if(head!=NULL)      if(head!=NULL)
       op->head=head,prev->more=op;        op->head=head,prev->more=op;
     if (RANDOM()%10) generate_artifact(op, gen->map->difficulty);      if (RANDOM()%10) generate_artifact(op, gen->map->difficulty);
     insert_ob_in_map(op,gen->map,gen);      insert_ob_in_map(op,gen->map,gen,0);
     if (QUERY_FLAG(op, FLAG_FREED)) return;      if (QUERY_FLAG(op, FLAG_FREED)) return;
     if(op->randomitems!=NULL)      if(op->randomitems!=NULL)
       create_treasure(op->randomitems,op,GT_APPLY,        create_treasure(op->randomitems,op,GT_APPLY,
Line 218
 
Line 218
  if((int)op->stats.wc < (NUM_ANIMATIONS(op)/2+1)) {   if((int)op->stats.wc < (NUM_ANIMATIONS(op)/2+1)) {
      CLEAR_FLAG(op, FLAG_NO_PASS);       CLEAR_FLAG(op, FLAG_NO_PASS);
      CLEAR_FLAG(op, FLAG_BLOCKSVIEW);       CLEAR_FLAG(op, FLAG_BLOCKSVIEW);
      update_all_los(op->map);       update_all_los(op->map, op->x, op->y);
  }   }
  SET_ANIMATION(op, op->stats.wc);   SET_ANIMATION(op, op->stats.wc);
  update_object(op);   update_object(op,UP_OBJ_CHANGE);
  return;   return;
     }      }
   
Line 293
 
Line 293
      if (i!=-1) {       if (i!=-1) {
  remove_ob(tmp);   remove_ob(tmp);
  tmp->x+=freearr_x[i],tmp->y+=freearr_y[i];   tmp->x+=freearr_x[i],tmp->y+=freearr_y[i];
  insert_ob_in_map(tmp,op->map,op);   insert_ob_in_map(tmp,op->map,op,0);
      }       }
  }   }
      }       }
Line 312
 
Line 312
  SET_FLAG(op, FLAG_NO_PASS);    /* The coast is clear, block the way */   SET_FLAG(op, FLAG_NO_PASS);    /* The coast is clear, block the way */
  if(!op->arch->clone.stats.ac)   if(!op->arch->clone.stats.ac)
      SET_FLAG(op, FLAG_BLOCKSVIEW);       SET_FLAG(op, FLAG_BLOCKSVIEW);
  update_all_los(op->map);   update_all_los(op->map, op->x, op->y);
      }       }
  } /* gate is halfway up */   } /* gate is halfway up */
   
  SET_ANIMATION(op, op->stats.wc);   SET_ANIMATION(op, op->stats.wc);
  update_object(op);   update_object(op,UP_OBJ_CHANGE);
     } /* gate is going up */      } /* gate is going up */
 }  }
   
Line 404
 
Line 404
     check_trigger(op,NULL);      check_trigger(op,NULL);
   } else {    } else {
     SET_ANIMATION(op, op->stats.wc);      SET_ANIMATION(op, op->stats.wc);
     update_object(op);      update_object(op,UP_OBJ_FACE);
   }    }
 }  }
   
Line 423
 
Line 423
      }       }
  }   }
  SET_ANIMATION(op, op->stats.wc);   SET_ANIMATION(op, op->stats.wc);
  update_object(op);   update_object(op,UP_OBJ_FACE);
  return;   return;
     }      }
     /* We're closing */      /* We're closing */
Line 432
 
Line 432
     if((int)op->stats.wc >= NUM_ANIMATIONS(op))      if((int)op->stats.wc >= NUM_ANIMATIONS(op))
  op->stats.wc=NUM_ANIMATIONS(op)-1;   op->stats.wc=NUM_ANIMATIONS(op)-1;
     SET_ANIMATION(op, op->stats.wc);      SET_ANIMATION(op, op->stats.wc);
     update_object(op);      update_object(op,UP_OBJ_FACE);
     if((unsigned char) op->stats.wc==(NUM_ANIMATIONS(op)-1)) {      if((unsigned char) op->stats.wc==(NUM_ANIMATIONS(op)-1)) {
  op->speed = 0;   op->speed = 0;
  update_ob_speed(op); /* closed, let's stop */   update_ob_speed(op); /* closed, let's stop */
Line 498
 
Line 498
     if (map == NULL)      if (map == NULL)
         return;          return;
     if (QUERY_FLAG (op, FLAG_REMOVED))      if (QUERY_FLAG (op, FLAG_REMOVED))
         insert_ob_in_map (op, map, originator);          insert_ob_in_map (op, map, originator,0);
     else if (op->type == ARROW)      else if (op->type == ARROW)
         merge_ob (op, NULL);   /* only some arrows actually need this */          merge_ob (op, NULL);   /* only some arrows actually need this */
 }  }
Line 526
 
Line 526
     op->stats.hp = 0;      op->stats.hp = 0;
     op->face=op->arch->clone.face;      op->face=op->arch->clone.face;
     op->owner=NULL; /* So that stopped arrows will be saved */      op->owner=NULL; /* So that stopped arrows will be saved */
     update_object (op);      update_object (op,UP_OBJ_FACE);
     return op;      return op;
 }  }
   
Line 553
 
Line 553
  object *payload = op->inv;   object *payload = op->inv;
  remove_ob (payload);   remove_ob (payload);
  clear_owner(payload);   clear_owner(payload);
         insert_ob_in_map (payload, op->map, payload);          insert_ob_in_map (payload, op->map, payload,0);
         remove_ob (op);          remove_ob (op);
  free_object (op);   free_object (op);
     } else {      } else {
Line 689
 
Line 689
     remove_ob (op);      remove_ob (op);
     op->x = new_x;      op->x = new_x;
     op->y = new_y;      op->y = new_y;
     insert_ob_in_map (op, op->map, op);      insert_ob_in_map (op, op->map, op,0);
 }  }
   
 /* This routine doesnt seem to work for "inanimate" objects that  /* This routine doesnt seem to work for "inanimate" objects that
Line 732
 
Line 732
      free_object(tmp);       free_object(tmp);
  else {   else {
      tmp->x=op->x+freearr_x[j],tmp->y=op->y+freearr_y[j];       tmp->x=op->x+freearr_x[j],tmp->y=op->y+freearr_y[j];
      insert_ob_in_map(tmp,op->map,op);       insert_ob_in_map(tmp,op->map,op,0);
  }   }
     }      }
   }    }
Line 902
 
Line 902
  tmp->title = add_string(op->slaying);   tmp->title = add_string(op->slaying);
   }    }
   tmp->x=op->x;tmp->y=op->y;tmp->map=op->map;tmp->level=op->level;    tmp->x=op->x;tmp->y=op->y;tmp->map=op->map;tmp->level=op->level;
   insert_ob_in_map(tmp,op->map,op);    insert_ob_in_map(tmp,op->map,op,0);
 }  }
   
 /* move_marker --peterm@soda.csua.berkeley.edu  /* move_marker --peterm@soda.csua.berkeley.edu


Legend:
line(s) removed in v.1.25 
line(s) changed
 line(s) added in v.1.26

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