Skip to content

Commit

Permalink
MORTEVIELLE: Silent a bunch of GCC warnings and errors
Browse files Browse the repository at this point in the history
  • Loading branch information
Strangerke committed Apr 6, 2012
1 parent 0f82bab commit e81636f
Show file tree
Hide file tree
Showing 17 changed files with 614 additions and 620 deletions.
610 changes: 306 additions & 304 deletions engines/mortevielle/actions.cpp

Large diffs are not rendered by default.

19 changes: 10 additions & 9 deletions engines/mortevielle/dialogs.cpp
Expand Up @@ -326,7 +326,8 @@ bool Ques::show() {
optionPosY = 35;
maxLength = 0;

for (int j = firstOption, prevChoice = 1; j <= lastOption; ++j, ++prevChoice) {
prevChoice = 1;
for (int j = firstOption; j <= lastOption; ++j, ++prevChoice) {
tmpStr = deline(j);
if ((int) tmpStr.size() > maxLength)
maxLength = tmpStr.size();
Expand Down Expand Up @@ -369,16 +370,16 @@ bool Ques::show() {
++currChoice;
if (coor[currChoice].enabled) {
if ((prevChoice != 0) && (prevChoice != currChoice)) {
Common::String tmpStr = choiceArray[prevChoice] + '$';
tmpStr = choiceArray[prevChoice] + '$';
afftex(tmpStr, 100, 27 + (prevChoice * 8), 100, 1, 0);
}
if (prevChoice != currChoice) {
Common::String tmpStr = choiceArray[currChoice] + '$';
tmpStr = choiceArray[currChoice] + '$';
afftex(tmpStr, 100, 27 + (currChoice * 8), 100, 1, 1);
prevChoice = currChoice;
}
} else if (prevChoice != 0) {
Common::String tmpStr = choiceArray[prevChoice] + '$';
tmpStr = choiceArray[prevChoice] + '$';
afftex(tmpStr, 100, 27 + (prevChoice * 8), 100, 1, 0);
prevChoice = 0;
}
Expand Down Expand Up @@ -438,15 +439,15 @@ void f3f8::checkForF8(int SpeechNum, bool drawAni50Fl) {
teskbd();
do {
parole(SpeechNum, 0, 0);
waitForF3F8(key);
waitForF3F8(g_key);
CHECK_QUIT;

if (_newGraphicalDevice != _currGraphicalDevice) {
_currGraphicalDevice = _newGraphicalDevice;
if (g_newGraphicalDevice != g_currGraphicalDevice) {
g_currGraphicalDevice = g_newGraphicalDevice;
hirs();
aff50(drawAni50Fl);
}
} while (key != 66); // keycode for F8
} while (g_key != 66); // keycode for F8
}

/**
Expand All @@ -462,7 +463,7 @@ void f3f8::waitForF3F8(int &key) {

void f3f8::aff50(bool drawAni50Fl) {
caff = 50;
_maff = 0;
g_maff = 0;
taffich();
dessine(ades, 63, 12);
if (drawAni50Fl)
Expand Down
2 changes: 1 addition & 1 deletion engines/mortevielle/keyboard.cpp
Expand Up @@ -42,7 +42,7 @@ int testou() {

switch (ch) {
case '\23' :
_soundOff = !_soundOff;
g_soundOff = !g_soundOff;
break;
case '\26' :
if ((c_zzz == 1) || (c_zzz == 2)) {
Expand Down
8 changes: 4 additions & 4 deletions engines/mortevielle/level15.cpp
Expand Up @@ -68,7 +68,7 @@ void outbloc(int n, pattern p, t_nhom pal) {
void writepal(int n) {
t_nhom pal;

switch (_currGraphicalDevice) {
switch (g_currGraphicalDevice) {
case MODE_TANDY:
case MODE_EGA:
case MODE_AMSTRAD1512:
Expand Down Expand Up @@ -96,7 +96,7 @@ void pictout(int seg, int dep, int x, int y) {
GfxSurface surface;
surface.decode(&mem[seg * 16 + dep]);

if (_currGraphicalDevice == MODE_HERCULES) {
if (g_currGraphicalDevice == MODE_HERCULES) {
mem[0x7000 * 16 + 2] = 0;
mem[0x7000 * 16 + 32] = 15;
}
Expand All @@ -109,13 +109,13 @@ void pictout(int seg, int dep, int x, int y) {

void sauvecr(int y, int dy) {
hideMouse();
s_sauv(_currGraphicalDevice, y, dy);
s_sauv(g_currGraphicalDevice, y, dy);
showMouse();
}

void charecr(int y, int dy) {
hideMouse();
s_char(_currGraphicalDevice, y, dy);
s_char(g_currGraphicalDevice, y, dy);
showMouse();
}

Expand Down
10 changes: 5 additions & 5 deletions engines/mortevielle/menu.cpp
Expand Up @@ -154,7 +154,7 @@ void Menu::displayMenu() {

g_vm->_screenSurface.fillRect(7, Common::Rect(0, 0, 639, 10));
col = 28 * res;
if (_currGraphicalDevice == MODE_CGA)
if (g_currGraphicalDevice == MODE_CGA)
color = 1;
else
color = 9;
Expand Down Expand Up @@ -456,8 +456,8 @@ void Menu::mdn() {
// A menu was clicked on
choisi = (test0) && (msg4 != OPCODE_NONE);
menuUp(msg3);
msg[4] = msg4;
msg[3] = msg3;
g_msg[4] = msg4;
g_msg[3] = msg3;
msg3 = OPCODE_NONE;
msg4 = OPCODE_NONE;

Expand Down Expand Up @@ -513,8 +513,8 @@ void Menu::initMenu() {
}
msg3 = OPCODE_NONE;
msg4 = OPCODE_NONE;
msg[3] = OPCODE_NONE;
msg[4] = OPCODE_NONE;
g_msg[3] = OPCODE_NONE;
g_msg[4] = OPCODE_NONE;
g_vm->setMouseClick(false);
}

Expand Down

0 comments on commit e81636f

Please sign in to comment.