diff options
author | Paul Gilbert | 2012-12-05 20:41:58 +1100 |
---|---|---|
committer | Paul Gilbert | 2012-12-05 20:41:58 +1100 |
commit | e0711bb832b8224d261e21030eeceaafd91fbf6c (patch) | |
tree | 56635005ad36a2583672888355c796e5b388d912 | |
parent | 8aebc05322dfd5539a5f754d9440b6d653840769 (diff) | |
download | scummvm-rg350-e0711bb832b8224d261e21030eeceaafd91fbf6c.tar.gz scummvm-rg350-e0711bb832b8224d261e21030eeceaafd91fbf6c.tar.bz2 scummvm-rg350-e0711bb832b8224d261e21030eeceaafd91fbf6c.zip |
HOPKINS: Fix some compiler warnings under gcc
-rw-r--r-- | engines/hopkins/events.cpp | 18 | ||||
-rw-r--r-- | engines/hopkins/lines.cpp | 2 | ||||
-rw-r--r-- | engines/hopkins/script.cpp | 2 |
3 files changed, 11 insertions, 11 deletions
diff --git a/engines/hopkins/events.cpp b/engines/hopkins/events.cpp index 2271bff7b4..be261342d1 100644 --- a/engines/hopkins/events.cpp +++ b/engines/hopkins/events.cpp @@ -203,11 +203,11 @@ void EventsManager::pollEvents() { return; case Common::EVENT_KEYDOWN: - keyState[toupper(event.kbd.ascii)] = true; + keyState[(byte)toupper(event.kbd.ascii)] = true; handleKey(event); return; case Common::EVENT_KEYUP: - keyState[toupper(event.kbd.ascii)] = false; + keyState[(byte)toupper(event.kbd.ascii)] = false; return; case Common::EVENT_LBUTTONDOWN: souris_b = 1; @@ -225,10 +225,10 @@ void EventsManager::pollEvents() { } for (char chr = 'A'; chr <= 'Z'; chr++) - keyState[chr] = false; + keyState[(byte)chr] = false; for (char chr = '0'; chr <= '9'; chr++) - keyState[chr] = false; + keyState[(byte)chr] = false; } void EventsManager::handleKey(Common::Event &event) { @@ -260,20 +260,20 @@ int EventsManager::keywin() { return -1; for (char ch = 'A'; ch <= 'Z'; ++ch) { - if (keyState[ch]) { + if (keyState[(byte)ch]) { foundChar = ch; break; } } for (char ch = '0'; ch <= '9'; ++ch) { - if (keyState[ch]) { + if (keyState[(byte)ch]) { foundChar = ch; break; } } - if (keyState['.']) + if (keyState[(byte)'.']) foundChar = '.'; else if (keyState[8]) // BACKSPACE @@ -281,14 +281,14 @@ int EventsManager::keywin() { else if (keyState[13]) // ENTER foundChar = 13; - else if (keyState[' ']) + else if (keyState[(byte)' ']) foundChar = ' '; VBL(); } // Wait for keypress release - while (keyState[foundChar] && !_vm->shouldQuit()) { + while (keyState[(byte)foundChar] && !_vm->shouldQuit()) { VBL(); g_system->delayMillis(10); } diff --git a/engines/hopkins/lines.cpp b/engines/hopkins/lines.cpp index 2aaa6adc63..4a3eabe878 100644 --- a/engines/hopkins/lines.cpp +++ b/engines/hopkins/lines.cpp @@ -626,7 +626,7 @@ int LinesManager::CONTOURNE(int a1, int a2, int a3, int a4, int a5, int16 *a6, i for (int i = a2; Ligne[a1].field0 > i; ++i) { int16 *v10 = Ligne[a1].lineData; int v11 = v10[2 * i]; - int v50 = v10[2 * i + 1]; + v50 = v10[2 * i + 1]; int v12 = v8; a6[v12] = v11; diff --git a/engines/hopkins/script.cpp b/engines/hopkins/script.cpp index 0898556e41..a96b8d197e 100644 --- a/engines/hopkins/script.cpp +++ b/engines/hopkins/script.cpp @@ -172,7 +172,7 @@ LABEL_104: if (*(a1 + 2) == 'B' && *(a1 + 3) == 'O' && *(a1 + 4) == 'B') { if (_vm->_objectsManager.DESACTIVE != true) { int v72 = *(a1 + 5); - int v70 = *(a1 + 6); + v70 = *(a1 + 6); int v4 = *(a1 + 7); int v68 = (int16)READ_LE_UINT16(a1 + 8); int v66 = (int16)READ_LE_UINT16(a1 + 10); |