return EL_UNDEFINED;
}
+static void SetLevelSettings_SB(struct LevelInfo *level)
+{
+ // time settings
+ level->time = 0;
+ level->use_step_counter = TRUE;
+
+ // score settings
+ level->score[SC_TIME_BONUS] = 0;
+ level->time_score_base = 1;
+ level->rate_time_over_score = TRUE;
+
+ // game settings
+ level->auto_exit_sokoban = TRUE;
+}
+
static void LoadLevelFromFileInfo_SB(struct LevelInfo *level,
struct LevelFileInfo *level_file_info,
boolean level_info_only)
}
// set special level settings for Sokoban levels
-
- level->time = 0;
- level->use_step_counter = TRUE;
- level->auto_exit_sokoban = TRUE;
-
- level->score[SC_TIME_BONUS] = 0;
- level->time_score_base = 1;
- level->rate_time_over_score = TRUE;
+ SetLevelSettings_SB(level);
if (load_xsb_to_ces)
{
// special global settings can now be set in level template
-
level->use_custom_template = TRUE;
}
}
if (is_sokoban_level)
{
// set special level settings for Sokoban levels
- level->time = 0;
- level->use_step_counter = TRUE;
- level->auto_exit_sokoban = TRUE;
-
- level->score[SC_TIME_BONUS] = 0;
- level->time_score_base = 1;
- level->rate_time_over_score = TRUE;
+ SetLevelSettings_SB(level);
}
}