aboutsummaryrefslogtreecommitdiff
path: root/engines/chewy
diff options
context:
space:
mode:
authorFilippos Karapetis2016-10-03 01:38:48 +0300
committerFilippos Karapetis2016-10-03 01:38:48 +0300
commit891813c9e1ec96971a61ede016e3b7872977549e (patch)
treefbe2e6d00651ba97594257100c0e6aa32bc2218f /engines/chewy
parentb394b1b687a037369db6f4242329cf370d4d1c85 (diff)
downloadscummvm-rg350-891813c9e1ec96971a61ede016e3b7872977549e.tar.gz
scummvm-rg350-891813c9e1ec96971a61ede016e3b7872977549e.tar.bz2
scummvm-rg350-891813c9e1ec96971a61ede016e3b7872977549e.zip
CHEWY: TCF resources contain error messages, not in-game text
Diffstat (limited to 'engines/chewy')
-rw-r--r--engines/chewy/console.cpp28
-rw-r--r--engines/chewy/console.h2
-rw-r--r--engines/chewy/resource.cpp2
-rw-r--r--engines/chewy/resource.h8
4 files changed, 20 insertions, 20 deletions
diff --git a/engines/chewy/console.cpp b/engines/chewy/console.cpp
index f982cade75..a681c8997e 100644
--- a/engines/chewy/console.cpp
+++ b/engines/chewy/console.cpp
@@ -31,15 +31,15 @@
namespace Chewy {
Console::Console(ChewyEngine *vm) : GUI::Debugger(), _vm(vm) {
- registerCmd("dump", WRAP_METHOD(Console, Cmd_Dump));
- registerCmd("dump_bg", WRAP_METHOD(Console, Cmd_DumpBg));
- registerCmd("draw", WRAP_METHOD(Console, Cmd_Draw));
- registerCmd("play_sound", WRAP_METHOD(Console, Cmd_PlaySound));
- registerCmd("play_speech", WRAP_METHOD(Console, Cmd_PlaySpeech));
- registerCmd("play_music", WRAP_METHOD(Console, Cmd_PlayMusic));
- registerCmd("play_video", WRAP_METHOD(Console, Cmd_PlayVideo));
- registerCmd("video_info", WRAP_METHOD(Console, Cmd_VideoInfo));
- registerCmd("text", WRAP_METHOD(Console, Cmd_Text));
+ registerCmd("dump", WRAP_METHOD(Console, Cmd_Dump));
+ registerCmd("dump_bg", WRAP_METHOD(Console, Cmd_DumpBg));
+ registerCmd("draw", WRAP_METHOD(Console, Cmd_Draw));
+ registerCmd("play_sound", WRAP_METHOD(Console, Cmd_PlaySound));
+ registerCmd("play_speech", WRAP_METHOD(Console, Cmd_PlaySpeech));
+ registerCmd("play_music", WRAP_METHOD(Console, Cmd_PlayMusic));
+ registerCmd("play_video", WRAP_METHOD(Console, Cmd_PlayVideo));
+ registerCmd("video_info", WRAP_METHOD(Console, Cmd_VideoInfo));
+ registerCmd("error_message", WRAP_METHOD(Console, Cmd_ErrorMessage));
}
Console::~Console() {
@@ -177,18 +177,18 @@ bool Console::Cmd_VideoInfo(int argc, const char **argv) {
return true;
}
-bool Console::Cmd_Text(int argc, const char **argv) {
+bool Console::Cmd_ErrorMessage(int argc, const char **argv) {
if (argc < 2) {
- debugPrintf("Usage: <file> <text number>\n");
+ debugPrintf("Usage: error_message <file> <message number>\n");
return true;
}
Common::String filename = argv[1];
int resNum = atoi(argv[2]);
- TextResource *res = new TextResource(filename);
- Common::String str = res->getText(resNum);
- this->debugPrintf("Text: %s\n", str.c_str());
+ ErrorMessage *res = new ErrorMessage(filename);
+ Common::String str = res->getErrorMessage(resNum);
+ this->debugPrintf("Error message: %s\n", str.c_str());
delete res;
return true;
diff --git a/engines/chewy/console.h b/engines/chewy/console.h
index ab8b8de60a..a4ffbe8ada 100644
--- a/engines/chewy/console.h
+++ b/engines/chewy/console.h
@@ -45,7 +45,7 @@ private:
bool Cmd_PlayMusic(int argc, const char **argv);
bool Cmd_PlayVideo(int argc, const char **argv);
bool Cmd_VideoInfo(int argc, const char **argv);
- bool Cmd_Text(int argc, const char **argv);
+ bool Cmd_ErrorMessage(int argc, const char **argv);
};
} // End of namespace Chewy
diff --git a/engines/chewy/resource.cpp b/engines/chewy/resource.cpp
index c5f0a19d05..a30548c746 100644
--- a/engines/chewy/resource.cpp
+++ b/engines/chewy/resource.cpp
@@ -268,7 +268,7 @@ SoundChunk *SoundResource::getSound(uint num) {
return sound;
}
-Common::String TextResource::getText(uint num) {
+Common::String ErrorMessage::getErrorMessage(uint num) {
assert(num < _chunkList.size());
Chunk *chunk = &_chunkList[num];
diff --git a/engines/chewy/resource.h b/engines/chewy/resource.h
index 6d2126c1e6..8685cc6adc 100644
--- a/engines/chewy/resource.h
+++ b/engines/chewy/resource.h
@@ -169,12 +169,12 @@ public:
SoundChunk *getSound(uint num);
};
-class TextResource : public Resource {
+class ErrorMessage : public Resource {
public:
- TextResource(Common::String filename) : Resource(filename) {}
- virtual ~TextResource() {}
+ ErrorMessage(Common::String filename) : Resource(filename) {}
+ virtual ~ErrorMessage() {}
- Common::String getText(uint num);
+ Common::String getErrorMessage(uint num);
};
class VideoResource : public Resource {