projects
/
rocksndiamonds.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
minor whitespace change
[rocksndiamonds.git]
/
src
/
game.c
diff --git
a/src/game.c
b/src/game.c
index 52ea43293cebaf68c232005cd88121809568ab26..9b91031193dda070ee3285f3f9c976682c80e8ab 100644
(file)
--- a/
src/game.c
+++ b/
src/game.c
@@
-3402,6
+3402,7
@@
void InitGame(void)
player->action = 0;
player->effective_action = 0;
player->programmed_action = 0;
player->action = 0;
player->effective_action = 0;
player->programmed_action = 0;
+ player->snap_action = 0;
player->mouse_action.lx = 0;
player->mouse_action.ly = 0;
player->mouse_action.lx = 0;
player->mouse_action.ly = 0;
@@
-11058,10
+11059,7
@@
static void CheckSingleStepMode(struct PlayerInfo *player)
if (!player->is_moving &&
!player->is_pushing &&
!player->is_dropping_pressed)
if (!player->is_moving &&
!player->is_pushing &&
!player->is_dropping_pressed)
- {
TapeTogglePause(TAPE_TOGGLE_AUTOMATIC);
TapeTogglePause(TAPE_TOGGLE_AUTOMATIC);
- SnapField(player, 0, 0); // stop snapping
- }
}
CheckSaveEngineSnapshot(player);
}
CheckSaveEngineSnapshot(player);
@@
-11996,7
+11994,7
@@
void GameActions_RND(void)
element == EL_DC_MAGIC_WALL_FULL ||
element == EL_DC_MAGIC_WALL_ACTIVE ||
element == EL_DC_MAGIC_WALL_EMPTYING) &&
element == EL_DC_MAGIC_WALL_FULL ||
element == EL_DC_MAGIC_WALL_ACTIVE ||
element == EL_DC_MAGIC_WALL_EMPTYING) &&
- ABS(x
-jx) + ABS(y-jy) < ABS(magic_wall_x-jx) + ABS(magic_wall_y-
jy))
+ ABS(x
- jx) + ABS(y - jy) < ABS(magic_wall_x - jx) + ABS(magic_wall_y -
jy))
{
magic_wall_x = x;
magic_wall_y = y;
{
magic_wall_x = x;
magic_wall_y = y;
@@
-12530,7
+12528,7
@@
boolean MovePlayer(struct PlayerInfo *player, int dx, int dy)
{
if ((player->MovDir == MV_LEFT && scroll_x > jx - MIDPOSX + offset) ||
(player->MovDir == MV_RIGHT && scroll_x < jx - MIDPOSX - offset))
{
if ((player->MovDir == MV_LEFT && scroll_x > jx - MIDPOSX + offset) ||
(player->MovDir == MV_RIGHT && scroll_x < jx - MIDPOSX - offset))
- scroll_x = jx
-MIDPOSX + (scroll_x < jx-
MIDPOSX ? -offset : +offset);
+ scroll_x = jx
- MIDPOSX + (scroll_x < jx -
MIDPOSX ? -offset : +offset);
// don't scroll over playfield boundaries
if (scroll_x < SBX_Left || scroll_x > SBX_Right)
// don't scroll over playfield boundaries
if (scroll_x < SBX_Left || scroll_x > SBX_Right)
@@
-12548,7
+12546,7
@@
boolean MovePlayer(struct PlayerInfo *player, int dx, int dy)
{
if ((player->MovDir == MV_UP && scroll_y > jy - MIDPOSY + offset) ||
(player->MovDir == MV_DOWN && scroll_y < jy - MIDPOSY - offset))
{
if ((player->MovDir == MV_UP && scroll_y > jy - MIDPOSY + offset) ||
(player->MovDir == MV_DOWN && scroll_y < jy - MIDPOSY - offset))
- scroll_y = jy
-MIDPOSY + (scroll_y < jy-
MIDPOSY ? -offset : +offset);
+ scroll_y = jy
- MIDPOSY + (scroll_y < jy -
MIDPOSY ? -offset : +offset);
// don't scroll over playfield boundaries
if (scroll_y < SBY_Upper || scroll_y > SBY_Lower)
// don't scroll over playfield boundaries
if (scroll_y < SBY_Upper || scroll_y > SBY_Lower)