Difference for random_maps/random_map.c from version 1.14 to 1.15


version 1.14 version 1.15
Line 1
 
Line 1
 /*  /*
  * static char *rcsid_random_map_c =   * static char *rcsid_random_map_c =
  *   "$Id: random_map.c,v 1.14 2001/01/16 08:20:53 peterm Exp $";   *   "$Id: random_map.c,v 1.15 2001/01/31 07:54:51 cvs Exp $";
  */   */
   
 /*  /*
Line 35
 
Line 35
 #include <rproto.h>  #include <rproto.h>
 #include <sproto.h>  #include <sproto.h>
   
 #define LO_NEWFILE 2  
   
   
   
   
 EXTERN FILE *logfile;  EXTERN FILE *logfile;
 mapstruct *generate_random_map(char *InFileName,char *OutFileName) {  mapstruct *generate_random_map(char *OutFileName, RMParms *RP) {
   FILE *InFile;  
   char **layout;    char **layout;
   mapstruct *theMap;    mapstruct *theMap;
   RMParms *RP;  
   RP = (RMParms *) calloc(1,sizeof(RMParms));  
   
   /* set up the random numbers */  
   
   RP->Xsize=-1;  
   RP->Ysize=-1;  
   
   RP->generate_treasure_now=1;  
   
   if((InFile=fopen(InFileName,"r"))==NULL) {  
     printf("\nError:  can't open %s\n",InFileName);  
     return(0);  
   }   
   
   load_parameters(InFile,LO_NEWFILE,RP);  
   
   /* pick a random seed, or use the one from the input file */    /* pick a random seed, or use the one from the input file */
   if(RP->random_seed == 0)    SRANDOM(time(0));    if(RP->random_seed == 0)    SRANDOM(time(0));
Line 119
 
Line 99
   if(RP->generate_treasure_now)    if(RP->generate_treasure_now)
     fix_auto_apply(theMap);      fix_auto_apply(theMap);
   
   
   fclose(InFile);  
   /*  fclose(OutFile); */    /*  fclose(OutFile); */
   /*new_save_map(theMap,1);*/    /*new_save_map(theMap,1);*/
   return theMap;    return theMap;


Legend:
line(s) removed in v.1.14 
line(s) changed
 line(s) added in v.1.15

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