aboutsummaryrefslogtreecommitdiff
path: root/engines/fullpipe/motion.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/fullpipe/motion.cpp')
-rw-r--r--engines/fullpipe/motion.cpp17
1 files changed, 15 insertions, 2 deletions
diff --git a/engines/fullpipe/motion.cpp b/engines/fullpipe/motion.cpp
index a1ad4de89f..8aa879477f 100644
--- a/engines/fullpipe/motion.cpp
+++ b/engines/fullpipe/motion.cpp
@@ -507,7 +507,7 @@ bool MctlCompoundArray::load(MfcArchive &file) {
MovGraphItem::MovGraphItem() {
ani = 0;
field_4 = 0;
- field_8 = 0;
+ movarr = 0;
field_C = 0;
field_10 = 0;
field_14 = 0;
@@ -523,6 +523,10 @@ MovGraphItem::MovGraphItem() {
field_3C = 0;
}
+void MovGraphItem::free() {
+ warning("STUB: MovGraphItem::free()");
+}
+
int MovGraph_messageHandler(ExCommand *cmd);
int MovGraphCallback(int a1, int a2, int a3) {
@@ -576,7 +580,16 @@ int MovGraph::removeObject(StaticANIObject *obj) {
}
void MovGraph::freeItems() {
- warning("STUB: MovGraph::freeItems()");
+ for (uint i = 0; i < _items.size(); i++) {
+ _items[i]->free();
+
+ for (int j = 0; j < _items[i]->movarr->size(); j++)
+ delete (_items[i]->movarr)->operator[](j);
+
+ delete _items[i]->movarr;
+ }
+
+ _items.clear();
}
int MovGraph::method28() {