clear.ts 209 Bytes
import { Game } from "../../game/Game";
import { Room } from "../../room/Room";

export function clear(rooms: Room[]): void {
  rooms.forEach((room) => {
    room.game?.finishGame();
    room.close();
  });
}