Difference for common/map.c from version 1.28 to 1.29


version 1.28 version 1.29
Line 1
 
Line 1
 /*  /*
  * static char *rcsid_map_c =   * static char *rcsid_map_c =
  *   "$Id: map.c,v 1.28 2001/12/17 04:15:20 mwedel Exp $";   *   "$Id: map.c,v 1.29 2001/12/18 08:58:03 garbled Exp $";
  */   */
   
 /*  /*
Line 643
 
Line 643
     /* Gah - these should really have a zero default! */      /* Gah - these should really have a zero default! */
     MAP_ENTER_X(map)=1;      MAP_ENTER_X(map)=1;
     MAP_ENTER_Y(map)=1;      MAP_ENTER_Y(map)=1;
   #if 0
       /* the calloc should already clear all this */
       map->next=NULL;
       map->path[0]='\0';
       map->tmpname=NULL;
       map->players=0;
       map->timeout=0;
       map->light = (objectlink *) NULL;
       map->darkness = 0;
       map->do_los=0;
       map->map_object = NULL;
       map->buttons = NULL;
       map->compressed = 0;
   #endif
     return map;      return map;
 }  }
   
Line 788
 
Line 802
      tile, m->path);       tile, m->path);
      } else {       } else {
  *end = 0;   *end = 0;
  if (m->tile_path[tile-1]) {   if (m->tile_path[tile]) {
      LOG(llevError,"load_map_header: tile location %d duplicated (%s)\n",       LOG(llevError,"load_map_header: tile location %d duplicated (%s)\n",
  tile, m->path);   tile, m->path);
      free(m->tile_path[tile-1]);       free(m->tile_path[tile]);
  }   }
  if (!editor) {   if (!editor) {
      if (check_path(value, 1)==-1) {       if (check_path(value, 1)==-1) {
Line 1186
 
Line 1200
     if (m->buttons)      if (m->buttons)
  free_objectlinkpt(m->buttons);   free_objectlinkpt(m->buttons);
     m->buttons = NULL;      m->buttons = NULL;
     for (i=0; i<4; i++) {      for (i=0; i<4; i++)
  if (m->tile_path[i]) FREE_AND_CLEAR(m->tile_path[i]);   if (m->tile_path[i]) FREE_AND_CLEAR(m->tile_path[i]);
  m->tile_map[i] = NULL;  
     }  
     m->in_memory = MAP_SWAPPED;      m->in_memory = MAP_SWAPPED;
 }  }
   
Line 1226
 
Line 1238
      * tiling can be assymetric, we just can not look to see which       * tiling can be assymetric, we just can not look to see which
      * maps this map tiles with and clears those.       * maps this map tiles with and clears those.
      */       */
     for (tmp = first_map; tmp != NULL; tmp = tmp->next) {      for (tmp = first_map; tmp != m; tmp = tmp->next) {
  if (tmp->next == m) last = tmp;   if (tmp->next == m) last = tmp;
   
  /* This should hopefully get unrolled on a decent compiler */   /* This should hopefully get unrolled on a decent compiler */
Line 1275
 
Line 1287
     m = has_been_loaded (name);      m = has_been_loaded (name);
   
     /* Map is good to go, so just return it */      /* Map is good to go, so just return it */
     if (m && (m->in_memory == MAP_LOADING || m->in_memory == MAP_IN_MEMORY))      if (m && (m->in_memory == MAP_LOADING || m->in_memory == MAP_IN_MEMORY)) {
    (*set_darkness_map_func)(m);
  return m;   return m;
       }
   
     /* unique maps always get loaded from their original location, and never      /* unique maps always get loaded from their original location, and never
      * a temp location.  Likewise, if map_flush is set, or we have never loaded       * a temp location.  Likewise, if map_flush is set, or we have never loaded
Line 1337
 
Line 1351
   
     /* In case other objects press some buttons down */      /* In case other objects press some buttons down */
     update_buttons(m);      update_buttons(m);
       (*set_darkness_map_func)(m);
     return m;      return m;
 }  }
   


Legend:
line(s) removed in v.1.28 
line(s) changed
 line(s) added in v.1.29

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