projects
/
rocksndiamonds.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
added checkbox to player settings in editor if first player solves level
[rocksndiamonds.git]
/
src
/
game.c
diff --git
a/src/game.c
b/src/game.c
index d9ac07ace8b24b7aa528880e7bc7858f76f589e7..e0f9c8781c8f199311028141fe57aee066ad09b1 100644
(file)
--- a/
src/game.c
+++ b/
src/game.c
@@
-3956,6
+3956,9
@@
void InitGame()
if (stored_player[i].active)
local_player->players_still_needed++;
if (stored_player[i].active)
local_player->players_still_needed++;
+ if (level.solved_by_one_player)
+ local_player->players_still_needed = 1;
+
/* when recording the game, store which players take part in the game */
if (tape.recording)
{
/* when recording the game, store which players take part in the game */
if (tape.recording)
{
@@
-13425,7
+13428,8
@@
void ExitPlayer(struct PlayerInfo *player)
DrawPlayer(player); /* needed here only to cleanup last field */
RemovePlayer(player);
DrawPlayer(player); /* needed here only to cleanup last field */
RemovePlayer(player);
- local_player->players_still_needed--;
+ if (local_player->players_still_needed > 0)
+ local_player->players_still_needed--;
}
static void setFieldForSnapping(int x, int y, int element, int direction)
}
static void setFieldForSnapping(int x, int y, int element, int direction)