mirror of
https://github.com/guezoloic/L3-racing-game.git
synced 2026-03-31 04:11:33 +00:00
fix(Rankboard.java): ajout arraylist clone
This commit is contained in:
@@ -243,14 +243,17 @@ public class Game
|
||||
*
|
||||
* @throws InterruptedException si le thread est interrompu pendant wait()
|
||||
*/
|
||||
private synchronized void step() throws InterruptedException
|
||||
private void step() throws InterruptedException
|
||||
{
|
||||
for (int i = 0; i < cars.size(); i++)
|
||||
for (Car car : cars)
|
||||
{
|
||||
while (isPaused)
|
||||
wait();
|
||||
synchronized(this)
|
||||
{
|
||||
while (isPaused)
|
||||
wait();
|
||||
}
|
||||
|
||||
cars.get(i).run();
|
||||
car.run();
|
||||
|
||||
for (GObserver o : obs)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user