Difference for main/hudlog.c from version 1.7 to 1.8


version 1.7 version 1.8
Line 36
 
Line 36
 }  }
   
 void hud_log_check_multi_start(void){  void hud_log_check_multi_start(void){
   #ifdef NETWORK
  if ((Game_mode & GM_MULTI) && HUD_log_multi_autostart){   if ((Game_mode & GM_MULTI) && HUD_log_multi_autostart){
  if (!fhudlog || !fhudmulti)   if (!fhudlog || !fhudmulti)
  open_hud_log();//don't reopen the log file (for example, when changing levels in a multi player game)   open_hud_log();//don't reopen the log file (for example, when changing levels in a multi player game)
  }   }
   #endif
 }  }
 void hud_log_check_multi_stop(void){  void hud_log_check_multi_stop(void){
   #ifdef NETWORK
  if (HUD_log_multi_autostart && fhudmulti){   if (HUD_log_multi_autostart && fhudmulti){
  close_hud_log();   close_hud_log();
  }   }
   #endif
 }  }
   
 void open_hud_log(void){  void open_hud_log(void){
Line 55
 
Line 59
   
  if (fhudlog)close_hud_log();   if (fhudlog)close_hud_log();
   
   #ifdef NETWORK
  fhudmulti = Game_mode & GM_MULTI;   fhudmulti = Game_mode & GM_MULTI;
   #endif
   
  t=time(NULL);   t=time(NULL);
  lt=localtime(&t);   lt=localtime(&t);
Line 94
 
Line 100
 // printf("hud_log_message %i %i %i %p: %s\n",recurse_flag,HUD_log_autostart,HUD_log_multi_autostart,fhudlog,message);  // printf("hud_log_message %i %i %i %p: %s\n",recurse_flag,HUD_log_autostart,HUD_log_multi_autostart,fhudlog,message);
  if (++recurse_flag==1){//avoid infinite loop.  doh.   if (++recurse_flag==1){//avoid infinite loop.  doh.
  if (fhudlog){   if (fhudlog){
   #ifdef MULTI
  if (HUD_log_multi_autostart && ((Game_mode & GM_MULTI) != fhudmulti))   if (HUD_log_multi_autostart && ((Game_mode & GM_MULTI) != fhudmulti))
  close_hud_log();//if we are using -hudlog_multi, presumably we would want multiplayer games in seperate log files than single player, so close the log file and let a new one be reopened if needed.   close_hud_log();//if we are using -hudlog_multi, presumably we would want multiplayer games in seperate log files than single player, so close the log file and let a new one be reopened if needed.
   #endif
  }   }
  if (!fhudlog){   if (!fhudlog){
  if (HUD_log_autostart)   if (HUD_log_autostart)
  open_hud_log();   open_hud_log();
   #ifdef MULTI
  else if ((Game_mode & GM_MULTI) && HUD_log_multi_autostart){   else if ((Game_mode & GM_MULTI) && HUD_log_multi_autostart){
  open_hud_log();   open_hud_log();
  }   }
   #endif
  }   }
  }   }
  --recurse_flag;   --recurse_flag;

Legend:
line(s) removed in v.1.7 
line(s) changed
 line(s) added in v.1.8