Page 1 of 1

skipping all players

Posted: 11 April 2024, 15:53
by AxeCrazy
Well, i have a strange issue with the latest gaem i am trying to develop.
It can be played with 2 to 8 players.
i only just started the framework and somehow when the startplayer plays a card the state goes to nextplayer, which should active the next player and so on.
But when player 1 plays a card i get just as many nextplayer-> playCard state changes as the are players, without the other players becoming active, so it ends up with hte 1 player again?

Anyone had this problem ?
Must be very easy, but cannot find the glitch

Re: skipping all players

Posted: 11 April 2024, 20:02
by LeSteffen
Post some code please :-)

Re: skipping all players

Posted: 11 April 2024, 21:34
by AxeCrazy
It really was to stupid :P
i added the $this->gamestate->nextState('nextPlayer');
call in the a for loop to update players
so, problems solved :lol: