X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;ds=sidebyside;f=src%2Fgame.c;h=2024abb41b49e957be9fabc3f2644f01e6dcb53f;hb=338cfb1f6b043bdeaa0c77518b2a58b364ebc941;hp=b12c0f41dd8546b75348dab4c0a00de6dea3a6b8;hpb=c9d8e4e56f2c15baf85f2344043899c9782bddd2;p=rocksndiamonds.git diff --git a/src/game.c b/src/game.c index b12c0f41..2024abb4 100644 --- a/src/game.c +++ b/src/game.c @@ -197,17 +197,26 @@ void InitGame() { player->active = TRUE; + /* remove potentially duplicate players */ + if (StorePlayer[jx][jy] == Feld[x][y]) + StorePlayer[jx][jy] = 0; + + StorePlayer[x][y] = Feld[x][y]; + printf("Player %d activated.\n", player->element_nr); printf("[Local player is %d and currently %s.]\n", local_player->element_nr, local_player->active ? "active" : "not active"); } +#if 0 /* remove potentially duplicate players */ if (StorePlayer[jx][jy] == Feld[x][y]) StorePlayer[jx][jy] = 0; StorePlayer[x][y] = Feld[x][y]; +#endif + Feld[x][y] = EL_LEERRAUM; player->jx = player->last_jx = x; player->jy = player->last_jy = y;