import { PLAYER } from "../constants.js" import { placeLinks } from "../engine/placeLinks.js" import { removeDeadStones } from "../engine/death.js" export let playerTurn = "black" export function nextTurn({move = null}) { if (move != null) removeDeadStones(move) changeTurn() startTurn() } export function startTurn() { placeLinks() } function changeTurn() { playerTurn = playerTurn == PLAYER.BLACK ? PLAYER.WHITE : PLAYER.BLACK }