diff options
author | Max Horn | 2003-09-13 17:36:53 +0000 |
---|---|---|
committer | Max Horn | 2003-09-13 17:36:53 +0000 |
commit | 54a6946eee0e8789bf3b9d66b81378119c4852d3 (patch) | |
tree | c294d582edb1f6b284372c9dfd94cc162dfa4f81 /sword2 | |
parent | 51703e1014b8d72aa2469819a8c483870a3a503a (diff) | |
download | scummvm-rg350-54a6946eee0e8789bf3b9d66b81378119c4852d3.tar.gz scummvm-rg350-54a6946eee0e8789bf3b9d66b81378119c4852d3.tar.bz2 scummvm-rg350-54a6946eee0e8789bf3b9d66b81378119c4852d3.zip |
cleanup
svn-id: r10235
Diffstat (limited to 'sword2')
-rw-r--r-- | sword2/router.cpp | 66 | ||||
-rw-r--r-- | sword2/save_rest.cpp | 12 |
2 files changed, 39 insertions, 39 deletions
diff --git a/sword2/router.cpp b/sword2/router.cpp index 06229dc29b..2d6297cbf2 100644 --- a/sword2/router.cpp +++ b/sword2/router.cpp @@ -221,10 +221,10 @@ static _barData bars[O_GRID_SIZE+EXTRA_GRID_SIZE]; // because extra bars will be 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 _pathData modularPath[O_ROUTE_SIZE]; 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) diff --git a/sword2/save_rest.cpp b/sword2/save_rest.cpp index 2e3bde15c7..e6ba630050 100644 --- a/sword2/save_rest.cpp +++ b/sword2/save_rest.cpp @@ -186,16 +186,16 @@ void FillSaveBuffer(mem *buffer, uint32 size, uint8 *desc) // 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 @@ void FillSaveBuffer(mem *buffer, uint32 size, uint8 *desc) #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; |