aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVladimir Menshakov2010-03-24 19:48:32 +0000
committerVladimir Menshakov2010-03-24 19:48:32 +0000
commitf3ed66045ff11f3a1dfd74ed91e324279886358e (patch)
treee331f2085936e9a1a637367e87d0d0b4cd7acf97
parente9d80d104d75e8651a2334471df65efacdc92855 (diff)
downloadscummvm-rg350-f3ed66045ff11f3a1dfd74ed91e324279886358e.tar.gz
scummvm-rg350-f3ed66045ff11f3a1dfd74ed91e324279886358e.tar.bz2
scummvm-rg350-f3ed66045ff11f3a1dfd74ed91e324279886358e.zip
fixed warning
svn-id: r48384
-rw-r--r--engines/teenagent/scene.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/engines/teenagent/scene.cpp b/engines/teenagent/scene.cpp
index 237db19558..60b3e7a5d4 100644
--- a/engines/teenagent/scene.cpp
+++ b/engines/teenagent/scene.cpp
@@ -1188,7 +1188,7 @@ Object *Scene::getObject(int id, int scene_id) {
return &scene_objects[id];
}
-Common::Point Scene::messagePosition(const Common::String &str, Common::Point position) {
+Common::Point Scene::messagePosition(const Common::String &str, Common::Point message_position) {
Resources *res = Resources::instance();
int lines = 1;
for(uint i = 0; i < str.size(); ++i)
@@ -1198,19 +1198,19 @@ Common::Point Scene::messagePosition(const Common::String &str, Common::Point po
uint w = res->font7.render(NULL, 0, 0, str, 0);
uint h = res->font7.height * lines + 3;
- position.x -= w / 2;
- position.y -= h;
+ message_position.x -= w / 2;
+ message_position.y -= h;
- if (position.x + w > 320)
- position.x = 320 - w;
- if (position.x < 0)
- position.x = 0;
- if (position.y + h > 320)
- position.y = 200 - h;
- if (position.y < 0)
- position.y = 0;
+ if (message_position.x + w > 320)
+ message_position.x = 320 - w;
+ if (message_position.x < 0)
+ message_position.x = 0;
+ if (message_position.y + h > 320)
+ message_position.y = 200 - h;
+ if (message_position.y < 0)
+ message_position.y = 0;
- return position;
+ return message_position;
}
uint Scene::messageDuration(const Common::String &str) {