diff options
author | Paul Gilbert | 2019-07-06 17:02:26 -0700 |
---|---|---|
committer | Paul Gilbert | 2019-07-06 17:02:26 -0700 |
commit | 3b9547edde674d3517a60ec8189a063bfb6a4d13 (patch) | |
tree | f4f6049f42c6e96d653bc8aa8ee9a816b98ab1f4 /engines/glk/magnetic | |
parent | f282fbb49bf941c5b8ac1a2dd0b26a4a63978060 (diff) | |
download | scummvm-rg350-3b9547edde674d3517a60ec8189a063bfb6a4d13.tar.gz scummvm-rg350-3b9547edde674d3517a60ec8189a063bfb6a4d13.tar.bz2 scummvm-rg350-3b9547edde674d3517a60ec8189a063bfb6a4d13.zip |
GLK: Fix various gcc warnings
Diffstat (limited to 'engines/glk/magnetic')
-rw-r--r-- | engines/glk/magnetic/emu.cpp | 4 | ||||
-rw-r--r-- | engines/glk/magnetic/graphics.cpp | 10 | ||||
-rw-r--r-- | engines/glk/magnetic/magnetic.cpp | 6 |
3 files changed, 11 insertions, 9 deletions
diff --git a/engines/glk/magnetic/emu.cpp b/engines/glk/magnetic/emu.cpp index 76d0fa754e..1d63f5944a 100644 --- a/engines/glk/magnetic/emu.cpp +++ b/engines/glk/magnetic/emu.cpp @@ -25,8 +25,8 @@ namespace Glk { namespace Magnetic { -static const char *no_hints = "[Hints are not available.]\n"; -static const char *not_supported = "[This function is not supported.]\n"; +//static const char *no_hints = "[Hints are not available.]\n"; +//static const char *not_supported = "[This function is not supported.]\n"; int Magnetic::ms_init(bool restarting) { byte header[42]; diff --git a/engines/glk/magnetic/graphics.cpp b/engines/glk/magnetic/graphics.cpp index 1c635782c2..5ba20531d3 100644 --- a/engines/glk/magnetic/graphics.cpp +++ b/engines/glk/magnetic/graphics.cpp @@ -86,7 +86,8 @@ bool Magnetic::is_blank(uint16 line, uint16 width) const { byte *Magnetic::ms_extract1(byte pic, uint16 * w, uint16 * h, uint16 * pal) { byte *table, *data, bit, val, *buffer; uint16 tablesize, count; - uint32 i, j, datasize, upsize, offset; + uint32 i, j, upsize, offset; + //uint32 datasize; offset = READ_LE_UINT32(gfx_data + 4 * pic); buffer = gfx_data + offset - 8; @@ -97,7 +98,7 @@ byte *Magnetic::ms_extract1(byte pic, uint16 * w, uint16 * h, uint16 * pal) { h[0] = READ_LE_UINT16(buffer + 6); tablesize = READ_LE_UINT16(buffer + 0x3c); - datasize = READ_LE_UINT32(buffer + 0x3e); + //datasize = READ_LE_UINT32(buffer + 0x3e); table = buffer + 0x42; data = table + tablesize * 2 + 2; upsize = h[0] * w[0]; @@ -193,8 +194,9 @@ byte *Magnetic::ms_extract2(const char *name, uint16 *w, uint16 *h, uint16 *pal, anim_data = gfx2_buf + 48 + main_pic.data_size; if ((anim_data[0] != 0xD0) || (anim_data[1] != 0x5E)) { byte *current; - uint16 frame_count, command_count; + uint16 frame_count; uint16 value1, value2; + //uint16 command_count; if (is_anim != 0) *is_anim = 1; @@ -261,7 +263,7 @@ byte *Magnetic::ms_extract2(const char *name, uint16 *w, uint16 *h, uint16 *pal, } // Get the command sequence table - command_count = READ_LE_UINT16(current); + //command_count = READ_LE_UINT16(current); command_table = current + 2; for (i = 0; i < MAX_POSITIONS; i++) diff --git a/engines/glk/magnetic/magnetic.cpp b/engines/glk/magnetic/magnetic.cpp index 7bd3fd686d..3f9917bf7b 100644 --- a/engines/glk/magnetic/magnetic.cpp +++ b/engines/glk/magnetic/magnetic.cpp @@ -80,12 +80,12 @@ bool Magnetic::is_gamefile_valid() { } // We support version 2.0 through 3.1.* - version = _gameFile.readUint32BE(); - if (version < 0x20000) { + uint32 vers = _gameFile.readUint32BE(); + if (vers < 0x20000) { GUIErrorMessage(_("This Glulx file is too old a version to execute.")); return false; } - if (version >= 0x30200) { + if (vers >= 0x30200) { GUIErrorMessage(_("This Glulx file is too new a version to execute.")); return false; } |