aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugene Sandulenko2013-09-28 13:06:06 +0300
committerEugene Sandulenko2013-09-28 13:06:06 +0300
commitb22c7d28f7d757c56d998a2c5d286e3679ae9249 (patch)
tree62df05e23e163d9fbee8015f683efc330a76a3be
parentd207dcfba64cefc8c3423878c8f20ee7752a862c (diff)
downloadscummvm-rg350-b22c7d28f7d757c56d998a2c5d286e3679ae9249.tar.gz
scummvm-rg350-b22c7d28f7d757c56d998a2c5d286e3679ae9249.tar.bz2
scummvm-rg350-b22c7d28f7d757c56d998a2c5d286e3679ae9249.zip
FULLPIPE: Implement MctlCompound::addObject()
-rw-r--r--engines/fullpipe/motion.cpp15
-rw-r--r--engines/fullpipe/motion.h8
2 files changed, 9 insertions, 14 deletions
diff --git a/engines/fullpipe/motion.cpp b/engines/fullpipe/motion.cpp
index 5def3cb4a7..66664b1de5 100644
--- a/engines/fullpipe/motion.cpp
+++ b/engines/fullpipe/motion.cpp
@@ -76,10 +76,9 @@ bool MctlCompound::load(MfcArchive &file) {
return true;
}
-int MctlCompound::addObject(StaticANIObject *obj) {
- warning("STUB: MctlCompound::addObject()");
-
- return 0;
+void MctlCompound::addObject(StaticANIObject *obj) {
+ for (uint i = 0; i < _motionControllers.size(); i++)
+ _motionControllers[i]->_motionControllerObj->addObject(obj);
}
int MctlCompound::removeObject(StaticANIObject *obj) {
@@ -167,10 +166,8 @@ bool MovGraph::load(MfcArchive &file) {
return true;
}
-int MovGraph::addObject(StaticANIObject *obj) {
+void MovGraph::addObject(StaticANIObject *obj) {
warning("STUB: MovGraph::addObject()");
-
- return 0;
}
int MovGraph::removeObject(StaticANIObject *obj) {
@@ -237,10 +234,8 @@ double MovGraph::calcDistance(Common::Point *point, MovGraphLink *link, int flag
return 0;
}
-int MovGraph2::addObject(StaticANIObject *obj) {
+void MovGraph2::addObject(StaticANIObject *obj) {
warning("STUB: MovGraph2::addObject()");
-
- return 0;
}
int MovGraph2::removeObject(StaticANIObject *obj) {
diff --git a/engines/fullpipe/motion.h b/engines/fullpipe/motion.h
index 3e76f24c60..0f91a99600 100644
--- a/engines/fullpipe/motion.h
+++ b/engines/fullpipe/motion.h
@@ -42,7 +42,7 @@ public:
virtual void method10() {}
virtual void clearEnabled() { _isEnabled = false; }
virtual void setEnabled() { _isEnabled = true; }
- virtual int addObject(StaticANIObject *obj) { return 0; }
+ virtual void addObject(StaticANIObject *obj) {}
virtual int removeObject(StaticANIObject *obj) { return 0; }
virtual void freeItems() {}
virtual int method28() { return 0; }
@@ -91,7 +91,7 @@ class MctlCompound : public MotionController {
virtual bool load(MfcArchive &file);
- virtual int addObject(StaticANIObject *obj);
+ virtual void addObject(StaticANIObject *obj);
virtual int removeObject(StaticANIObject *obj);
virtual void freeItems();
virtual MessageQueue *method34(StaticANIObject *subj, int xpos, int ypos, int flag, int staticsId);
@@ -183,7 +183,7 @@ class MovGraph : public MotionController {
MovGraph();
virtual bool load(MfcArchive &file);
- virtual int addObject(StaticANIObject *obj);
+ virtual void addObject(StaticANIObject *obj);
virtual int removeObject(StaticANIObject *obj);
virtual void freeItems();
virtual int method28();
@@ -204,7 +204,7 @@ public:
ObArray _items;
public:
- virtual int addObject(StaticANIObject *obj);
+ virtual void addObject(StaticANIObject *obj);
virtual int removeObject(StaticANIObject *obj);
virtual void freeItems();
virtual MessageQueue *method34(StaticANIObject *subj, int xpos, int ypos, int flag, int staticsId);