diff options
Diffstat (limited to 'engines')
-rw-r--r-- | engines/agi/agi.h | 4 | ||||
-rw-r--r-- | engines/agi/preagi_mickey.cpp | 6 |
2 files changed, 6 insertions, 4 deletions
diff --git a/engines/agi/agi.h b/engines/agi/agi.h index 4df8824b0e..e991345040 100644 --- a/engines/agi/agi.h +++ b/engines/agi/agi.h @@ -556,8 +556,8 @@ struct AgiGame { int lineUserInput; /**< line to put user input on */ int lineMinPrint; /**< num lines to print on */ int cursorPos; /**< column where the input cursor is */ - uint8 inputBuffer[40]; /**< buffer for user input */ - uint8 echoBuffer[40]; /**< buffer for echo.line */ + byte inputBuffer[40]; /**< buffer for user input */ + byte echoBuffer[40]; /**< buffer for echo.line */ int keypress; InputMode inputMode; /**< keyboard input mode */ diff --git a/engines/agi/preagi_mickey.cpp b/engines/agi/preagi_mickey.cpp index ec8a1f4878..ea041a93c7 100644 --- a/engines/agi/preagi_mickey.cpp +++ b/engines/agi/preagi_mickey.cpp @@ -302,6 +302,8 @@ void Mickey::getMouseMenuSelRow(MSA_MENU menu, int *sel0, int *sel1, int iRow, i if (y != IDI_MSA_ROW_MENU_1) return; sel = sel1; break; + default: + return; } for (iWord = 0; iWord < menu.row[iRow].count; iWord++) { @@ -1234,7 +1236,7 @@ int Mickey::getPlanet() { if (!_game.nButtons) return -1; - for (int iPlanet = 0; iPlanet < IDI_MSA_MAX_DAT; iPlanet++) { + for (int iPlanet = 0; iPlanet < IDI_MSA_MAX_DAT - 1; iPlanet++) { if (!strcmp(IDS_MSA_ADDR_PLANET[iPlanet], _game.szAddr)) { return iPlanet; } @@ -1313,7 +1315,7 @@ void Mickey::flipSwitch() { _game.iPlanetXtal[0] = IDI_MSA_PLANET_EARTH; _game.iPlanetXtal[8] = IDI_MSA_PLANET_URANUS; - for (int i = 1; i < 9; i++) { + for (int i = 1; i < IDI_MSA_MAX_PLANET; i++) { if (i < 8) { do { // Earth (planet 0) and Uranus (planet 8) are excluded |