diff options
Diffstat (limited to 'src/engine/turns.js')
-rw-r--r-- | src/engine/turns.js | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/engine/turns.js b/src/engine/turns.js index 0018417..0906932 100644 --- a/src/engine/turns.js +++ b/src/engine/turns.js @@ -1,10 +1,16 @@ import { PLAYER } from "../constants.js" import { placeLinks } from "../engine/placeLinks.js" +import { removeDeadStones } from "../engine/death.js" -export let playerTurn = "" +export let playerTurn = "black" -export function nextTurn() { +export function nextTurn({move = null}) { + if (move != null) removeDeadStones(move) changeTurn() + startTurn() +} + +export function startTurn() { placeLinks() } |