@Override
        public void run() {
            //write your code here
            while (!OnlineGame.isWinnerFound) {
                for (int i = 0; i < OnlineGame.actions.size(); i++) {
                    try {
                        System.out.println(this.getName() + ":" + OnlineGame.actions.get(i));
                        Thread.sleep(1000/this.rating);
                    } catch (InterruptedException e) {
                        System.out.println(this.getName() + ":lost");
                        break;
                    }
                }
                OnlineGame.isWinnerFound = true;
                System.out.println(this.getName() + ":won!");
            }
        }
    }
}
Output was: Smith:Start game Jones:Start game Gates:Start game Gates:Gather resources Smith:Gather resources Gates:Grow economy Gates:Kill enemies Smith:Grow economy Smith:lost Jones:lost Gates:won! Jones:won! Smith:won! How should I have done it that only won of them displayed won! ?