Add Thread-Safe Lists, and make all list access thread-safe

This commit is contained in:
Li 2022-08-31 20:31:07 +12:00
parent 900fe0d48a
commit 40c34ac030
24 changed files with 111 additions and 44 deletions

View file

@ -97,11 +97,11 @@ namespace HISP.Game.Events
return participents.ToArray();
}
}
private List<Participent> participents;
private ThreadSafeList<Participent> participents;
public RealTimeQuiz()
{
participents = new List<Participent>();
participents = new ThreadSafeList<Participent>();
Questions = new QuizQuestion[8];
for(int i = 0; i < 8; i++)
{