[Scummvm-cvs-logs] CVS: scummvm/sword1 logic.cpp,1.50,1.51 router.cpp,1.12,1.13 text.cpp,1.11,1.12

Max Horn fingolfin at users.sourceforge.net
Sun May 8 14:52:09 CEST 2005


Update of /cvsroot/scummvm/scummvm/sword1
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28088/sword1

Modified Files:
	logic.cpp router.cpp text.cpp 
Log Message:
Comply to our coding conventions

Index: logic.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/sword1/logic.cpp,v
retrieving revision 1.50
retrieving revision 1.51
diff -u -d -r1.50 -r1.51
--- logic.cpp	7 Apr 2005 08:50:48 -0000	1.50
+++ logic.cpp	8 May 2005 21:49:52 -0000	1.51
@@ -245,7 +245,7 @@
 			error("Fatal error: compact %d's logic == %X!", id, compact->o_logic);
 			break;
 		}
-	} while(logicRet);
+	} while (logicRet);
 }
 
 int Logic::logicWaitTalk(Object *compact) {

Index: router.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/sword1/router.cpp,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -d -r1.12 -r1.13
--- router.cpp	1 Jan 2005 16:09:25 -0000	1.12
+++ router.cpp	8 May 2005 21:49:52 -0000	1.13
@@ -190,7 +190,7 @@
 			solidFlag = SolidWalkAnimator(megaObject->o_route);
 		}
 
-		if(!solidFlag)
+		if (!solidFlag)
 		{
 			SlidyPath();
 			SlidyWalkAnimator(megaObject->o_route);
@@ -247,7 +247,7 @@
 			changed = Scan(level);
 			level =level + 1;
 		}
-		while(changed == 1);
+		while (changed == 1);
 
 		// Check to see if the route reached the target
 		if (node[nnodes].dist < 9999)
@@ -869,7 +869,7 @@
 				step += 1;
 				module += 1;
 			}
-			while( module < moduleEnd) ;
+			while ( module < moduleEnd) ;
 			stepX = modX[modularPath[p].dir];
 			stepY = modY[modularPath[p].dir];
 			errorX = modularPath[p].x -	moduleX;
@@ -923,7 +923,7 @@
 						frameCount += 1;
 						walkAnim[lastCount + frameCount - 1].x +=	errorX*frameCount/frames;
 					}
-					while(frameCount<frames);	
+					while (frameCount<frames);	
 				}
 				if (errorY != 0)
 				{
@@ -934,7 +934,7 @@
 						frameCount += 1;
 						walkAnim[lastCount + frameCount-1].y +=	errorY*frameCount/frames;
 					}
-					while(frameCount<frames);	
+					while (frameCount<frames);	
 				}
 				// Now is the time to put in the turn frames for the last turn
 				if (frames < framesPerStep)
@@ -954,7 +954,7 @@
 							walkAnim[frame].frame += 104;//turning left 
 							frame += 1;
 						}
-						while(frame < lastCount );
+						while (frame < lastCount );
 					}
 					if (((lastDir == 1) || (lastDir == -7)) || ((lastDir == 2) || (lastDir == -6)))
 					{	
@@ -965,7 +965,7 @@
 							walkAnim[frame].frame += 200; //was 60 now 116
 							frame += 1;
 						}
-						while(frame < lastCount );
+						while (frame < lastCount );
 					}
 					lastDir = currentDir;
 				}
@@ -1359,7 +1359,7 @@
 
 	do
 	{
-		while(modularPath[p].num > 0)
+		while (modularPath[p].num > 0)
 		{
 			currentDir = modularPath[p].dir;
 			if (currentDir< NO_DIRECTIONS)
@@ -1388,7 +1388,7 @@
 					module += 1;
 					step += 1;
 				}
-				while( module < moduleEnd) ;
+				while ( module < moduleEnd) ;
 				errorX = modularPath[p].x -	moduleX;
 				errorX = errorX * modX[modularPath[p].dir];
 				errorY = modularPath[p].y -	moduleY;
@@ -1432,7 +1432,7 @@
 								walkAnim[frame].frame += 104;//turning left 
 								frame += 1;
 							}
-							while(frame < lastCount );
+							while (frame < lastCount );
 						}
 						if (((lastDir == 1) || (lastDir == -7)) || ((lastDir == 2) || (lastDir == -6)))
 						{	
@@ -1443,7 +1443,7 @@
 								walkAnim[frame].frame += 200; //was 60 now 116
 								frame += 1;
 							}
-							while(frame < lastCount );
+							while (frame < lastCount );
 						}
 					}
 					// all turns checked
@@ -1474,7 +1474,7 @@
 				walkAnim[frame].frame += 278;//stopping right 
 				frame += 1;
 			}
-			while(frame < lastCount );
+			while (frame < lastCount );
 			walkAnim[stepCount].frame = 308;
 			walkAnim[stepCount].step = 7;
 			walkAnim[stepCount].dir = currentDir;
@@ -1489,7 +1489,7 @@
 				walkAnim[frame].frame += 279;//stopping right
 				frame += 1;
 			}
-			while(frame < lastCount );
+			while (frame < lastCount );
 			walkAnim[stepCount].frame = 315;
 			walkAnim[stepCount].step = 7;
 			walkAnim[stepCount].dir = currentDir;
@@ -1510,7 +1510,7 @@
 				walkAnim[frame].frame += 244;//stopping left 
 				frame += 1;
 			}
-			while(frame < lastCount );
+			while (frame < lastCount );
 			walkAnim[stepCount].frame = 322;
 			walkAnim[stepCount].step = 7;
 			walkAnim[stepCount].dir = currentDir;
@@ -1525,7 +1525,7 @@
 				walkAnim[frame].frame += 245;//stopping left 
 				frame += 1;
 			}
-			while(frame < lastCount );
+			while (frame < lastCount );
 			walkAnim[stepCount].frame = 329;
 			walkAnim[stepCount].step = 7;
 			walkAnim[stepCount].dir = currentDir;
@@ -1565,7 +1565,7 @@
 #endif   
 		i += 1;
 	}
-	while(i<p-1);
+	while (i<p-1);
 	if (p != 0)
 	{
 		targetDir =	modularPath[p-1].dir;
@@ -1646,11 +1646,11 @@
 				}
 				k-=1;
 			}
-			while(k > 0);	
+			while (k > 0);	
 		}
 		i=i+1;
 	}
-	while(i < nnodes);	
+	while (i < nnodes);	
 	return changed;
 }
 
@@ -2046,7 +2046,7 @@
 		}
 		i = i + 1;
 	}
-	while((i < nbars) && linesCrossed);
+	while ((i < nbars) && linesCrossed);
 
 	return linesCrossed;
 }
@@ -2100,7 +2100,7 @@
 		}
 		i = i + 1;
 	}
-	while((i < nbars) && linesCrossed);
+	while ((i < nbars) && linesCrossed);
 
 	return linesCrossed;
 }
@@ -2153,7 +2153,7 @@
 		}
 		i = i + 1;
 	}
-	while((i < nbars) && linesCrossed);
+	while ((i < nbars) && linesCrossed);
 
 	return linesCrossed;
 }
@@ -2229,7 +2229,7 @@
 		}
 		i = i + 1;
 	}
-	while((i < nbars) && (onLine == 0));
+	while ((i < nbars) && (onLine == 0));
 
 	return onLine;
 }
@@ -2313,7 +2313,7 @@
 		fPolygrid += 2*sizeof(int16);
 		j ++;
 	}
-	while(j < nnodes);//array starts at 0*/
+	while (j < nnodes);//array starts at 0*/
 	for (cnt = 1; cnt < nnodes; cnt++) {
 		node[cnt].x = READ_LE_UINT16(fPolygrid); fPolygrid += 2;
 		node[cnt].y = READ_LE_UINT16(fPolygrid); fPolygrid += 2;
@@ -2338,7 +2338,7 @@
 
 		// copy any extra nodes from extraNode array
 		j = 0;
-		while(j < _numExtraNodes)//array starts at 0
+		while (j < _numExtraNodes)//array starts at 0
 		{
 			node[nnodes+j].x = _extraNodes[j].x ;
 			node[nnodes+j].y = _extraNodes[j].y ;

Index: text.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/sword1/text.cpp,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -d -r1.11 -r1.12
--- text.cpp	1 Jan 2005 16:09:25 -0000	1.11
+++ text.cpp	8 May 2005 21:49:52 -0000	1.12
@@ -64,7 +64,7 @@
 	uint32 textObjId = (TEXT_sect * ITM_PER_SEC) - 1;
 	do {
 		textObjId++;
-	} while(_objMan->fetchObject(textObjId)->o_status);
+	} while (_objMan->fetchObject(textObjId)->o_status);
 	// okay, found a free text object
 
 	_objMan->fetchObject(textObjId)->o_status = STAT_FORE;
@@ -128,7 +128,7 @@
 			text++;
 
 		wordWidth += OVERLAP; // no overlap on final letter of word!
-		if( firstWord )	{ // first word on first line, so no separating SPACE needed
+		if ( firstWord )	{ // first word on first line, so no separating SPACE needed
 			line[0].width = wordWidth;
 			line[0].length = wordLength;
 			firstWord = false;





More information about the Scummvm-git-logs mailing list