aboutsummaryrefslogtreecommitdiff
path: root/engines/fullpipe
diff options
context:
space:
mode:
Diffstat (limited to 'engines/fullpipe')
-rw-r--r--engines/fullpipe/motion.cpp28
-rw-r--r--engines/fullpipe/motion.h19
2 files changed, 43 insertions, 4 deletions
diff --git a/engines/fullpipe/motion.cpp b/engines/fullpipe/motion.cpp
index 283777041a..607cc3a390 100644
--- a/engines/fullpipe/motion.cpp
+++ b/engines/fullpipe/motion.cpp
@@ -482,8 +482,34 @@ void MGM::clear() {
warning("STUB: MGM:clear()");
}
+MGMItem::MGMItem() {
+ objId = 0;
+ subItems = 0;
+ staticsListCount = 0;
+ movementListCount = 0;
+ statics = 0;
+ movements1 = 0;
+ movements2 = 0;
+}
+
void MGM::addItem(int objId) {
- warning("STUB: MGM:addItem(%d)", objId);
+ if (getItemIndexById(objId) == -1) {
+ MGMItem *item = new MGMItem();
+
+ item->objId = objId;
+ _items.push_back(item);
+ }
+ rebuildTables(objId);
+}
+
+void MGM::rebuildTables(int objId) {
+ warning("STUB: MGM:rebuildTables()");
+}
+
+int MGM::getItemIndexById(int objId) {
+ warning("STUB: MGM:getItemIndexById()");
+
+ return -1;
}
MovGraphLink::MovGraphLink() {
diff --git a/engines/fullpipe/motion.h b/engines/fullpipe/motion.h
index 23472297a9..09485507d7 100644
--- a/engines/fullpipe/motion.h
+++ b/engines/fullpipe/motion.h
@@ -100,15 +100,28 @@ class MctlCompound : public MotionController {
void initMovGraph2();
};
+struct MGMItem {
+ int16 objId;
+ int subItems;
+ int staticsListCount;
+ int movementListCount;
+ int statics;
+ int movements1;
+ int movements2;
+
+ MGMItem();
+};
+
+
class MGM : public CObject {
public:
- int _items;
- int _count;
+ Common::Array<MGMItem *> _items;
public:
- MGM() : _items(0), _count(0) {}
void clear();
void addItem(int objId);
+ void rebuildTables(int objId);
+ int getItemIndexById(int objId);
};
class MovGraphNode : public CObject {