aboutsummaryrefslogtreecommitdiff
path: root/engines/lab
diff options
context:
space:
mode:
authorFilippos Karapetis2015-12-24 12:36:26 +0200
committerFilippos Karapetis2015-12-24 12:36:26 +0200
commit3097ac8f1e336193755b2386506842ef76951b13 (patch)
tree71214eb8eed65d956e310f0d87ae090c92f2da87 /engines/lab
parentf018b44ff869cc774923818caccf203ff9c56e0b (diff)
downloadscummvm-rg350-3097ac8f1e336193755b2386506842ef76951b13.tar.gz
scummvm-rg350-3097ac8f1e336193755b2386506842ef76951b13.tar.bz2
scummvm-rg350-3097ac8f1e336193755b2386506842ef76951b13.zip
LAB: Change condition defines into an enum
Diffstat (limited to 'engines/lab')
-rw-r--r--engines/lab/engine.cpp4
-rw-r--r--engines/lab/processroom.h11
-rw-r--r--engines/lab/special.cpp13
3 files changed, 15 insertions, 13 deletions
diff --git a/engines/lab/engine.cpp b/engines/lab/engine.cpp
index d51106523e..8d859bc84e 100644
--- a/engines/lab/engine.cpp
+++ b/engines/lab/engine.cpp
@@ -62,10 +62,6 @@ enum Items {
kItemQuarter = 30
};
-#define kCondLampOn 151
-#define kCondBeltGlowing 70
-#define kCondUsedHelmet 184
-
enum Monitors {
kMonitorMuseum = 71,
kMonitorGramophone = 72,
diff --git a/engines/lab/processroom.h b/engines/lab/processroom.h
index 31a8f281db..37585bc05c 100644
--- a/engines/lab/processroom.h
+++ b/engines/lab/processroom.h
@@ -91,6 +91,17 @@ enum RuleAction {
kRuleActionTakeDef = 4
};
+enum Condition {
+ kCondBeltGlowing = 70,
+ kCondBridge1 = 104,
+ kCondNoNews = 135,
+ kCondBridge0 = 148,
+ kCondLampOn = 151,
+ kCondNoClean = 152,
+ kCondDirty = 175,
+ kCondUsedHelmet = 184
+};
+
#if defined(WIN32)
#pragma pack(push, 1)
#endif
diff --git a/engines/lab/special.cpp b/engines/lab/special.cpp
index 8c69fb4034..de9f1d9786 100644
--- a/engines/lab/special.cpp
+++ b/engines/lab/special.cpp
@@ -41,11 +41,6 @@
#include "lab/utils.h"
namespace Lab {
-#define BRIDGE0 148
-#define BRIDGE1 104
-#define DIRTY 175
-#define NONEWS 135
-#define NOCLEAN 152
void LabEngine::doNotes() {
TextFont *noteFont = _resource->getFont("F:Note.fon");
@@ -103,10 +98,10 @@ void LabEngine::loadJournalData() {
Common::String filename = "Lab:Rooms/j";
- bool bridge = _conditions->in(BRIDGE0) || _conditions->in(BRIDGE1);
- bool dirty = _conditions->in(DIRTY);
- bool news = !_conditions->in(NONEWS);
- bool clean = !_conditions->in(NOCLEAN);
+ bool bridge = _conditions->in(kCondBridge0) || _conditions->in(kCondBridge1);
+ bool dirty = _conditions->in(kCondDirty);
+ bool news = !_conditions->in(kCondNoNews);
+ bool clean = !_conditions->in(kCondNoClean);
if (bridge && clean && news)
filename += '8';