summaryrefslogtreecommitdiff
path: root/src/script/script_info.cpp
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2012-12-05 19:34:45 +0000
committerfrosch <frosch@openttd.org>2012-12-05 19:34:45 +0000
commita499435351fcb7b25e1e49e1366ebeac91636c35 (patch)
tree0941b7701eb2e7c88add8330fecb78b4720c8061 /src/script/script_info.cpp
parent5b2da98ca312f91c93012e7a92fb1120d2b9d1fa (diff)
downloadopenttd-a499435351fcb7b25e1e49e1366ebeac91636c35.tar.xz
(svn r24786) -Codechange: Add SettingsProfile enum for difficulty profiles and highscore tables.
Diffstat (limited to 'src/script/script_info.cpp')
-rw-r--r--src/script/script_info.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/script/script_info.cpp b/src/script/script_info.cpp
index b5a83ccb2..94c977225 100644
--- a/src/script/script_info.cpp
+++ b/src/script/script_info.cpp
@@ -294,10 +294,10 @@ int ScriptInfo::GetSettingDefaultValue(const char *name) const
if (strcmp((*it).name, name) != 0) continue;
/* The default value depends on the difficulty level */
switch (GetGameSettings().difficulty.diff_level) {
- case 0: return (*it).easy_value;
- case 1: return (*it).medium_value;
- case 2: return (*it).hard_value;
- case 3: return (*it).custom_value;
+ case SP_EASY: return (*it).easy_value;
+ case SP_MEDIUM: return (*it).medium_value;
+ case SP_HARD: return (*it).hard_value;
+ case SP_CUSTOM: return (*it).custom_value;
default: NOT_REACHED();
}
}