[Scummvm-cvs-logs] CVS: scummvm/queen talk.cpp,1.13,1.14
Jamieson Christian
jamieson630 at users.sourceforge.net
Fri Oct 17 09:48:04 CEST 2003
Update of /cvsroot/scummvm/scummvm/queen
In directory sc8-pr-cvs1:/tmp/cvs-serv12090/scummvm/queen
Modified Files:
talk.cpp
Log Message:
Fix MSVC6 warnings
Index: talk.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/talk.cpp,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -d -r1.13 -r1.14
--- talk.cpp 17 Oct 2003 11:47:41 -0000 1.13
+++ talk.cpp 17 Oct 2003 16:42:49 -0000 1.14
@@ -74,6 +74,7 @@
void Talk::talk(const char *filename, int personInRoom, char *cutawayFilename) {
+ int i;
_oldSelectedSentenceIndex = 0;
_oldSelectedSentenceValue = 0;
@@ -117,7 +118,7 @@
bool personWalking = false; // OWALK in talk.c
// Lines 828-846 in talk.c
- for (int i = 1; i <= 4; i++) {
+ for (i = 1; i <= 4; i++) {
if (talkSelected()->values[i-1] > 0) {
// This option has been redefined so display new dialogue option
_dialogueTree[1][i].head = talkSelected()->values[i-1];
@@ -166,7 +167,7 @@
// Joe dialogue
- for (int i = 1; i <= 4; i++) {
+ for (i = 1; i <= 4; i++) {
findDialogueString(_joePtr, _dialogueTree[level][i].head, _talkString[i]);
int16 index = _dialogueTree[level][i].gameStateIndex;
@@ -184,7 +185,7 @@
int choicesLeft = 0;
int selectedSentence = 0;
- for (int i = 1; i <= 4; i++) {
+ for (i = 1; i <= 4; i++) {
if (_talkString[i][0] != '\0') {
choicesLeft++;
selectedSentence = i;
@@ -224,7 +225,7 @@
// Set LEVEL to the selected child in dialogue tree
- for (int i = 1; i <= _levelMax; i++)
+ for (i = 1; i <= _levelMax; i++)
if (_dialogueTree[i][0].head == head)
level = i;
@@ -232,7 +233,7 @@
// No new level has been selected, so lets set LEVEL to the
// tree path pointed to by the RETVAL
- for (int i = 1; i <= _levelMax; i++)
+ for (i = 1; i <= _levelMax; i++)
for (int j = 0; j <= 5; j++)
if (_dialogueTree[i][j].head == retval)
level = i;
@@ -619,9 +620,11 @@
Person *person,
int command,
const char *voiceFilePrefix,
- int index) {
+ int index)
+{
// Function SPEAK_SUB, lines 1406-1870 in talk.a
+ int i;
char segment[MAX_STRING_SIZE];
memcpy(segment, segmentStart, length);
segment[length] = '\0';
@@ -638,7 +641,7 @@
switch (command) {
case SPEAK_PAUSE:
- for (int i = 0; i < 10; i++) {
+ for (i = 0; i < 10; i++) {
if (_quit)
break;
_graphics->update();
@@ -824,7 +827,7 @@
int spaces = countSpaces(segment);
- for (int i = 0; i < (spaces + 1) /* || sfxflag == 0*/; i++) {
+ for (i = 0; i < (spaces + 1) /* || sfxflag == 0*/; i++) {
// XXX #ifdef __DOS__
// XXX if(sfxflag==0 && sfxbusy())
// XXX break;
@@ -1130,7 +1133,7 @@
}
if (oldZone > 0) {
- // XXX for (i = zones[1][oldZone].y1; i < zones[1][oldZone].y2; i += 10)
+ // XXX for (int i = zones[1][oldZone].y1; i < zones[1][oldZone].y2; i += 10)
// XXX texts[i + 150].col = INK_TALK_NORMAL;
}
@@ -1229,7 +1232,7 @@
int max_line_width = 0;
- for (int i = 0; i < line_count; i++) {
+ for (i = 0; i < line_count; i++) {
int width = _graphics->textWidth(lines[i]);
if (max_line_width < width)
max_line_width = width;
@@ -1281,7 +1284,7 @@
_graphics->textCurrentColor(color);
- for (int i = 0; i < line_count; i++) {
+ for (i = 0; i < line_count; i++) {
int lineX = x + (max_line_width - _graphics->textWidth(lines[i])) / 2;
//debug(0, "Setting text '%s' at (%i, %i)", lines[i], lineX, y + 9 * i);
More information about the Scummvm-git-logs
mailing list