This commit is contained in:
Fangh 2024-02-04 13:11:24 +01:00
parent 6454b54dc6
commit 63bcb59d72
2 changed files with 5 additions and 1 deletions

View File

@ -505,7 +505,7 @@ public void onClickNewPlayers()
private void OnCurrentQuestionChanged(object sender, ValueChangedEventArgs onlineValue)
{
if (onlineValue == null || onlineValue.Snapshot == null || onlineValue.Snapshot.Value == null)
if (onlineValue == null || onlineValue.Snapshot == null || onlineValue.Snapshot.Value == null || myRoom.questions == null || myRoom.questions.Count == 0)
return;
int questionId = onlineValue.Snapshot.Value.ConvertTo<int>();

View File

@ -26,6 +26,10 @@ public void Initialize(Room _myRoom, Action _onPropositionFinish)
myRoom = _myRoom;
allPlayersHasProposedTwoPictures = false;
playersIdWhoHaveProposed.Clear();
foreach(TextMeshProUGUI label in playerLabels)
{
label.color = Color.white;
}
ShowPlayerLabels();
}