From 7bfaa0db78b79c555fc1137de4a5964beca9d16e Mon Sep 17 00:00:00 2001 From: Torbjörn Andersson Date: Sat, 8 Jul 2006 20:45:01 +0000 Subject: Cleanup svn-id: r23439 --- engines/sword2/console.cpp | 36 +++++++++++++++--------------------- 1 file changed, 15 insertions(+), 21 deletions(-) (limited to 'engines/sword2/console.cpp') diff --git a/engines/sword2/console.cpp b/engines/sword2/console.cpp index b95c50653a..02f85418ad 100644 --- a/engines/sword2/console.cpp +++ b/engines/sword2/console.cpp @@ -434,44 +434,41 @@ bool Debugger::Cmd_ResLook(int argc, const char **argv) { } // Open up the resource and take a look inside! - uint8 type = _vm->_resman->fetchType(res);; - byte name[NAME_LEN]; - - _vm->_resman->fetchName(res, name); + uint8 type = _vm->_resman->fetchType(res); switch (type) { case ANIMATION_FILE: - DebugPrintf(" %s\n", name); + DebugPrintf(" %s\n", _vm->_resman->fetchName(res)); break; case SCREEN_FILE: - DebugPrintf(" %s\n", name); + DebugPrintf(" %s\n", _vm->_resman->fetchName(res)); break; case GAME_OBJECT: - DebugPrintf(" %s\n", name); + DebugPrintf(" %s\n", _vm->_resman->fetchName(res)); break; case WALK_GRID_FILE: - DebugPrintf(" %s\n", name); + DebugPrintf(" %s\n", _vm->_resman->fetchName(res)); break; case GLOBAL_VAR_FILE: - DebugPrintf(" %s\n", name); + DebugPrintf(" %s\n", _vm->_resman->fetchName(res)); break; case PARALLAX_FILE_null: - DebugPrintf(" %s\n", name); + DebugPrintf(" %s\n", _vm->_resman->fetchName(res)); break; case RUN_LIST: - DebugPrintf(" %s\n", name); + DebugPrintf(" %s\n", _vm->_resman->fetchName(res)); break; case TEXT_FILE: - DebugPrintf(" %s\n", name); + DebugPrintf(" %s\n", _vm->_resman->fetchName(res)); break; case SCREEN_MANAGER: - DebugPrintf(" %s\n", name); + DebugPrintf(" %s\n", _vm->_resman->fetchName(res)); break; case MOUSE_FILE: - DebugPrintf(" %s\n", name); + DebugPrintf(" %s\n", _vm->_resman->fetchName(res)); break; case ICON_FILE: - DebugPrintf(" %s\n", name); + DebugPrintf(" %s\n", _vm->_resman->fetchName(res)); break; default: DebugPrintf("unrecognised fileType %d\n", type); @@ -511,9 +508,7 @@ bool Debugger::Cmd_RunList(int argc, const char **argv) { if (!res) break; - byte name[NAME_LEN]; - - DebugPrintf("%d %s\n", res, _vm->_resman->fetchName(res, name)); + DebugPrintf("%d %s\n", res, _vm->_resman->fetchName(res)); } _vm->_resman->closeResource(runList); @@ -786,12 +781,11 @@ bool Debugger::Cmd_Events(int argc, const char **argv) { for (uint32 i = 0; i < MAX_events; i++) { if (eventList[i].id) { - byte buf[NAME_LEN]; uint32 target = eventList[i].id; uint32 script = eventList[i].interact_id; - DebugPrintf("slot %2d: id = %s (%d)\n", i, _vm->_resman->fetchName(target, buf), target); - DebugPrintf(" script = %s (%d) pos %d\n", _vm->_resman->fetchName(script / 65536, buf), script / 65536, script % 65536); + DebugPrintf("slot %2d: id = %s (%d)\n", i, _vm->_resman->fetchName(target), target); + DebugPrintf(" script = %s (%d) pos %d\n", _vm->_resman->fetchName(script / 65536), script / 65536, script % 65536); } } -- cgit v1.2.3