aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
Diffstat (limited to 'engines')
-rw-r--r--engines/zvision/console.cpp12
-rw-r--r--engines/zvision/console.h1
2 files changed, 13 insertions, 0 deletions
diff --git a/engines/zvision/console.cpp b/engines/zvision/console.cpp
index aaf43c598f..9c7d79a8f1 100644
--- a/engines/zvision/console.cpp
+++ b/engines/zvision/console.cpp
@@ -47,6 +47,7 @@ Console::Console(ZVision *engine) : GUI::Debugger(), _engine(engine) {
DCmd_Register("setpanoramafov", WRAP_METHOD(Console, cmdSetPanoramaFoV));
DCmd_Register("setpanoramascale", WRAP_METHOD(Console, cmdSetPanoramaScale));
DCmd_Register("changelocation", WRAP_METHOD(Console, cmdChangeLocation));
+ DCmd_Register("dumpfile", WRAP_METHOD(Console, cmdDumpFile));
}
bool Console::cmdLoadImage(int argc, const char **argv) {
@@ -163,4 +164,15 @@ bool Console::cmdChangeLocation(int argc, const char **argv) {
return true;
}
+bool Console::cmdDumpFile(int argc, const char **argv) {
+ if (argc != 2) {
+ DebugPrintf("Use dumpfile <fileName> to dump a file");
+ return true;
+ }
+
+ writeFileContentsToFile(argv[1], argv[1]);
+
+ return true;
+}
+
} // End of namespace ZVision
diff --git a/engines/zvision/console.h b/engines/zvision/console.h
index d7d2ce904b..be3ebf10dc 100644
--- a/engines/zvision/console.h
+++ b/engines/zvision/console.h
@@ -46,6 +46,7 @@ private:
bool cmdSetPanoramaFoV(int argc, const char **argv);
bool cmdSetPanoramaScale(int argc, const char **argv);
bool cmdChangeLocation(int argc, const char **argv);
+ bool cmdDumpFile(int argc, const char **argv);
};
} // End of namespace ZVision