aboutsummaryrefslogtreecommitdiff
path: root/engines/titanic
diff options
context:
space:
mode:
authorPaul Gilbert2016-07-31 18:08:57 -0400
committerPaul Gilbert2016-07-31 18:08:57 -0400
commit7ace328cb86a83db670ba0401176ad108a9c107c (patch)
tree1126a29837ae4458d585b0923549d9e9af29a648 /engines/titanic
parenta0f051a374162ef0e1770c25b4621c6b4d4da9ee (diff)
downloadscummvm-rg350-7ace328cb86a83db670ba0401176ad108a9c107c.tar.gz
scummvm-rg350-7ace328cb86a83db670ba0401176ad108a9c107c.tar.bz2
scummvm-rg350-7ace328cb86a83db670ba0401176ad108a9c107c.zip
TITANIC: Fix various warnings
Diffstat (limited to 'engines/titanic')
-rw-r--r--engines/titanic/pet_control/pet_load.h2
-rw-r--r--engines/titanic/pet_control/pet_load_save.cpp2
-rw-r--r--engines/titanic/pet_control/pet_load_save.h2
-rw-r--r--engines/titanic/pet_control/pet_save.cpp2
-rw-r--r--engines/titanic/pet_control/pet_save.h2
-rw-r--r--engines/titanic/star_control/star_control.cpp2
-rw-r--r--engines/titanic/star_control/star_field.cpp18
-rw-r--r--engines/titanic/star_control/star_field.h2
-rw-r--r--engines/titanic/true_talk/barbot_script.cpp18
9 files changed, 24 insertions, 26 deletions
diff --git a/engines/titanic/pet_control/pet_load.h b/engines/titanic/pet_control/pet_load.h
index ad0b026818..421531974d 100644
--- a/engines/titanic/pet_control/pet_load.h
+++ b/engines/titanic/pet_control/pet_load.h
@@ -42,7 +42,7 @@ public:
/**
* Highlight any currently highlighted element
*/
- virtual void highlightCurrent() { resetSlots(); }
+ virtual void highlightCurrent(const Point &pt) { resetSlots(); }
/**
* Returns the tooltip text for when the glyph is selected
diff --git a/engines/titanic/pet_control/pet_load_save.cpp b/engines/titanic/pet_control/pet_load_save.cpp
index 77b6126249..aebe43551e 100644
--- a/engines/titanic/pet_control/pet_load_save.cpp
+++ b/engines/titanic/pet_control/pet_load_save.cpp
@@ -81,7 +81,7 @@ bool CPetLoadSave::MouseButtonDownMsg(const Point &pt) {
return false;
}
-bool CPetLoadSave::KeyCharMsg(Common::KeyCode key) {
+bool CPetLoadSave::KeyCharMsg(int key) {
switch (key) {
case Common::KEYCODE_TAB:
case Common::KEYCODE_DOWN:
diff --git a/engines/titanic/pet_control/pet_load_save.h b/engines/titanic/pet_control/pet_load_save.h
index 687bd13e58..dd1c907ef1 100644
--- a/engines/titanic/pet_control/pet_load_save.h
+++ b/engines/titanic/pet_control/pet_load_save.h
@@ -91,7 +91,7 @@ public:
/**
* Handles keypresses when the glyph is focused
*/
- virtual bool KeyCharMsg(Common::KeyCode key);
+ virtual bool KeyCharMsg(int key);
/**
* Resets highlighting on the save slots
diff --git a/engines/titanic/pet_control/pet_save.cpp b/engines/titanic/pet_control/pet_save.cpp
index 341053948e..b5e16736bc 100644
--- a/engines/titanic/pet_control/pet_save.cpp
+++ b/engines/titanic/pet_control/pet_save.cpp
@@ -48,7 +48,7 @@ bool CPetSave::MouseButtonUpMsg(const Point &pt) {
}
}
-void CPetSave::highlightCurrent() {
+void CPetSave::highlightCurrent(const Point &pt) {
resetSlots();
highlightSave(_savegameSlotNum);
}
diff --git a/engines/titanic/pet_control/pet_save.h b/engines/titanic/pet_control/pet_save.h
index d37f4e3012..54e91e4c76 100644
--- a/engines/titanic/pet_control/pet_save.h
+++ b/engines/titanic/pet_control/pet_save.h
@@ -47,7 +47,7 @@ public:
/**
* Highlight any currently highlighted element
*/
- virtual void highlightCurrent();
+ virtual void highlightCurrent(const Point &pt);
/**
* Returns the tooltip text for when the glyph is selected
diff --git a/engines/titanic/star_control/star_control.cpp b/engines/titanic/star_control/star_control.cpp
index 18876adadc..7ba160cd37 100644
--- a/engines/titanic/star_control/star_control.cpp
+++ b/engines/titanic/star_control/star_control.cpp
@@ -60,7 +60,7 @@ void CStarControl::load(SimpleFile *file) {
int val = file->readNumber();
if (!val) {
- _starField.load(file, 0);
+ _starField.load(file);
if (!_starField.initDocument())
error("Couldn't initialise the StarField document");
diff --git a/engines/titanic/star_control/star_field.cpp b/engines/titanic/star_control/star_field.cpp
index 882e3c3600..c50e8466ec 100644
--- a/engines/titanic/star_control/star_field.cpp
+++ b/engines/titanic/star_control/star_field.cpp
@@ -29,16 +29,14 @@ CStarField::CStarField() : _val1(0), _val2(0), _val3(0), _val4(true),
_val5(0), _val6(false) {
}
-void CStarField::load(SimpleFile *file, int param) {
- if (!param) {
- _sub7.load(file);
- _sub8.load(file);
- _val1 = file->readNumber();
- _val2 = file->readNumber();
- _val3 = file->readNumber();
- _val4 = file->readNumber();
- _val6 = file->readNumber();
- }
+void CStarField::load(SimpleFile *file) {
+ _sub7.load(file);
+ _sub8.load(file);
+ _val1 = file->readNumber();
+ _val2 = file->readNumber();
+ _val3 = file->readNumber();
+ _val4 = file->readNumber();
+ _val6 = file->readNumber();
}
void CStarField::save(SimpleFile *file, int indent) {
diff --git a/engines/titanic/star_control/star_field.h b/engines/titanic/star_control/star_field.h
index 18104cdedf..ef1ee29737 100644
--- a/engines/titanic/star_control/star_field.h
+++ b/engines/titanic/star_control/star_field.h
@@ -51,7 +51,7 @@ public:
/**
* Load the data for the class from file
*/
- void load(SimpleFile *file, int param);
+ void load(SimpleFile *file);
/**
* Save the data for the class to file
diff --git a/engines/titanic/true_talk/barbot_script.cpp b/engines/titanic/true_talk/barbot_script.cpp
index ccc583347c..b327c3647e 100644
--- a/engines/titanic/true_talk/barbot_script.cpp
+++ b/engines/titanic/true_talk/barbot_script.cpp
@@ -650,7 +650,7 @@ done:
val += 4;
if (val < 9) {
val = val / 2;
- dval = 250081 + flag ? 0 : 267;
+ dval = 250081 + (flag ? 0 : 267);
}
CTrueTalkManager::setFlags(29, val);
break;
@@ -661,7 +661,7 @@ done:
val += 4;
if (val < 9) {
val = val / 2;
- dval = 250081 + flag ? 0 : 243;
+ dval = 250081 + (flag ? 0 : 243);
}
CTrueTalkManager::setFlags(30, val);
break;
@@ -672,7 +672,7 @@ done:
val += 4;
if (val < 9) {
val = val / 2;
- dval = 250081 + flag ? 0 : 256;
+ dval = 250081 + (flag ? 0 : 256);
}
CTrueTalkManager::setFlags(31, val);
break;
@@ -683,7 +683,7 @@ done:
val += 4;
if (val < 9) {
val = val / 2;
- dval = 250081 + flag ? 0 : 251;
+ dval = 250081 + (flag ? 0 : 251);
}
CTrueTalkManager::setFlags(32, val);
break;
@@ -694,7 +694,7 @@ done:
val += 4;
if (val < 9) {
val = val / 2;
- dval = 250081 + flag ? 0 : 273;
+ dval = 250081 + (flag ? 0 : 273);
}
CTrueTalkManager::setFlags(33, val);
break;
@@ -705,7 +705,7 @@ done:
val += 4;
if (val < 9) {
val = val / 2;
- dval = 250081 + flag ? 0 : 236;
+ dval = 250081 + (flag ? 0 : 236);
}
CTrueTalkManager::setFlags(34, val);
break;
@@ -969,7 +969,7 @@ int BarbotScript::updateState(uint oldId, uint newId, int index) {
return 250538;
}
if (newId == 251704) {
- return 251701 + _field7C ? 3 : 0;
+ return 251701 + (_field7C ? 3 : 0);
}
for (uint idx = 0; idx < _states.size(); ++idx) {
@@ -1078,14 +1078,14 @@ int BarbotScript::doSentenceEntry(int val1, const int *srcIdP, const TTroomScrip
if (bit2) {
if (!bit0) {
- id = 250085 - bit3 ? 0 : 199715;
+ id = 250085 - (bit3 ? 0 : 199715);
break;
} else if (!bit3) {
id = 250627;
}
} else {
if (!bit0) {
- id = 50365 + bit3 ? 0 : 2;
+ id = 50365 + (bit3 ? 0 : 2);
} else if (!bit3) {
id = 50370;
}