Compare commits

..

No commits in common. "8b48dc9462051c9fd870a6c74e2aa911ca74aa80" and "d36dad28bd0079bf81134f3570c51e5ce83dd3c4" have entirely different histories.

2 changed files with 7 additions and 13 deletions

View File

@ -428,7 +428,7 @@ private void CheckPlayersPropositions()
{
if (string.IsNullOrEmpty(p.photoUrl))
{
Debug.Log($"player {p.owner.name} has a proposition without an URL");
Debug.Log($"player {p.owner} has a proposition without an URL");
allPlayersHasProposedTwoPictures = false;
}
}

View File

@ -133,27 +133,21 @@ private void UpdateVoters()
if (currentQuestion.propositions[0] != null)
{
List<Player> playersThatHasVotedForFirstProposition = new List<Player>();
if (currentQuestion.propositions[0].voters != null)
foreach (string playerId in currentQuestion.propositions[0].voters)
{
foreach (string playerId in currentQuestion.propositions[0].voters)
{
playersThatHasVotedForFirstProposition.Add(currentPlayers[playerId]);
}
proposition1.UpdateVoters(playersThatHasVotedForFirstProposition);
playersThatHasVotedForFirstProposition.Add(currentPlayers[playerId]);
}
proposition1.UpdateVoters(playersThatHasVotedForFirstProposition);
}
if (currentQuestion.propositions[1] != null)
{
List<Player> playersThatHasVotedForSecondProposition = new List<Player>();
if (currentQuestion.propositions[0].voters != null)
foreach (string playerId in currentQuestion.propositions[1].voters)
{
foreach (string playerId in currentQuestion.propositions[1].voters)
{
playersThatHasVotedForSecondProposition.Add(currentPlayers[playerId]);
}
proposition2.UpdateVoters(playersThatHasVotedForSecondProposition);
playersThatHasVotedForSecondProposition.Add(currentPlayers[playerId]);
}
proposition2.UpdateVoters(playersThatHasVotedForSecondProposition);
}
}
}