X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Fgame_sp%2FMainGameLoop.c;h=028c861e03a5741f44a9eccff4d84465340cfed1;hb=f926e522aef77158e0011ae5ad2cf8805509d6d1;hp=42bafa50fe9e253fbf04201159caa617171c7a12;hpb=572a4bab20b6f36ef1a4782094b27ac5a703a476;p=rocksndiamonds.git diff --git a/src/game_sp/MainGameLoop.c b/src/game_sp/MainGameLoop.c index 42bafa50..028c861e 100644 --- a/src/game_sp/MainGameLoop.c +++ b/src/game_sp/MainGameLoop.c @@ -293,8 +293,8 @@ locExitMainGameLoop: #if 1 /* if the game is not won when reaching this point, then it is lost */ - if (!game_sp_info.LevelSolved) - game_sp_info.GameOver = TRUE; + if (!game_sp.LevelSolved) + game_sp.GameOver = TRUE; #endif #if 1 @@ -581,9 +581,26 @@ int subCalculateScreenScrollPos() int ax, Ay; +#if 1 + int jump_pos = TILEX / 2; + + if (MurphyScreenXPos < -jump_pos) + { + MurphyScreenXPos = FieldWidth * TILEX + MurphyScreenXPos; + MurphyScreenYPos -= TILEY; + } + else if (MurphyScreenXPos >= FieldWidth * TILEX - jump_pos) + { + MurphyScreenXPos = MurphyScreenXPos - FieldWidth * TILEX; + MurphyScreenYPos += TILEY; + } +#endif + if (ExplosionShake != 0) { subGetRandomNumber(); + + // printf("::: ExplosionShake [%d]\n", FrameCounter); } {