added explicit level number parameter to high-score handling functions
[rocksndiamonds.git] / src / screens.c
index 2b4539f990d2aa12547abbadc627ca7e7e9874c0..0198a8eea8bdb8e5a472e84b0cd96c67a4d10e9c 100644 (file)
@@ -1087,7 +1087,7 @@ static boolean visibleTextPos(struct TextPosInfo *pos)
 
 static void InitializeMainControls()
 {
-  boolean local_team_mode = (!options.network && setup.team_mode);
+  boolean local_team_mode = (!network.enabled && setup.team_mode);
   int i;
 
   /* set main control text values to dynamically determined values */
@@ -2073,7 +2073,7 @@ void HandleMainMenu(int mx, int my, int dx, int dy, int button)
 
        SetGameStatus(GAME_MODE_SCORES);
 
-       DrawHallOfFame(-1);
+       DrawHallOfFame(level_nr, -1);
       }
       else if (pos == MAIN_CONTROL_EDITOR)
       {
@@ -2101,7 +2101,7 @@ void HandleMainMenu(int mx, int my, int dx, int dy, int button)
       }
       else if (pos == MAIN_CONTROL_GAME)
       {
-       StartGameActions(options.network, setup.autorecord, level.random_seed);
+       StartGameActions(network.enabled, setup.autorecord, level.random_seed);
       }
       else if (pos == MAIN_CONTROL_SETUP)
       {
@@ -4498,7 +4498,7 @@ void HandleChooseLevelNr(int mx, int my, int dx, int dy, int button)
   HandleChooseTree(mx, my, dx, dy, button, &level_number_current);
 }
 
-void DrawHallOfFame(int highlight_position)
+void DrawHallOfFame(int level_nr, int highlight_position)
 {
   int fade_mask = REDRAW_FIELD;
 
@@ -6446,7 +6446,7 @@ static void changeSetupValue(int screen_pos, int setup_info_pos_raw, int dx)
 
   if (si->value == &setup.network_mode &&
       setup.network_mode &&
-      !options.network)
+      !network.enabled)
     Request("Please restart game to enable network games!", REQ_CONFIRM);
 }