aboutsummaryrefslogtreecommitdiff
path: root/engines/titanic/game/maitred
diff options
context:
space:
mode:
authorPaul Gilbert2016-03-02 22:05:25 -0500
committerPaul Gilbert2016-03-02 22:05:25 -0500
commit3ae4e63c80cda635f941370e72536988bde67698 (patch)
treea63cb088bbb9109f7e3ad36cdf20112ebf60f99d /engines/titanic/game/maitred
parent5dce31417cd257785b9bbc790a9686e64a4aff37 (diff)
downloadscummvm-rg350-3ae4e63c80cda635f941370e72536988bde67698.tar.gz
scummvm-rg350-3ae4e63c80cda635f941370e72536988bde67698.tar.bz2
scummvm-rg350-3ae4e63c80cda635f941370e72536988bde67698.zip
TITANIC: Implemented more saveable classes
Diffstat (limited to 'engines/titanic/game/maitred')
-rw-r--r--engines/titanic/game/maitred/maitred_arm_holder.cpp37
-rw-r--r--engines/titanic/game/maitred/maitred_arm_holder.h50
-rw-r--r--engines/titanic/game/maitred/maitred_body.cpp39
-rw-r--r--engines/titanic/game/maitred/maitred_body.h54
-rw-r--r--engines/titanic/game/maitred/maitred_legs.cpp39
-rw-r--r--engines/titanic/game/maitred/maitred_legs.h54
-rw-r--r--engines/titanic/game/maitred/maitred_prod_receptor.cpp45
-rw-r--r--engines/titanic/game/maitred/maitred_prod_receptor.h57
8 files changed, 375 insertions, 0 deletions
diff --git a/engines/titanic/game/maitred/maitred_arm_holder.cpp b/engines/titanic/game/maitred/maitred_arm_holder.cpp
new file mode 100644
index 0000000000..b6fc494441
--- /dev/null
+++ b/engines/titanic/game/maitred/maitred_arm_holder.cpp
@@ -0,0 +1,37 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * 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.
+ *
+ */
+
+#include "titanic/game/maitred/maitred_arm_holder.h"
+
+namespace Titanic {
+
+void CMaitreDArmHolder::save(SimpleFile *file, int indent) const {
+ file->writeNumberLine(1, indent);
+ CDropTarget::save(file, indent);
+}
+
+void CMaitreDArmHolder::load(SimpleFile *file) {
+ file->readNumber();
+ CDropTarget::load(file);
+}
+
+} // End of namespace Titanic
diff --git a/engines/titanic/game/maitred/maitred_arm_holder.h b/engines/titanic/game/maitred/maitred_arm_holder.h
new file mode 100644
index 0000000000..b838109fa3
--- /dev/null
+++ b/engines/titanic/game/maitred/maitred_arm_holder.h
@@ -0,0 +1,50 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * 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.
+ *
+ */
+
+#ifndef TITANIC_MAITRED_ARM_HOLDER_H
+#define TITANIC_MAITRED_ARM_HOLDER_H
+
+#include "titanic/core/drop_target.h"
+
+namespace Titanic {
+
+class CMaitreDArmHolder : public CDropTarget {
+public:
+ /**
+ * Return the class name
+ */
+ virtual const char *getClassName() const { return "CMaitreDArmHolder"; }
+
+ /**
+ * Save the data for the class to file
+ */
+ virtual void save(SimpleFile *file, int indent) const;
+
+ /**
+ * Load the data for the class from file
+ */
+ virtual void load(SimpleFile *file);
+};
+
+} // End of namespace Titanic
+
+#endif /* TITANIC_MAITRED_ARM_HOLDER_H */
diff --git a/engines/titanic/game/maitred/maitred_body.cpp b/engines/titanic/game/maitred/maitred_body.cpp
new file mode 100644
index 0000000000..4cdd5899de
--- /dev/null
+++ b/engines/titanic/game/maitred/maitred_body.cpp
@@ -0,0 +1,39 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * 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.
+ *
+ */
+
+#include "titanic/game/maitred/maitred_legs.h"
+
+namespace Titanic {
+
+void CMaitreDLegs::save(SimpleFile *file, int indent) const {
+ file->writeNumberLine(1, indent);
+ file->writeNumberLine(_fieldC8, indent);
+ CMaitreDProdReceptor::save(file, indent);
+}
+
+void CMaitreDLegs::load(SimpleFile *file) {
+ file->readNumber();
+ _fieldC8 = file->readNumber();
+ CMaitreDProdReceptor::load(file);
+}
+
+} // End of namespace Titanic
diff --git a/engines/titanic/game/maitred/maitred_body.h b/engines/titanic/game/maitred/maitred_body.h
new file mode 100644
index 0000000000..29e528b1f6
--- /dev/null
+++ b/engines/titanic/game/maitred/maitred_body.h
@@ -0,0 +1,54 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * 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.
+ *
+ */
+
+#ifndef TITANIC_MAITRED_BODY_H
+#define TITANIC_MAITRED_BODY_H
+
+#include "titanic/game/maitred/maitred_prod_receptor.h"
+
+namespace Titanic {
+
+class CMaitreDBody : public CMaitreDProdReceptor {
+private:
+ int _fieldC8;
+public:
+ CMaitreDBody() : CMaitreDProdReceptor(), _fieldC8(1) {}
+
+ /**
+ * Return the class name
+ */
+ virtual const char *getClassName() const { return "CMaitreDBody"; }
+
+ /**
+ * Save the data for the class to file
+ */
+ virtual void save(SimpleFile *file, int indent) const;
+
+ /**
+ * Load the data for the class from file
+ */
+ virtual void load(SimpleFile *file);
+};
+
+} // End of namespace Titanic
+
+#endif /* TITANIC_MAITRED_BODY_H */
diff --git a/engines/titanic/game/maitred/maitred_legs.cpp b/engines/titanic/game/maitred/maitred_legs.cpp
new file mode 100644
index 0000000000..ce7054e057
--- /dev/null
+++ b/engines/titanic/game/maitred/maitred_legs.cpp
@@ -0,0 +1,39 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * 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.
+ *
+ */
+
+#include "titanic/game/maitred/maitred_body.h"
+
+namespace Titanic {
+
+void CMaitreDBody::save(SimpleFile *file, int indent) const {
+ file->writeNumberLine(1, indent);
+ file->writeNumberLine(_fieldC8, indent);
+ CMaitreDProdReceptor::save(file, indent);
+}
+
+void CMaitreDBody::load(SimpleFile *file) {
+ file->readNumber();
+ _fieldC8 = file->readNumber();
+ CMaitreDProdReceptor::load(file);
+}
+
+} // End of namespace Titanic
diff --git a/engines/titanic/game/maitred/maitred_legs.h b/engines/titanic/game/maitred/maitred_legs.h
new file mode 100644
index 0000000000..e3ac93c870
--- /dev/null
+++ b/engines/titanic/game/maitred/maitred_legs.h
@@ -0,0 +1,54 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * 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.
+ *
+ */
+
+#ifndef TITANIC_MAITRED_LEGS_H
+#define TITANIC_MAITRED_LEGS_H
+
+#include "titanic/game/maitred/maitred_prod_receptor.h"
+
+namespace Titanic {
+
+class CMaitreDLegs : public CMaitreDProdReceptor {
+private:
+ int _fieldC8;
+public:
+ CMaitreDLegs() : CMaitreDProdReceptor(), _fieldC8(1) {}
+
+ /**
+ * Return the class name
+ */
+ virtual const char *getClassName() const { return "CMaitreDLegs"; }
+
+ /**
+ * Save the data for the class to file
+ */
+ virtual void save(SimpleFile *file, int indent) const;
+
+ /**
+ * Load the data for the class from file
+ */
+ virtual void load(SimpleFile *file);
+};
+
+} // End of namespace Titanic
+
+#endif /* TITANIC_MAITRED_LEGS_H */
diff --git a/engines/titanic/game/maitred/maitred_prod_receptor.cpp b/engines/titanic/game/maitred/maitred_prod_receptor.cpp
new file mode 100644
index 0000000000..6e6143c510
--- /dev/null
+++ b/engines/titanic/game/maitred/maitred_prod_receptor.cpp
@@ -0,0 +1,45 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * 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.
+ *
+ */
+
+#include "titanic/game/maitred/maitred_prod_receptor.h"
+
+namespace Titanic {
+
+void CMaitreDProdReceptor::save(SimpleFile *file, int indent) const {
+ file->writeNumberLine(1, indent);
+ file->writeNumberLine(_fieldBC, indent);
+ file->writeNumberLine(_fieldC0, indent);
+ file->writeNumberLine(_fieldC4, indent);
+
+ CGameObject::save(file, indent);
+}
+
+void CMaitreDProdReceptor::load(SimpleFile *file) {
+ file->readNumber();
+ _fieldBC = file->readNumber();
+ _fieldC0 = file->readNumber();
+ _fieldC4 = file->readNumber();
+
+ CGameObject::load(file);
+}
+
+} // End of namespace Titanic
diff --git a/engines/titanic/game/maitred/maitred_prod_receptor.h b/engines/titanic/game/maitred/maitred_prod_receptor.h
new file mode 100644
index 0000000000..130bc547b2
--- /dev/null
+++ b/engines/titanic/game/maitred/maitred_prod_receptor.h
@@ -0,0 +1,57 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * 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.
+ *
+ */
+
+#ifndef TITANIC_MAITRED_PROD_RECEPTOR_H
+#define TITANIC_MAITRED_PROD_RECEPTOR_H
+
+#include "titanic/core/game_object.h"
+
+namespace Titanic {
+
+class CMaitreDProdReceptor : public CGameObject {
+protected:
+ int _fieldBC;
+ int _fieldC0;
+ int _fieldC4;
+public:
+ CMaitreDProdReceptor() : CGameObject(),
+ _fieldBC(0), _fieldC0(0), _fieldC4(1) {}
+
+ /**
+ * Return the class name
+ */
+ virtual const char *getClassName() const { return "CMaitreDProdReceptor"; }
+
+ /**
+ * Save the data for the class to file
+ */
+ virtual void save(SimpleFile *file, int indent) const;
+
+ /**
+ * Load the data for the class from file
+ */
+ virtual void load(SimpleFile *file);
+};
+
+} // End of namespace Titanic
+
+#endif /* TITANIC_MAITRED_PROD_RECEPTOR_H */