aboutsummaryrefslogtreecommitdiff
path: root/engines/wage/script.h
diff options
context:
space:
mode:
Diffstat (limited to 'engines/wage/script.h')
-rw-r--r--engines/wage/script.h14
1 files changed, 11 insertions, 3 deletions
diff --git a/engines/wage/script.h b/engines/wage/script.h
index 1a7d07d29a..2cd4f11f0d 100644
--- a/engines/wage/script.h
+++ b/engines/wage/script.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -80,31 +80,37 @@ private:
Operand(Obj *value, OperandType type) {
_value.obj = value;
+ assert(type == OBJ);
_type = type;
}
Operand(Chr *value, OperandType type) {
_value.chr = value;
+ assert(type == CHR);
_type = type;
}
Operand(Scene *value, OperandType type) {
_value.scene = value;
+ assert(type == SCENE);
_type = type;
}
Operand(int value, OperandType type) {
_value.number = value;
+ assert(type == NUMBER);
_type = type;
}
Operand(Common::String *value, OperandType type) {
_value.string = value;
+ assert(type == STRING || type == TEXT_INPUT);
_type = type;
}
Operand(Designed *value, OperandType type) {
_value.inputClick = value;
+ assert(type == CLICK_INPUT);
_type = type;
}
@@ -144,8 +150,10 @@ private:
void assign(byte operandType, int uservar, uint16 value);
- Common::Array<ScriptText *> _scriptText;
void convertToText();
+
+public:
+ Common::Array<ScriptText *> _scriptText;
};
} // End of namespace Wage