[Scummvm-cvs-logs] CVS: scummvm/bs2 router.cpp,1.10,1.11 save_rest.cpp,1.9,1.10
Max Horn
fingolfin at users.sourceforge.net
Sat Sep 13 10:37:10 CEST 2003
Update of /cvsroot/scummvm/scummvm/bs2
In directory sc8-pr-cvs1:/tmp/cvs-serv10750
Modified Files:
router.cpp save_rest.cpp
Log Message:
cleanup
Index: router.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/bs2/router.cpp,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- router.cpp 13 Sep 2003 12:03:29 -0000 1.10
+++ router.cpp 13 Sep 2003 17:36:53 -0000 1.11
@@ -221,10 +221,10 @@
static _nodeData node[O_GRID_SIZE+EXTRA_GRID_SIZE];
// area for extra route data to block parts of floors and enable routing round mega charaters
-static int32 nExtraBars = 0;
-static int32 nExtraNodes = 0;
-static _barData extraBars[EXTRA_GRID_SIZE];
-static _nodeData extraNode[EXTRA_GRID_SIZE];
+static int32 nExtraBars = 0;
+static int32 nExtraNodes = 0;
+static _barData extraBars[EXTRA_GRID_SIZE];
+static _nodeData extraNode[EXTRA_GRID_SIZE];
static int32 startX;
static int32 startY;
@@ -240,45 +240,45 @@
static int32 routeLength;
-int32 framesPerStep;
-int32 framesPerChar;
+static int32 framesPerStep;
+static int32 framesPerChar;
-uint8 nWalkFrames; // no. of frames per walk cycle
-uint8 usingStandingTurnFrames; // any standing turn frames?
-uint8 usingWalkingTurnFrames; // any walking turn frames?
-uint8 usingSlowInFrames; // any slow-in frames?
-uint8 usingSlowOutFrames; // any slow-out frames?
-int32 dx[NO_DIRECTIONS + MAX_FRAMES_PER_CHAR];
-int32 dy[NO_DIRECTIONS + MAX_FRAMES_PER_CHAR];
-int8 modX[NO_DIRECTIONS];
-int8 modY[NO_DIRECTIONS];
-int32 diagonalx = 0;
-int32 diagonaly = 0;
+static uint8 nWalkFrames; // no. of frames per walk cycle
+static uint8 usingStandingTurnFrames; // any standing turn frames?
+static uint8 usingWalkingTurnFrames; // any walking turn frames?
+static uint8 usingSlowInFrames; // any slow-in frames?
+static uint8 usingSlowOutFrames; // any slow-out frames?
+static int32 dx[NO_DIRECTIONS + MAX_FRAMES_PER_CHAR];
+static int32 dy[NO_DIRECTIONS + MAX_FRAMES_PER_CHAR];
+static int8 modX[NO_DIRECTIONS];
+static int8 modY[NO_DIRECTIONS];
+static int32 diagonalx = 0;
+static int32 diagonaly = 0;
-int32 firstStandFrame;
+static int32 firstStandFrame;
-int32 firstStandingTurnLeftFrame;
-int32 firstStandingTurnRightFrame;
+static int32 firstStandingTurnLeftFrame;
+static int32 firstStandingTurnRightFrame;
-int32 firstWalkingTurnLeftFrame; // left walking turn
-int32 firstWalkingTurnRightFrame; // right walking turn
+static int32 firstWalkingTurnLeftFrame; // left walking turn
+static int32 firstWalkingTurnRightFrame; // right walking turn
-uint32 firstSlowInFrame[NO_DIRECTIONS];
-uint32 numberOfSlowInFrames[NO_DIRECTIONS];
+static uint32 firstSlowInFrame[NO_DIRECTIONS];
+static uint32 numberOfSlowInFrames[NO_DIRECTIONS];
-uint32 leadingLeg[NO_DIRECTIONS];
+static uint32 leadingLeg[NO_DIRECTIONS];
-int32 firstSlowOutFrame;
-int32 numberOfSlowOutFrames; // number of slow-out frames on for each leading-leg in each direction
+static int32 firstSlowOutFrame;
+static int32 numberOfSlowOutFrames; // number of slow-out frames on for each leading-leg in each direction
-int32 stepCount;
+static int32 stepCount;
-int32 moduleX;
-int32 moduleY;
-int32 currentDir;
-int32 lastCount;
-int32 frame;
+static int32 moduleX;
+static int32 moduleY;
+static int32 currentDir;
+static int32 lastCount;
+static int32 frame;
// ie. total number of slow-out frames = (numberOfSlowOutFrames * 2 * NO_DIRECTIONS)
Index: save_rest.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/bs2/save_rest.cpp,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- save_rest.cpp 13 Sep 2003 13:20:28 -0000 1.9
+++ save_rest.cpp 13 Sep 2003 17:36:53 -0000 1.10
@@ -186,16 +186,16 @@
// set up the g_header
// 'checksum' gets filled in last of all
- sprintf(g_header.description, "%s", (char*)desc); // player's description of savegame
+ sprintf(g_header.description, "%s", (char*)desc); // player's description of savegame
g_header.varLength = res_man.Res_fetch_len(1); // length of global variables resource
- g_header.screenId = this_screen.background_layer_id; // resource id of current screen file
+ g_header.screenId = this_screen.background_layer_id; // resource id of current screen file
g_header.runListId = LLogic.Return_run_list(); // resource id of current run-list
g_header.feet_x = this_screen.feet_x; // those scroll position control things
g_header.feet_y = this_screen.feet_y; //
- g_header.music_id = looping_music_id; // id of currently looping music (or zero)
+ g_header.music_id = looping_music_id; // id of currently looping music (or zero)
// object hub
- memcpy (&g_header.player_hub, res_man.Res_open(CUR_PLAYER_ID) + sizeof(_standardHeader), sizeof(_object_hub));
+ memcpy(&g_header.player_hub, res_man.Res_open(CUR_PLAYER_ID) + sizeof(_standardHeader), sizeof(_object_hub));
res_man.Res_close(CUR_PLAYER_ID);
// logic, graphic & mega structures
@@ -207,13 +207,13 @@
#ifdef SCUMM_BIG_ENDIAN
converHeaderEndian(g_header);
#endif
- memcpy( buffer->ad, &g_header, sizeof(g_header) ); // copy the header to the savegame buffer
+ memcpy(buffer->ad, &g_header, sizeof(g_header)); // copy the header to the savegame buffer
//------------------------------------------------------
// copy the global variables to the buffer
varsRes = res_man.Res_open(1); // open variables resource
- memcpy( buffer->ad + sizeof(g_header), varsRes, FROM_LE_32(g_header.varLength) ); // copy that to the buffer, following the header
+ memcpy(buffer->ad + sizeof(g_header), varsRes, FROM_LE_32(g_header.varLength)); // copy that to the buffer, following the header
#ifdef SCUMM_BIG_ENDIAN
uint32 *globalVars = (uint32 *)(buffer->ad + sizeof(g_header));
const uint numVars = FROM_LE_32(g_header.varLength)/4;
More information about the Scummvm-git-logs
mailing list