Re-added the classic-mode-edge-behavior in a better way.
This way preserves checks for Classic difficulty within (where auto-camera-centering is implemented) so that if the edge behavior ever changes again, it won't have unintended side-effects. The conditional is also inverted to make it easier to read.
This commit is contained in:
parent
628ed07c8b
commit
d8331ac14e
14
src/game.c
14
src/game.c
|
@ -1435,9 +1435,12 @@ static void game_doPlayer()
|
|||
|
||||
if (engine.done == 0)
|
||||
{
|
||||
if ((game.difficulty != DIFFICULTY_ORIGINAL) ||
|
||||
((game.area != MISN_ELLESH) &&
|
||||
(game.area != MISN_MARS)))
|
||||
if (game.difficulty == DIFFICULTY_ORIGINAL)
|
||||
{
|
||||
LIMIT(player.x, X_VIEW_BORDER, screen->w - X_VIEW_BORDER);
|
||||
LIMIT(player.y, Y_VIEW_BORDER, screen->h - Y_VIEW_BORDER);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (xmoved)
|
||||
{
|
||||
|
@ -1499,11 +1502,6 @@ static void game_doPlayer()
|
|||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
LIMIT(player.x, X_VIEW_BORDER, screen->w - X_VIEW_BORDER);
|
||||
LIMIT(player.y, Y_VIEW_BORDER, screen->h - Y_VIEW_BORDER);
|
||||
}
|
||||
}
|
||||
|
||||
if ((player.maxShield <= 1) || (player.shield > engine.lowShield))
|
||||
|
|
Loading…
Reference in New Issue